svn commit: r210257 - head/sys/dev/bce
Pyun YongHyeon
yongari at FreeBSD.org
Mon Jul 19 21:13:07 UTC 2010
Author: yongari
Date: Mon Jul 19 21:13:07 2010
New Revision: 210257
URL: http://svn.freebsd.org/changeset/base/210257
Log:
When we didn't find a matching flash device, do not touch flash
config data. While I'm here, use return code of bce_init_nvram()
to set error instead of directly setting ENODEV.
Reviewed by: davidch
Modified:
head/sys/dev/bce/if_bce.c
Modified: head/sys/dev/bce/if_bce.c
==============================================================================
--- head/sys/dev/bce/if_bce.c Mon Jul 19 20:31:04 2010 (r210256)
+++ head/sys/dev/bce/if_bce.c Mon Jul 19 21:13:07 2010 (r210257)
@@ -2264,7 +2264,8 @@ bce_init_nvram(struct bce_softc *sc)
sc->bce_flash_info = NULL;
BCE_PRINTF("%s(%d): Unknown Flash NVRAM found!\n",
__FILE__, __LINE__);
- rc = ENODEV;
+ DBEXIT(BCE_VERBOSE_NVRAM);
+ return (ENODEV);
}
bce_init_nvram_get_flash_size:
@@ -4796,10 +4797,8 @@ bce_chipinit(struct bce_softc *sc)
}
/* Prepare NVRAM for access. */
- if (bce_init_nvram(sc)) {
- rc = ENODEV;
+ if ((rc = bce_init_nvram(sc)) != 0)
goto bce_chipinit_exit;
- }
/* Set the kernel bypass block size */
val = REG_RD(sc, BCE_MQ_CONFIG);
More information about the svn-src-head
mailing list