PERFORCE change 221805 for review
Bjoern A. Zeeb
bz at FreeBSD.org
Wed Feb 6 19:09:01 UTC 2013
http://p4web.freebsd.org/@@221805?ac=10
Change 221805 by bz at bz_zenith on 2013/02/06 19:08:31
Move the factory Ethernet hardware address blacklist checking down
to where the test can actually do something useful (and works).
Affected files ...
.. //depot/projects/ctsrd/beribsd/src/sys/dev/altera/atse/if_atse.c#10 edit
Differences ...
==== //depot/projects/ctsrd/beribsd/src/sys/dev/altera/atse/if_atse.c#10 (text+ko) ====
@@ -688,18 +688,6 @@
sc->atse_eth_addr[2] != 0x00)
return (0);
- /* Handle factory default ethernet addresss: 00:07:ed:ff:ed:15 */
- if (sc->atse_eth_addr[0] == 0x00 && sc->atse_eth_addr[1] == 0x07 &&
- sc->atse_eth_addr[2] == 0xed && sc->atse_eth_addr[3] == 0xff &&
- sc->atse_eth_addr[4] == 0xed && sc->atse_eth_addr[5] == 0x15) {
-
- device_printf(sc->atse_dev, "Factory programmed Ethernet "
- "hardware address blacklisted. Falling back to random "
- "address to avoid collisions.\n");
- device_printf(sc->atse_dev, "Please re-program your flash.\n");
- goto get_random;
- }
-
if ((atse_ethernet_option_bits_flag &
ATSE_ETHERNET_OPTION_BITS_READ) == 0)
goto get_random;
@@ -723,6 +711,18 @@
sc->atse_eth_addr[4] = atse_ethernet_option_bits[8];
sc->atse_eth_addr[5] = atse_ethernet_option_bits[9];
+ /* Handle factory default ethernet addresss: 00:07:ed:ff:ed:15 */
+ if (sc->atse_eth_addr[0] == 0x00 && sc->atse_eth_addr[1] == 0x07 &&
+ sc->atse_eth_addr[2] == 0xed && sc->atse_eth_addr[3] == 0xff &&
+ sc->atse_eth_addr[4] == 0xed && sc->atse_eth_addr[5] == 0x15) {
+
+ device_printf(sc->atse_dev, "Factory programmed Ethernet "
+ "hardware address blacklisted. Falling back to random "
+ "address to avoid collisions.\n");
+ device_printf(sc->atse_dev, "Please re-program your flash.\n");
+ goto get_random;
+ }
+
/*
* If we find a locally administered address with a 0x0 ending
* adjust by device unit. If not and this is not the first
More information about the p4-projects
mailing list