diff mbox series

[RFC,2/2] RDMA/rxe: set RXE_PAGE_SIZE_CAP to PAGE_SIZE

Message ID 20231027054154.2935054-2-lizhijian@fujitsu.com (mailing list archive)
State RFC
Headers show
Series [RFC,1/2] RDMA/rxe: don't allow registering !PAGE_SIZE mr | expand

Commit Message

Zhijian Li (Fujitsu) Oct. 27, 2023, 5:41 a.m. UTC
RXE_PAGE_SIZE_CAP means the MR page size supported by RXE. However
in current RXE implementation, only PAGE_SIZE MR works well.
So change it to PAGE_SIZE only.

ULPs such as SRP calculating the page size according to this attribute get
worked again with this change.

Signed-off-by: Li Zhijian <lizhijian@fujitsu.com>
---
 drivers/infiniband/sw/rxe/rxe_param.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Bart Van Assche Oct. 27, 2023, 9:47 p.m. UTC | #1
On 10/26/23 22:41, Li Zhijian wrote:
> diff --git a/drivers/infiniband/sw/rxe/rxe_param.h b/drivers/infiniband/sw/rxe/rxe_param.h
> index d2f57ead78ad..b1cf1e1c0ce1 100644
> --- a/drivers/infiniband/sw/rxe/rxe_param.h
> +++ b/drivers/infiniband/sw/rxe/rxe_param.h
> @@ -38,7 +38,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_PAGE_SIZE_CAP		= 0xfffff000,
> +	RXE_PAGE_SIZE_CAP		= PAGE_SIZE,
>   	RXE_MAX_QP_WR			= DEFAULT_MAX_VALUE,
>   	RXE_DEVICE_CAP_FLAGS		= IB_DEVICE_BAD_PKEY_CNTR
>   					| IB_DEVICE_BAD_QKEY_CNTR

Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Zhu Yanjun Oct. 28, 2023, 3:52 a.m. UTC | #2
在 2023/10/27 13:41, Li Zhijian 写道:
> RXE_PAGE_SIZE_CAP means the MR page size supported by RXE. However
> in current RXE implementation, only PAGE_SIZE MR works well.
> So change it to PAGE_SIZE only.
> 
> ULPs such as SRP calculating the page size according to this attribute get
> worked again with this change.
> 
> Signed-off-by: Li Zhijian <lizhijian@fujitsu.com>
Acked-by: Zhu Yanjun <zyjzyj2000@gmail.com>

Thanks a lot.
Zhu Yanjun

> ---
>   drivers/infiniband/sw/rxe/rxe_param.h | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/infiniband/sw/rxe/rxe_param.h b/drivers/infiniband/sw/rxe/rxe_param.h
> index d2f57ead78ad..b1cf1e1c0ce1 100644
> --- a/drivers/infiniband/sw/rxe/rxe_param.h
> +++ b/drivers/infiniband/sw/rxe/rxe_param.h
> @@ -38,7 +38,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_PAGE_SIZE_CAP		= 0xfffff000,
> +	RXE_PAGE_SIZE_CAP		= PAGE_SIZE,
>   	RXE_MAX_QP_WR			= DEFAULT_MAX_VALUE,
>   	RXE_DEVICE_CAP_FLAGS		= IB_DEVICE_BAD_PKEY_CNTR
>   					| IB_DEVICE_BAD_QKEY_CNTR
diff mbox series

Patch

diff --git a/drivers/infiniband/sw/rxe/rxe_param.h b/drivers/infiniband/sw/rxe/rxe_param.h
index d2f57ead78ad..b1cf1e1c0ce1 100644
--- a/drivers/infiniband/sw/rxe/rxe_param.h
+++ b/drivers/infiniband/sw/rxe/rxe_param.h
@@ -38,7 +38,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_PAGE_SIZE_CAP		= 0xfffff000,
+	RXE_PAGE_SIZE_CAP		= PAGE_SIZE,
 	RXE_MAX_QP_WR			= DEFAULT_MAX_VALUE,
 	RXE_DEVICE_CAP_FLAGS		= IB_DEVICE_BAD_PKEY_CNTR
 					| IB_DEVICE_BAD_QKEY_CNTR