diff options
author | Brad Smith <brad@cvs.openbsd.org> | 2008-12-04 02:36:53 +0000 |
---|---|---|
committer | Brad Smith <brad@cvs.openbsd.org> | 2008-12-04 02:36:53 +0000 |
commit | b31366e422eadfe3261e107ff625a058b3878daa (patch) | |
tree | 78a1c850db806bc3f2a6f6c9fadc77372468f3d2 | |
parent | 9c747f8a643dcd3c27b163d00728d6d7ff90d96a (diff) |
Add initial support for the ICH9 IGP M and ICH9 IGP M AMT chipsets.
For now the chunk in em_detect_gig_phy() is a hack to get things going
until it can be figured out why exactly the PHY id is not probed
properly.
Based on a diff from jcs@ via ckuethe@
ok kettenis@
-rw-r--r-- | sys/dev/pci/if_em.c | 6 | ||||
-rw-r--r-- | sys/dev/pci/if_em_hw.c | 13 |
2 files changed, 16 insertions, 3 deletions
diff --git a/sys/dev/pci/if_em.c b/sys/dev/pci/if_em.c index 76c2f065594..f059449896b 100644 --- a/sys/dev/pci/if_em.c +++ b/sys/dev/pci/if_em.c @@ -31,7 +31,7 @@ POSSIBILITY OF SUCH DAMAGE. ***************************************************************************/ -/* $OpenBSD: if_em.c,v 1.200 2008/12/03 00:59:48 dlg Exp $ */ +/* $OpenBSD: if_em.c,v 1.201 2008/12/04 02:36:51 brad Exp $ */ /* $FreeBSD: if_em.c,v 1.46 2004/09/29 18:28:28 mlaier Exp $ */ #include <dev/pci/if_em.h> @@ -127,7 +127,9 @@ const struct pci_matchid em_devices[] = { { PCI_VENDOR_INTEL, PCI_PRODUCT_INTEL_ICH9_IFE_G }, { PCI_VENDOR_INTEL, PCI_PRODUCT_INTEL_ICH9_IFE_GT }, { PCI_VENDOR_INTEL, PCI_PRODUCT_INTEL_ICH9_IGP_AMT }, - { PCI_VENDOR_INTEL, PCI_PRODUCT_INTEL_ICH9_IGP_C } + { PCI_VENDOR_INTEL, PCI_PRODUCT_INTEL_ICH9_IGP_C }, + { PCI_VENDOR_INTEL, PCI_PRODUCT_INTEL_ICH9_IGP_M }, + { PCI_VENDOR_INTEL, PCI_PRODUCT_INTEL_ICH9_IGP_M_AMT } }; /********************************************************************* diff --git a/sys/dev/pci/if_em_hw.c b/sys/dev/pci/if_em_hw.c index 9285f58f6f5..eadfd67234f 100644 --- a/sys/dev/pci/if_em_hw.c +++ b/sys/dev/pci/if_em_hw.c @@ -31,7 +31,7 @@ *******************************************************************************/ -/* $OpenBSD: if_em_hw.c,v 1.30 2008/09/24 19:12:59 chl Exp $ */ +/* $OpenBSD: if_em_hw.c,v 1.31 2008/12/04 02:36:52 brad Exp $ */ /* if_em_hw.c * Shared functions for accessing and configuring the MAC @@ -460,6 +460,8 @@ em_set_mac_type(struct em_hw *hw) case E1000_DEV_ID_ICH9_IFE_GT: case E1000_DEV_ID_ICH9_IGP_AMT: case E1000_DEV_ID_ICH9_IGP_C: + case E1000_DEV_ID_ICH9_IGP_M: + case E1000_DEV_ID_ICH9_IGP_M_AMT: hw->mac_type = em_ich9lan; break; default: @@ -4048,6 +4050,15 @@ em_detect_gig_phy(struct em_hw *hw) return E1000_SUCCESS; } + /* until something better comes along... makes the Lenovo X200 work */ + if (hw->mac_type == em_ich9lan && + (hw->device_id == E1000_DEV_ID_ICH9_IGP_M || + hw->device_id == E1000_DEV_ID_ICH9_IGP_M_AMT)) { + hw->phy_id = IGP03E1000_E_PHY_ID; + hw->phy_type = em_phy_igp_3; + return E1000_SUCCESS; + } + /* ESB-2 PHY reads require em_phy_gg82563 to be set because of a work- * around that forces PHY page 0 to be set or the reads fail. The rest of * the code in this routine uses em_read_phy_reg to read the PHY ID. |