[PATCH v2 21/26] staging/lustre: Inline ib_dma_map_*() functions
From: Bart Van Assche
Date: Thu Jan 12 2017 - 14:13:30 EST
Signed-off-by: Bart Van Assche <bart.vanassche@xxxxxxxxxxx>
Reviewed-by: Christoph Hellwig <hch@xxxxxx>
Reviewed-by: Sagi Grimberg <sagi@xxxxxxxxxxx>
Cc: Oleg Drokin <oleg.drokin@xxxxxxxxx>
Cc: Andreas Dilger <andreas.dilger@xxxxxxxxx>
Cc: James Simmons <jsimmons@xxxxxxxxxxxxx>
---
drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h b/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h
index 14576977200f..f2c0c60eee1d 100644
--- a/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h
+++ b/drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.h
@@ -925,21 +925,21 @@ kiblnd_rd_msg_size(struct kib_rdma_desc *rd, int msgtype, int n)
static inline __u64
kiblnd_dma_mapping_error(struct ib_device *dev, u64 dma_addr)
{
- return ib_dma_mapping_error(dev, dma_addr);
+ return dma_mapping_error(dev->dma_device, dma_addr);
}
static inline __u64 kiblnd_dma_map_single(struct ib_device *dev,
void *msg, size_t size,
enum dma_data_direction direction)
{
- return ib_dma_map_single(dev, msg, size, direction);
+ return dma_map_single(dev->dma_device, msg, size, direction);
}
static inline void kiblnd_dma_unmap_single(struct ib_device *dev,
__u64 addr, size_t size,
enum dma_data_direction direction)
{
- ib_dma_unmap_single(dev, addr, size, direction);
+ dma_unmap_single(dev->dma_device, addr, size, direction);
}
#define KIBLND_UNMAP_ADDR_SET(p, m, a) do {} while (0)
@@ -949,26 +949,26 @@ static inline int kiblnd_dma_map_sg(struct ib_device *dev,
struct scatterlist *sg, int nents,
enum dma_data_direction direction)
{
- return ib_dma_map_sg(dev, sg, nents, direction);
+ return dma_map_sg(dev->dma_device, sg, nents, direction);
}
static inline void kiblnd_dma_unmap_sg(struct ib_device *dev,
struct scatterlist *sg, int nents,
enum dma_data_direction direction)
{
- ib_dma_unmap_sg(dev, sg, nents, direction);
+ dma_unmap_sg(dev->dma_device, sg, nents, direction);
}
static inline __u64 kiblnd_sg_dma_address(struct ib_device *dev,
struct scatterlist *sg)
{
- return ib_sg_dma_address(dev, sg);
+ return sg_dma_address(sg);
}
static inline unsigned int kiblnd_sg_dma_len(struct ib_device *dev,
struct scatterlist *sg)
{
- return ib_sg_dma_len(dev, sg);
+ return sg_dma_len(sg);
}
/* XXX We use KIBLND_CONN_PARAM(e) as writable buffer, it's not strictly */
--
2.11.0