Whamcloud - gitweb
LU-10391 lnet: switch LNetIsPeerLocal() to take 16-byte addr
[fs/lustre-release.git] / lnet / include / lnet / lnet_rdma.h
1 #ifndef LNET_RDMA_H
2 #define LNET_RDMA_H
3
4 struct device;
5 struct page;
6 enum dma_data_direction;
7 struct scatterlist;
8
9 struct nvfs_dma_rw_ops;
10
11 int REGISTER_FUNC (struct nvfs_dma_rw_ops *ops);
12
13 void UNREGISTER_FUNC (void);
14
15 unsigned int lnet_get_dev_prio(struct device *dev,
16                                unsigned int dev_idx);
17 int lnet_rdma_map_sg_attrs(struct device *dev, struct scatterlist *sg,
18                            int nents, enum dma_data_direction direction);
19 int lnet_rdma_unmap_sg(struct device *dev,
20                        struct scatterlist *sg, int nents,
21                        enum dma_data_direction direction);
22 bool lnet_is_rdma_only_page(struct page *page);
23 unsigned int lnet_get_dev_idx(struct page *page);
24
25 /* DMA_ATTR_NO_WARN was added to kernel v4.8-11962-ga9a62c9 */
26 #ifndef DMA_ATTR_NO_WARN
27 #define DMA_ATTR_NO_WARN 0
28 #endif
29
30 #endif /* LUSTRE_NVFS_H */
31