diff options
author | Kevin Lo <kevlo@cvs.openbsd.org> | 2009-07-28 05:12:13 +0000 |
---|---|---|
committer | Kevin Lo <kevlo@cvs.openbsd.org> | 2009-07-28 05:12:13 +0000 |
commit | 673851422d748462fc542c2ed3588f866c8cb072 (patch) | |
tree | d7ce28fd0525da69e2eecc6b37ba73d149bb18de /sys | |
parent | 8c16d417c8488fbe105992504143e46fb618d4bf (diff) |
print the chipset name in the dmesg so it is possible to tell
whether this is an L1E or L2E chipset.
From Brad
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/pci/if_ale.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/dev/pci/if_ale.c b/sys/dev/pci/if_ale.c index 979ba123df7..a6793be1451 100644 --- a/sys/dev/pci/if_ale.c +++ b/sys/dev/pci/if_ale.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_ale.c,v 1.5 2009/07/28 02:40:53 kevlo Exp $ */ +/* $OpenBSD: if_ale.c,v 1.6 2009/07/28 05:12:12 kevlo Exp $ */ /*- * Copyright (c) 2008, Pyun YongHyeon <yongari@FreeBSD.org> * All rights reserved. @@ -374,6 +374,7 @@ ale_attach(struct device *parent, struct device *self, void *aux) pcireg_t memtype; int mii_flags, error = 0; uint32_t rxf_len, txf_len; + const char *chipname; /* * Allocate IO memory @@ -403,7 +404,6 @@ ale_attach(struct device *parent, struct device *self, void *aux) printf("\n"); goto fail; } - printf(": %s", intrstr); sc->sc_dmat = pa->pa_dmat; sc->sc_pct = pa->pa_pc; @@ -423,16 +423,21 @@ ale_attach(struct device *parent, struct device *self, void *aux) if (sc->ale_rev >= 0xF0) { /* L2E Rev. B. AR8114 */ sc->ale_flags |= ALE_FLAG_FASTETHER; + chipname = "AR8114"; } else { if ((CSR_READ_4(sc, ALE_PHY_STATUS) & PHY_STATUS_100M) != 0) { /* L1E AR8121 */ sc->ale_flags |= ALE_FLAG_JUMBO; + chipname = "AR8121"; } else { /* L2E Rev. A. AR8113 */ sc->ale_flags |= ALE_FLAG_FASTETHER; + chipname = "AR8113"; } } + printf(": %s, %s", chipname, intrstr); + /* * All known controllers seems to require 4 bytes alignment * of Tx buffers to make Tx checksum offload with custom |