Use IDs from pcidevs.h
authorSepherosa Ziehau <sephe@dragonflybsd.org>
Sat, 13 Sep 2008 02:30:37 +0000 (02:30 +0000)
committerSepherosa Ziehau <sephe@dragonflybsd.org>
Sat, 13 Sep 2008 02:30:37 +0000 (02:30 +0000)
sys/dev/netif/jme/if_jme.c
sys/dev/netif/jme/if_jmereg.h

index 2211bd9..1f09b72 100644 (file)
@@ -25,7 +25,7 @@
  * SUCH DAMAGE.
  *
  * $FreeBSD: src/sys/dev/jme/if_jme.c,v 1.2 2008/07/18 04:20:48 yongari Exp $
- * $DragonFly: src/sys/dev/netif/jme/if_jme.c,v 1.2 2008/08/03 11:00:32 sephe Exp $
+ * $DragonFly: src/sys/dev/netif/jme/if_jme.c,v 1.3 2008/09/13 02:30:37 sephe Exp $
  */
 
 #include "opt_ethernet.h"
@@ -133,9 +133,9 @@ static const struct jme_dev {
        uint16_t        jme_deviceid;
        const char      *jme_name;
 } jme_devs[] = {
-       { VENDORID_JMICRON, DEVICEID_JMC250,
+       { PCI_VENDOR_JMICRON, PCI_PRODUCT_JMICRON_JMC250,
            "JMicron Inc, JMC250 Gigabit Ethernet" },
-       { VENDORID_JMICRON, DEVICEID_JMC260,
+       { PCI_VENDOR_JMICRON, PCI_PRODUCT_JMICRON_JMC260,
            "JMicron Inc, JMC260 Fast Ethernet" },
        { 0, 0, NULL }
 };
@@ -422,7 +422,7 @@ jme_probe(device_t dev)
        for (sp = jme_devs; sp->jme_name != NULL; ++sp) {
                if (vid == sp->jme_vendorid && did == sp->jme_deviceid) {
                        device_set_desc(dev, sp->jme_name);
-                       if (vid == DEVICEID_JMC260) {
+                       if (vid == PCI_PRODUCT_JMICRON_JMC260) {
                                struct jme_softc *sc = device_get_softc(dev);
                                sc->jme_flags = JME_FLAG_FASTETH |
                                                JME_FLAG_NOJUMBO;
index 0c53c62..a921a2a 100644 (file)
  * SUCH DAMAGE.
  *
  * $FreeBSD: src/sys/dev/jme/if_jmereg.h,v 1.1 2008/05/27 01:42:01 yongari Exp $
- * $DragonFly: src/sys/dev/netif/jme/if_jmereg.h,v 1.1 2008/07/26 14:00:31 sephe Exp $
+ * $DragonFly: src/sys/dev/netif/jme/if_jmereg.h,v 1.2 2008/09/13 02:30:37 sephe Exp $
  */
 
 #ifndef        _IF_JMEREG_H
 #define        _IF_JMEREG_H
 
-/*
- * JMicron Inc. PCI vendor ID
- */
-#define        VENDORID_JMICRON        0x197B
-
-/*
- * JMC250 PCI device ID
- */
-#define        DEVICEID_JMC250         0x0250
-#define        DEVICEREVID_JMC250      0x10
-
-/*
- * JMC260 PCI device ID
- */
-#define        DEVICEID_JMC260         0x0260
-#define        DEVICEREVID_JMC260      0x20
-
 /* JMC250 PCI configuration register. */
 #define JME_PCIR_BAR           PCIR_BAR(0)