]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] [IPoIB] Handle sending of unicast RARP responses
authorHal Rosenstock <halr@voltaire.com>
Thu, 28 Jul 2005 20:17:26 +0000 (13:17 -0700)
committerRoland Dreier <roland@eddore.topspincom.com>
Thu, 28 Jul 2005 20:17:26 +0000 (13:17 -0700)
RARP replies are another valid case where IPoIB may need to send a
unicast packet with no neighbour structure.

Signed-off-by: Hal Rosenstock <halr@voltaire.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
drivers/infiniband/ulp/ipoib/ipoib_main.c

index 6f60abbaebd5602e472f625edc144af0d465aca8..fa00816a3cf7d31edb604481b810f445c2d7720e 100644 (file)
@@ -600,9 +600,10 @@ static int ipoib_start_xmit(struct sk_buff *skb, struct net_device *dev)
 
                        ipoib_mcast_send(dev, (union ib_gid *) (phdr->hwaddr + 4), skb);
                } else {
-                       /* unicast GID -- should be ARP reply */
+                       /* unicast GID -- should be ARP or RARP reply */
 
-                       if (be16_to_cpup((u16 *) skb->data) != ETH_P_ARP) {
+                       if ((be16_to_cpup((__be16 *) skb->data) != ETH_P_ARP) &&
+                           (be16_to_cpup((__be16 *) skb->data) != ETH_P_RARP)) {
                                ipoib_warn(priv, "Unicast, no %s: type %04x, QPN %06x "
                                           IPOIB_GID_FMT "\n",
                                           skb->dst ? "neigh" : "dst",