[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CANr-nt0DHudD9TFBqLzhgBuYz8GqVbwgiU7W2b5OVsLtpMuu_w@mail.gmail.com>
Date: Fri, 15 Mar 2019 09:34:14 +0100
From: Hans Holmberg <hans@...tronix.com>
To: Heiner Litz <hlitz@...c.edu>
Cc: Javier González <javier@...igon.com>,
Matias Bjørling <mb@...htnvm.io>,
Klaus Birkelund Jensen <klaus.jensen@...xlabs.com>,
"Konopko, Igor J" <igor.j.konopko@...el.com>,
linux-block@...r.kernel.org,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Hans Holmberg <hans.holmberg@...xlabs.com>
Subject: Re: [PATCH RFC] lightnvm: pblk: fix crash in pblk_end_partial_read
due to multipage bvecs
On Thu, Mar 14, 2019 at 5:15 PM Heiner Litz <hlitz@...c.edu> wrote:
>
> On Thu, Mar 14, 2019 at 7:16 AM Javier González <javier@...igon.com> wrote:
> >
> > > On 14 Mar 2019, at 06.49, Igor Konopko <igor.j.konopko@...el.com> wrote:
> > >
> > > While reading this patch, idea came to my mind - maybe it would be simply better to get rid of partial read handling from pblk in current form at all and use bio_split() & bio_chain() combination instead?
> > >
> > > This would definitely reduce a number of this 'kind of complicated' code inside pblk and let block layer help us with that. Even that the performance of such a requests could be a little worse (few smaller IOs instead of single vector IO), I believe that partial read is more a corner case, then a typical use case, so maybe this would be a path to go.
> > >
> > > Let me know what you think about such an approach - I can make a patch with that if you want.
>
> I like this idea as it will clean up a lot of code and get rid of the
> read_bitmap.
> Note that a single request can be turned into up to 32 requests if
> cached and non-cached sectors alternate, each one probably requiring
> an l2p lookup. I still think it's worth doing though.
> When you split, note that you have to release all line_refs which were
> acquired during l2p lookup.
>
> >
> > I agree with Igor.
> >
I agree as well, this path deserves some loving care and cleanup.
Let's just try to avoid read tail latency degradation.
Simplifying the code is a great first step, then we can optimize if needed be.
Thanks for the feedback y'all!
> > As I mentioned offline, we should fix this in a way that survives
> > further changes in struct bio; either making pblk handling visible to
> > the outside or rethinking the whole thing.
> >
> > Igor: If you can send a patch you mention, it would be great. I have
> > been trying the helper approach for some time, but it is too specific,
> > as fixing holes in the bvec breaks the bio advance-only semantics. Your
> > approach seems much better.
> >
> > Thanks,
> > Javier
Powered by blists - more mailing lists