Re: [dm-devel] [PATCH v2 3/6] block: add iopoll method to support bio-based IO polling

2021-01-29 Thread JeffleXu
On 1/28/21 4:40 PM, Christoph Hellwig wrote: > On Mon, Jan 25, 2021 at 08:13:37PM +0800, Jeffle Xu wrote: >> +int blk_poll(struct request_queue *q, blk_qc_t cookie, bool spin) > > Can you split the guts of this function into two separate helpers > for the mq vs non-mq case? As is is is a

Re: [dm-devel] [PATCH v2 3/6] block: add iopoll method to support bio-based IO polling

2021-01-28 Thread Christoph Hellwig
On Thu, Jan 28, 2021 at 07:52:05PM +0800, JeffleXu wrote: > > > On 1/28/21 4:40 PM, Christoph Hellwig wrote: > > On Mon, Jan 25, 2021 at 08:13:37PM +0800, Jeffle Xu wrote: > >> +int blk_poll(struct request_queue *q, blk_qc_t cookie, bool spin) > > > > Can you split the guts of this function

Re: [dm-devel] [PATCH v2 3/6] block: add iopoll method to support bio-based IO polling

2021-01-28 Thread Christoph Hellwig
On Mon, Jan 25, 2021 at 08:13:37PM +0800, Jeffle Xu wrote: > +int blk_poll(struct request_queue *q, blk_qc_t cookie, bool spin) Can you split the guts of this function into two separate helpers for the mq vs non-mq case? As is is is a little hard to read and introduced extra branches in the fast

Re: [dm-devel] [PATCH v2 3/6] block: add iopoll method to support bio-based IO polling

2021-01-27 Thread Mike Snitzer
On Mon, Jan 25 2021 at 7:13am -0500, Jeffle Xu wrote: > ->poll_fn was introduced in commit ea435e1b9392 ("block: add a poll_fn > callback to struct request_queue") to support bio-based queues such as > nvme multipath, but was later removed in commit 529262d56dbe ("block: > remove ->poll_fn"). >

[dm-devel] [PATCH v2 3/6] block: add iopoll method to support bio-based IO polling

2021-01-26 Thread Jeffle Xu
->poll_fn was introduced in commit ea435e1b9392 ("block: add a poll_fn callback to struct request_queue") to support bio-based queues such as nvme multipath, but was later removed in commit 529262d56dbe ("block: remove ->poll_fn"). Given commit c62b37d96b6e ("block: move ->make_request_fn to