@@ -36,6 +36,7 @@ static inline enum ib_mtu eth_mtu_int_to_enum(int mtu)
/* default/initial rxe device parameter settings */
enum rxe_device_param {
RXE_MAX_MR_SIZE = -1ull,
+ RXE_MAX_SEG_SIZE = SZ_1G,
RXE_PAGE_SIZE_CAP = 0xfffff000,
RXE_MAX_QP = 0x10000,
RXE_MAX_QP_WR = 0x4000,
@@ -1129,7 +1129,7 @@ int rxe_register_device(struct rxe_dev *rxe, const char *ibdev_name)
addrconf_addr_eui48((unsigned char *)&dev->node_guid,
rxe->ndev->dev_addr);
dev->dev.dma_parms = &rxe->dma_parms;
- dma_set_max_seg_size(&dev->dev, UINT_MAX);
+ dma_set_max_seg_size(&dev->dev, RXE_MAX_SEG_SIZE);
dma_set_coherent_mask(&dev->dev, dma_get_required_mask(&dev->dev));
dev->uverbs_cmd_mask = BIT_ULL(IB_USER_VERBS_CMD_GET_CONTEXT)
With the recent change to __sg_alloc_table_from_page the old value for max_seg_size is no longer valid. Change to a new parameter RXE_MAX_SEG_SIZE wich is set to 1G. Signed-off-by: Bob Pearson <rpearson@hpe.com> --- drivers/infiniband/sw/rxe/rxe_param.h | 1 + drivers/infiniband/sw/rxe/rxe_verbs.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-)