[openib-general] [PATCH/iproute2] Add support for IP-over-InfiniBand

Roland Dreier roland at topspin.com
Wed Feb 9 09:12:03 PST 2005


This trivial patch adds support for displaying InfiniBand link
addresses.  With the patch, output of "ip addr" changes from

    15: ib0: <BROADCAST,MULTICAST,UP> mtu 2044 qdisc pfifo_fast qlen 128
        link/[32] 00:00:04:04:fe:80:00:00:00:00:00:00:00:02:c9:01:07:8c:e4:61 brd 00:ff:ff:ff:ff:12:40:1b:ff:ff:00:00:00:00:00:00:ff:ff:ff:ff

to

    15: ib0: <BROADCAST,MULTICAST,UP> mtu 2044 qdisc pfifo_fast qlen 128
        link/infiniband 00:00:04:04:fe:80:00:00:00:00:00:00:00:02:c9:01:07:8c:e4:61 brd 00:ff:ff:ff:ff:12:40:1b:ff:ff:00:00:00:00:00:00:ff:ff:ff:ff

(Recent libc headers have ARPHRD_INFINIBAND defined -- for example,
they are in libc6-dev on my Debian Sarge system)

Thanks,
  Roland

--- iproute2-050207.orig/lib/ll_types.c	2005-02-07 10:37:20.000000000 -0800
+++ iproute2-050207/lib/ll_types.c	2005-02-08 21:40:10.000000000 -0800
@@ -55,6 +55,9 @@
 #ifdef ARPHRD_IEEE1394
 __PF(IEEE1394,ieee1394)
 #endif
+#ifdef ARPHRD_INFINIBAND
+__PF(INFINIBAND,infiniband)
+#endif
 
 __PF(SLIP,slip)
 __PF(CSLIP,cslip)



More information about the general mailing list