diff options
author | davidcs <davidcs@FreeBSD.org> | 2013-08-27 21:29:21 +0000 |
---|---|---|
committer | davidcs <davidcs@FreeBSD.org> | 2013-08-27 21:29:21 +0000 |
commit | 2b254c93081ca42c7b0fd38416fca970ae42fa66 (patch) | |
tree | 95bd69724d3625589fc45c886fd66b442f50b4a5 | |
parent | 976074d43e046c7be4a8f1855ef3005150d23eb3 (diff) | |
download | FreeBSD-src-2b254c93081ca42c7b0fd38416fca970ae42fa66.zip FreeBSD-src-2b254c93081ca42c7b0fd38416fca970ae42fa66.tar.gz |
Fix bug in Flash access code
Submitted by: David C Somayajulu
-rw-r--r-- | sys/dev/qlxgbe/ql_misc.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/dev/qlxgbe/ql_misc.c b/sys/dev/qlxgbe/ql_misc.c index 6c7292f..ef0f4a7 100644 --- a/sys/dev/qlxgbe/ql_misc.c +++ b/sys/dev/qlxgbe/ql_misc.c @@ -321,7 +321,7 @@ qla_get_fdt(qla_host_t *ha) } while ((count < 10000) && (data32 != 0x6)); - if (count == 0 && data32 != 0x6) { + if (data32 != 0x6) { qla_sem_unlock(ha, Q8_FLASH_UNLOCK); device_printf(ha->pci_dev, "%s: Poll Q8_FLASH_STATUS failed\n", @@ -401,7 +401,7 @@ qla_flash_write_enable(qla_host_t *ha, int enable) } while ((count < 10000) && (data32 != 0x6)); - if (count == 0 && data32 != 0x6) { + if (data32 != 0x6) { device_printf(ha->pci_dev, "%s: Poll Q8_FLASH_STATUS failed\n", __func__); @@ -432,7 +432,7 @@ qla_erase_flash_sector(qla_host_t *ha, uint32_t start) } while (((count++) < 1000) && (data32 != 0x6)); - if (count == 0 && data32 != 0x6) { + if (data32 != 0x6) { device_printf(ha->pci_dev, "%s: Poll Q8_FLASH_STATUS failed\n", __func__); @@ -479,7 +479,7 @@ qla_erase_flash_sector(qla_host_t *ha, uint32_t start) } while (((count++) < 1000) && (data32 != 0x6)); - if (count == 0 && data32 != 0x6) { + if (data32 != 0x6) { device_printf(ha->pci_dev, "%s: Poll Q8_FLASH_STATUS failed\n", __func__); @@ -575,7 +575,7 @@ qla_wr_flash32(qla_host_t *ha, uint32_t off, uint32_t *data) } while ((count < 10000) && (data32 != 0x6)); - if (count == 0 && data32 != 0x6) { + if (data32 != 0x6) { device_printf(ha->pci_dev, "%s: Poll Q8_FLASH_STATUS failed\n", __func__); |