diff options
author | Sean Hefty <sean.hefty@intel.com> | 2007-02-16 02:00:17 +0100 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2007-02-16 23:20:02 +0100 |
commit | faec2f7b96b555055d0aa6cc6b83a537270bed52 (patch) | |
tree | 0916cb780a1a5d5fe2ac98364917c79f25d57fcf /include/rdma/ib_addr.h | |
parent | IPoIB: CM error handling thinko fix (diff) | |
download | linux-faec2f7b96b555055d0aa6cc6b83a537270bed52.tar.xz linux-faec2f7b96b555055d0aa6cc6b83a537270bed52.zip |
IB/sa: Track multicast join/leave requests
The IB SA tracks multicast join/leave requests on a per port basis and
does not do any reference counting: if two users of the same port join
the same group, and one leaves that group, then the SA will remove the
port from the group even though there is one user who wants to stay a
member left. Therefore, in order to support multiple users of the
same multicast group from the same port, we need to perform reference
counting locally.
To do this, add an multicast submodule to ib_sa to perform reference
counting of multicast join/leave operations. Modify ib_ipoib (the
only in-kernel user of multicast) to use the new interface.
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'include/rdma/ib_addr.h')
-rw-r--r-- | include/rdma/ib_addr.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/rdma/ib_addr.h b/include/rdma/ib_addr.h index c094e5012862..c36750ff6ae8 100644 --- a/include/rdma/ib_addr.h +++ b/include/rdma/ib_addr.h @@ -110,6 +110,12 @@ static inline void ib_addr_set_pkey(struct rdma_dev_addr *dev_addr, u16 pkey) dev_addr->broadcast[9] = (unsigned char) pkey; } +static inline void ib_addr_get_mgid(struct rdma_dev_addr *dev_addr, + union ib_gid *gid) +{ + memcpy(gid, dev_addr->broadcast + 4, sizeof *gid); +} + static inline void ib_addr_get_sgid(struct rdma_dev_addr *dev_addr, union ib_gid *gid) { |