From 022a33775582d842aa03f4fc145ab90b8746b89b Mon Sep 17 00:00:00 2001 From: hosokawa Date: Sat, 22 Jan 2000 17:24:16 +0000 Subject: Don't execute MAC address initialization for non-pccard sn devices. --- sys/dev/sn/if_sn.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'sys/dev/sn/if_sn.c') diff --git a/sys/dev/sn/if_sn.c b/sys/dev/sn/if_sn.c index e03e868..cbc18d9 100644 --- a/sys/dev/sn/if_sn.c +++ b/sys/dev/sn/if_sn.c @@ -190,13 +190,14 @@ sn_attach(device_t dev) i = inw(BASE + CONFIG_REG_W); printf(i & CR_AUI_SELECT ? "AUI" : "UTP"); - for (j = 0; j < 3; j++) { - u_short w; + if (sc->pccard_enaddr) + for (j = 0; j < 3; j++) { + u_short w; - w = (u_short)sc->arpcom.ac_enaddr[j * 2] | - (((u_short)sc->arpcom.ac_enaddr[j * 2 + 1]) << 8); - outw(BASE + IAR_ADDR0_REG_W + j * 2, w); - } + w = (u_short)sc->arpcom.ac_enaddr[j * 2] | + (((u_short)sc->arpcom.ac_enaddr[j * 2 + 1]) << 8); + outw(BASE + IAR_ADDR0_REG_W + j * 2, w); + } /* * Read the station address from the chip. The MAC address is bank 1, -- cgit v1.1