Revert to Fedora kernel-2.6.17-1.2187_FC5 patched with vs2.0.2.1; there are too many...
[linux-2.6.git] / drivers / infiniband / ulp / ipoib / ipoib.h
index 474aa21..12a1e05 100644 (file)
@@ -42,6 +42,7 @@
 #include <linux/netdevice.h>
 #include <linux/workqueue.h>
 #include <linux/pci.h>
+#include <linux/config.h>
 #include <linux/kref.h>
 #include <linux/if_infiniband.h>
 #include <linux/mutex.h>
@@ -212,7 +213,6 @@ struct ipoib_path {
 
 struct ipoib_neigh {
        struct ipoib_ah    *ah;
-       union ib_gid        dgid;
        struct sk_buff_head queue;
 
        struct neighbour   *neighbour;
@@ -272,7 +272,8 @@ int ipoib_dev_init(struct net_device *dev, struct ib_device *ca, int port);
 void ipoib_dev_cleanup(struct net_device *dev);
 
 void ipoib_mcast_join_task(void *dev_ptr);
-void ipoib_mcast_send(struct net_device *dev, void *mgid, struct sk_buff *skb);
+void ipoib_mcast_send(struct net_device *dev, union ib_gid *mgid,
+                     struct sk_buff *skb);
 
 void ipoib_mcast_restart_task(void *dev_ptr);
 int ipoib_mcast_start_thread(struct net_device *dev);
@@ -368,26 +369,15 @@ extern int ipoib_debug_level;
 #endif /* CONFIG_INFINIBAND_IPOIB_DEBUG_DATA */
 
 
-#define IPOIB_GID_FMT          "%2.2x%2.2x:%2.2x%2.2x:%2.2x%2.2x:%2.2x%2.2x:" \
-                               "%2.2x%2.2x:%2.2x%2.2x:%2.2x%2.2x:%2.2x%2.2x"
-
-#define IPOIB_GID_RAW_ARG(gid) ((u8 *)(gid))[0], \
-                               ((u8 *)(gid))[1], \
-                               ((u8 *)(gid))[2], \
-                               ((u8 *)(gid))[3], \
-                               ((u8 *)(gid))[4], \
-                               ((u8 *)(gid))[5], \
-                               ((u8 *)(gid))[6], \
-                               ((u8 *)(gid))[7], \
-                               ((u8 *)(gid))[8], \
-                               ((u8 *)(gid))[9], \
-                               ((u8 *)(gid))[10],\
-                               ((u8 *)(gid))[11],\
-                               ((u8 *)(gid))[12],\
-                               ((u8 *)(gid))[13],\
-                               ((u8 *)(gid))[14],\
-                               ((u8 *)(gid))[15]
-
-#define IPOIB_GID_ARG(gid)     IPOIB_GID_RAW_ARG((gid).raw)
+#define IPOIB_GID_FMT          "%x:%x:%x:%x:%x:%x:%x:%x"
+
+#define IPOIB_GID_ARG(gid)     be16_to_cpup((__be16 *) ((gid).raw +  0)), \
+                               be16_to_cpup((__be16 *) ((gid).raw +  2)), \
+                               be16_to_cpup((__be16 *) ((gid).raw +  4)), \
+                               be16_to_cpup((__be16 *) ((gid).raw +  6)), \
+                               be16_to_cpup((__be16 *) ((gid).raw +  8)), \
+                               be16_to_cpup((__be16 *) ((gid).raw + 10)), \
+                               be16_to_cpup((__be16 *) ((gid).raw + 12)), \
+                               be16_to_cpup((__be16 *) ((gid).raw + 14))
 
 #endif /* _IPOIB_H */