[PATCH] IPoIB: Set full membership bit in P_Keys

Always make sure that the full membership bit is set in the P_Keys
that IPoIB uses. This makes sure that all hosts join the correct
multicast groups so that hosts that are partial partition members
can talk to the rest of the network.

Signed-off-by: Roland Dreier <rolandd@cisco.com>

authored by

Roland Dreier and committed by
Roland Dreier
4ce05937 ec34a922

+12
+12
drivers/infiniband/ulp/ipoib/ipoib_main.c
··· 883 if (pkey < 0 || pkey > 0xffff) 884 return -EINVAL; 885 886 ret = ipoib_vlan_add(container_of(cdev, struct net_device, class_dev), 887 pkey); 888 ··· 940 hca->name, port, result); 941 goto alloc_mem_failed; 942 } 943 944 priv->dev->broadcast[8] = priv->pkey >> 8; 945 priv->dev->broadcast[9] = priv->pkey & 0xff;
··· 883 if (pkey < 0 || pkey > 0xffff) 884 return -EINVAL; 885 886 + /* 887 + * Set the full membership bit, so that we join the right 888 + * broadcast group, etc. 889 + */ 890 + pkey |= 0x8000; 891 + 892 ret = ipoib_vlan_add(container_of(cdev, struct net_device, class_dev), 893 pkey); 894 ··· 934 hca->name, port, result); 935 goto alloc_mem_failed; 936 } 937 + 938 + /* 939 + * Set the full membership bit, so that we join the right 940 + * broadcast group, etc. 941 + */ 942 + priv->pkey |= 0x8000; 943 944 priv->dev->broadcast[8] = priv->pkey >> 8; 945 priv->dev->broadcast[9] = priv->pkey & 0xff;