Lines Matching refs:gid
99 union ib_gid *gid) in ib_addr_get_mgid() argument
101 memcpy(gid, dev_addr->broadcast + 4, sizeof *gid); in ib_addr_get_mgid()
114 static inline int rdma_ip2gid(struct sockaddr *addr, union ib_gid *gid) in rdma_ip2gid() argument
120 (struct in6_addr *)gid); in rdma_ip2gid()
123 *(struct in6_addr *)&gid->raw = in rdma_ip2gid()
133 static inline void rdma_gid2ip(struct sockaddr *out, const union ib_gid *gid) in rdma_gid2ip() argument
135 if (ipv6_addr_v4mapped((struct in6_addr *)gid)) { in rdma_gid2ip()
139 memcpy(&out_in->sin_addr.s_addr, gid->raw + 12, 4); in rdma_gid2ip()
144 memcpy(&out_in->sin6_addr.s6_addr, gid->raw, 16); in rdma_gid2ip()
153 static inline void rdma_addr_get_sgid(struct rdma_dev_addr *dev_addr, union ib_gid *gid) in rdma_addr_get_sgid() argument
155 memcpy(gid, dev_addr->src_dev_addr + rdma_addr_gid_offset(dev_addr), in rdma_addr_get_sgid()
156 sizeof(*gid)); in rdma_addr_get_sgid()
159 static inline void rdma_addr_set_sgid(struct rdma_dev_addr *dev_addr, union ib_gid *gid) in rdma_addr_set_sgid() argument
161 memcpy(dev_addr->src_dev_addr + rdma_addr_gid_offset(dev_addr), gid, sizeof *gid); in rdma_addr_set_sgid()
164 static inline void rdma_addr_get_dgid(struct rdma_dev_addr *dev_addr, union ib_gid *gid) in rdma_addr_get_dgid() argument
166 memcpy(gid, dev_addr->dst_dev_addr + rdma_addr_gid_offset(dev_addr), sizeof *gid); in rdma_addr_get_dgid()
169 static inline void rdma_addr_set_dgid(struct rdma_dev_addr *dev_addr, union ib_gid *gid) in rdma_addr_set_dgid() argument
171 memcpy(dev_addr->dst_dev_addr + rdma_addr_gid_offset(dev_addr), gid, sizeof *gid); in rdma_addr_set_dgid()