thanks, I decided that there was no point in having these defines so I
just did it like the kernel:

commit 040743fb06cf2abf9f302ee6f5870fd3fe944868
Author: Roland Dreier <[EMAIL PROTECTED]>
Date:   Mon Jul 2 20:45:40 2007 -0700

    Add new device IDs for PCIe gen2 HCAs
    
    Also just use hex device IDs plus comments instead of creating defines
    that are only used once.
    
    Signed-off-by: Roland Dreier <[EMAIL PROTECTED]>

diff --git a/src/mlx4.c b/src/mlx4.c
index 3684b50..b2e2ba9 100644
--- a/src/mlx4.c
+++ b/src/mlx4.c
@@ -53,29 +53,19 @@
 #define PCI_VENDOR_ID_MELLANOX                 0x15b3
 #endif
 
-#ifndef PCI_DEVICE_ID_MELLANOX_HERMON_SDR
-#define PCI_DEVICE_ID_MELLANOX_HERMON_SDR      0x6340
-#endif
-
-#ifndef PCI_DEVICE_ID_MELLANOX_HERMON_DDR
-#define PCI_DEVICE_ID_MELLANOX_HERMON_DDR      0x634a
-#endif
-
-#ifndef PCI_DEVICE_ID_MELLANOX_HERMON_QDR
-#define PCI_DEVICE_ID_MELLANOX_HERMON_QDR      0x6354
-#endif
-
 #define HCA(v, d) \
        { .vendor = PCI_VENDOR_ID_##v,                  \
-         .device = PCI_DEVICE_ID_MELLANOX_##d }
+         .device = d }
 
 struct {
        unsigned                vendor;
        unsigned                device;
 } hca_table[] = {
-       HCA(MELLANOX, HERMON_SDR),
-       HCA(MELLANOX, HERMON_DDR),
-       HCA(MELLANOX, HERMON_QDR),
+       HCA(MELLANOX, 0x6340),  /* MT25408 "Hermon" SDR */
+       HCA(MELLANOX, 0x634a),  /* MT25408 "Hermon" DDR */
+       HCA(MELLANOX, 0x6354),  /* MT25408 "Hermon" QDR */
+       HCA(MELLANOX, 0x6732),  /* MT25408 "Hermon" DDR PCIe gen2 */
+       HCA(MELLANOX, 0x673c),  /* MT25408 "Hermon" QDR PCIe gen2 */
 };
 
 static struct ibv_context_ops mlx4_ctx_ops = {
_______________________________________________
general mailing list
[email protected]
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general

To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general

Reply via email to