RDMA: iWARP Core Changes.
Modifications to the existing rdma header files, core files, drivers, and ulp files to support iWARP, including: - Hook iWARP CM into the build system and use it in rdma_cm. - Convert enum ib_node_type to enum rdma_node_type, which includes the possibility of RDMA_NODE_RNIC, and update everything for this. Signed-off-by: Tom Tucker <tom@opengridcomputing.com> Signed-off-by: Steve Wise <swise@opengridcomputing.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
This commit is contained in:
committed by
Roland Dreier
parent
922a8e9fb2
commit
07ebafbaaa
@@ -40,7 +40,7 @@ struct rdma_dev_addr {
|
||||
unsigned char src_dev_addr[MAX_ADDR_LEN];
|
||||
unsigned char dst_dev_addr[MAX_ADDR_LEN];
|
||||
unsigned char broadcast[MAX_ADDR_LEN];
|
||||
enum ib_node_type dev_type;
|
||||
enum rdma_node_type dev_type;
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -72,6 +72,9 @@ int rdma_resolve_ip(struct sockaddr *src_addr, struct sockaddr *dst_addr,
|
||||
|
||||
void rdma_addr_cancel(struct rdma_dev_addr *addr);
|
||||
|
||||
int rdma_copy_addr(struct rdma_dev_addr *dev_addr, struct net_device *dev,
|
||||
const unsigned char *dst_dev_addr);
|
||||
|
||||
static inline int ip_addr_size(struct sockaddr *addr)
|
||||
{
|
||||
return addr->sa_family == AF_INET6 ?
|
||||
@@ -113,4 +116,16 @@ static inline void ib_addr_set_dgid(struct rdma_dev_addr *dev_addr,
|
||||
memcpy(dev_addr->dst_dev_addr + 4, gid, sizeof *gid);
|
||||
}
|
||||
|
||||
static inline void iw_addr_get_sgid(struct rdma_dev_addr *dev_addr,
|
||||
union ib_gid *gid)
|
||||
{
|
||||
memcpy(gid, dev_addr->src_dev_addr, sizeof *gid);
|
||||
}
|
||||
|
||||
static inline void iw_addr_get_dgid(struct rdma_dev_addr *dev_addr,
|
||||
union ib_gid *gid)
|
||||
{
|
||||
memcpy(gid, dev_addr->dst_dev_addr, sizeof *gid);
|
||||
}
|
||||
|
||||
#endif /* IB_ADDR_H */
|
||||
|
||||
Reference in New Issue
Block a user