Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1439436
| From | Lars Ellenberg <lars.ellenberg@linbit.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion |
| Date | 2016-07-08 15:10 +0200 |
| Message-ID | <rSDHA-5cy-27@gated-at.bofh.it> (permalink) |
| References | (1 earlier) <rSacy-2D8-23@gated-at.bofh.it> <rScHo-4lY-5@gated-at.bofh.it> <rSpEB-4pQ-5@gated-at.bofh.it> <rSz1f-26t-3@gated-at.bofh.it> <rSAA2-2Xn-27@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Fri, Jul 08, 2016 at 07:39:36PM +1000, NeilBrown wrote:
> >> To make the patch "perfect", and maybe even more elegant we could treat
> >> ->remainder and ->recursion more alike.
> >> i.e.:
> >> - generic make request has a private "stack" of requests.
> >> - before calling ->make_request_fn(), both ->remainder and ->recursion
> >> are initialised
> >> - after ->make_request_fn(), ->remainder are spliced in to top of
> >> 'stack', then ->recursion is spliced onto that.
> >> - If stack is not empty, the top request is popped and we loop to top.
> >>
> >> This reliably follows in-order execution, and handles siblings correctly
> >> (in submitted order) if/when a request splits off multiple siblings.
> >
> > The only splitting that creates siblings on the current level
> > is blk_queue_split(), which splits the current bio into
> > "front piece" and "remainder", already processed in this order.
>
> Yes.
> I imagine that a driver *could* split a bio into three parts with a
> single allocation, but I cannot actually see any point in doing it. So
> I was over-complicating things.
>
> >
> > Anything else creating "siblings" is not creating siblings for the
> > current layer, but for the next deeper layer, which are queue on
> > "recursion" and also processed in the order they have been generated.
> >
> >> I think that as long a requests are submitted in the order they are
> >> created at each level there is no reason to expect performance
> >> regressions.
> >> All we are doing is changing the ordering between requests generated at
> >> different levels, and I think we are restoring a more natural order.
> >
> > I believe both patches combined are doing exactly this already.
> > I could rename .remainder to .todo or .incoming, though.
>
> :-) neither "remainder" or "recursion" seem like brilliant names to me,
> but I don't have anything better to suggest. Naming is hard!
> As long as a comment explains the name clearly I could cope with X and Y.
...
> I think we just might be in violent agreement.
I thought so, too :-)
Should I merge both patches,
rename to ".queue" and ".tmp",
and submit for inclusion?
Lars Ellenberg
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion NeilBrown <neilb@suse.com> - 2016-07-07 07:40 +0200
Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion Lars Ellenberg <lars.ellenberg@linbit.com> - 2016-07-07 10:20 +0200
Re: block: fix blk_queue_split() resource exhaustion Mike Snitzer <snitzer@redhat.com> - 2016-07-07 14:50 +0200
Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion Lars Ellenberg <lars.ellenberg@linbit.com> - 2016-07-07 14:50 +0200
Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion NeilBrown <neilb@suse.com> - 2016-07-08 00:10 +0200
Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion Lars Ellenberg <lars.ellenberg@linbit.com> - 2016-07-08 10:10 +0200
Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion NeilBrown <neilb@suse.com> - 2016-07-08 11:50 +0200
Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion Lars Ellenberg <lars.ellenberg@linbit.com> - 2016-07-08 15:10 +0200
Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion Ming Lei <ming.lei@canonical.com> - 2016-07-08 13:10 +0200
Re: [dm-devel] [RFC] block: fix blk_queue_split() resource exhaustion Lars Ellenberg <lars.ellenberg@linbit.com> - 2016-07-08 15:00 +0200
Re: block: fix blk_queue_split() resource exhaustion Mike Snitzer <snitzer@redhat.com> - 2016-07-08 15:10 +0200
Re: block: fix blk_queue_split() resource exhaustion Mike Snitzer <snitzer@redhat.com> - 2016-07-07 14:50 +0200
Re: block: fix blk_queue_split() resource exhaustion NeilBrown <neilb@suse.com> - 2016-07-08 00:50 +0200
csiph-web