[ipoib] fix for receiving mcast and bcast. (mlnx: 3023)
authortzachid <tzachid@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Sun, 24 Aug 2008 08:11:57 +0000 (08:11 +0000)
committertzachid <tzachid@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Sun, 24 Aug 2008 08:11:57 +0000 (08:11 +0000)
signed off by: Slava Strebkov [slavas@voltaire.com]

git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@1497 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

ulp/ipoib/kernel/ipoib_port.c

index e438999..97da803 100644 (file)
@@ -2160,9 +2160,16 @@ __recv_gen(
        p_eth->hdr.src = p_src->mac;\r
        p_eth->hdr.dst = p_dst->mac;\r
 \r
-       if (p_dst->h_mcast) {\r
-               p_dst->is_in_use = TRUE;\r
+       if ( p_eth->hdr.dst.addr[0] == 1 && \r
+                p_eth->hdr.type == ETH_PROT_TYPE_IP &&\r
+                p_eth->hdr.dst.addr[2] == 0x5E)  \r
+       {\r
+               p_eth->hdr.dst.addr[1] = 0;\r
+               p_eth->hdr.dst.addr[3] = p_eth->hdr.dst.addr[3] & 0x7f;\r
        }\r
+       if (p_dst->h_mcast)\r
+               p_dst->is_in_use = TRUE;\r
+\r
        IPOIB_EXIT( IPOIB_DBG_RECV );\r
        return IB_SUCCESS;\r
 }\r
@@ -5988,7 +5995,7 @@ __leave_error_mcast_cb(
 \r
 static void __port_do_mcast_garbage(ipoib_port_t* const        p_port)\r
 {\r
-    const mac_addr_t DEFAULT_MCAST_GROUP = {0x01, 0x00, 0x5e, 0x00, 0x00, 0x01};\r
+    const mac_addr_t DEFAULT_MCAST_GROUP = {0x01, 0x00, 0x5E, 0x00, 0x00, 0x01};\r
        /* Do garbage collecting... */\r
 \r
        cl_map_item_t   *p_item;\r