public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Zhu Yanjun <yanjun.zhu@linux.dev>
To: Bart Van Assche <bvanassche@acm.org>,
	Li Zhijian <lizhijian@fujitsu.com>,
	zyjzyj2000@gmail.com, jgg@ziepe.ca, leon@kernel.org,
	linux-rdma@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, rpearsonhpe@gmail.com,
	matsuda-daisuke@fujitsu.com
Subject: Re: [PATCH RFC 1/2] RDMA/rxe: don't allow registering !PAGE_SIZE mr
Date: Sun, 29 Oct 2023 11:22:53 +0800	[thread overview]
Message-ID: <b5085c19-490e-4c0a-8c89-03d646876c8f@linux.dev> (raw)
In-Reply-To: <a344b3b0-a43f-47eb-b5e4-9d54cda62518@acm.org>

在 2023/10/29 7:07, Bart Van Assche 写道:
> On 10/27/23 19:48, Zhu Yanjun wrote:
>> In this case, ULP with folio will not work well with current RXE after 
>> this commit is applied.
> 
> Why not? RDMA ULPs like the SRP initiator driver use ib_map_mr_sg(). The
> latter function calls rxe_map_mr_sg() if the RXE driver is used. 
> rxe_map_mr_sg() calls ib_sg_to_pages(). ib_sg_to_pages() translates
> SG-entries that are larger than a virtual memory page into multiple
> entries with size mr->page_size.

It seems that we are not on the same page. I am thinking that this fix 
should also work for the future folio. And your idea is based on the 
current implementation.

Perhaps it is not a good time to discuss folio currently. Let me focus 
on the current implementation.

In this commit, if the page size is not equal to PAGE_SIZE, it will pop 
out warning then exit. So "rxe_info_mr" should be changed to rxe_warning_mr?

In fact, I like to remove the page size assignment in rxe, that is, 
partly reverting the commit 325a7eb85199 ("RDMA/rxe: Cleanup page 
variables in rxe_mr.c"). But it seems that Jason did not like this.
I no longer insist on this.

I am not sure whether Jason, Leon, Bob and you have better solution to 
this problem or not.

If not, this commit can fix this problem if no better solution.

Reviewed-by: Zhu Yanjun <yanjun.zhu@linux.dev>

Thanks,
Zhu Yanjun

> 
> Thanks,
> 
> Bart.
> 


  reply	other threads:[~2023-10-29  3:23 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-27  5:41 [PATCH RFC 1/2] RDMA/rxe: don't allow registering !PAGE_SIZE mr Li Zhijian
2023-10-27  5:41 ` [PATCH RFC 2/2] RDMA/rxe: set RXE_PAGE_SIZE_CAP to PAGE_SIZE Li Zhijian
2023-10-27 21:47   ` Bart Van Assche
2023-10-28  3:52   ` Zhu Yanjun
2023-10-27  8:17 ` [PATCH RFC 1/2] RDMA/rxe: don't allow registering !PAGE_SIZE mr Zhu Yanjun
2023-10-27 21:46   ` Bart Van Assche
2023-10-28  2:48     ` Zhu Yanjun
2023-10-28 23:07       ` Bart Van Assche
2023-10-29  3:22         ` Zhu Yanjun [this message]
2023-10-30  8:13   ` Zhijian Li (Fujitsu)
2023-10-30  9:43     ` Zhu Yanjun
2023-10-30  7:51 ` Zhijian Li (Fujitsu)
2023-10-30 12:40   ` Jason Gunthorpe
2023-10-31  8:52     ` Zhu Yanjun
2023-10-31 13:19       ` Jason Gunthorpe
2023-11-01  0:58         ` Greg Sword
2023-10-31  9:59     ` Zhijian Li (Fujitsu)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b5085c19-490e-4c0a-8c89-03d646876c8f@linux.dev \
    --to=yanjun.zhu@linux.dev \
    --cc=bvanassche@acm.org \
    --cc=jgg@ziepe.ca \
    --cc=leon@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=lizhijian@fujitsu.com \
    --cc=matsuda-daisuke@fujitsu.com \
    --cc=rpearsonhpe@gmail.com \
    --cc=zyjzyj2000@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox