lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZLjHbNNM8eyeaTpH@infradead.org>
Date:   Wed, 19 Jul 2023 22:34:36 -0700
From:   Christoph Hellwig <hch@...radead.org>
To:     Matthew Wilcox <willy@...radead.org>
Cc:     Peng Zhang <zhangpeng362@...wei.com>, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org, sidhartha.kumar@...cle.com,
        akpm@...ux-foundation.org, wangkefeng.wang@...wei.com,
        sunnanyong@...wei.com
Subject: Re: [PATCH v2 3/9] mm/page_io: convert bio_first_page_all() to
 bio_first_folio_all()

On Wed, Jul 19, 2023 at 03:17:34PM +0100, Matthew Wilcox wrote:
> On Wed, Jul 19, 2023 at 05:58:42PM +0800, Peng Zhang wrote:
> > From: ZhangPeng <zhangpeng362@...wei.com>
> > 
> > Convert bio_first_page_all() to bio_first_folio_all() to return a
> > folio, which makes it easier to use.
> 
> This wasn't what I was suggesting.  Indeed, this may introduce bugs.
> I was suggesting adding bio_first_folio_all() so that it can be used
> by code that knows this is what it wants.

To add another opinion:  I'd really like to see bio_first_page_all
go away.  The right way to iterate over the pages is an iterator.
If we really want to micro-opimize not setting up an iteator because
we know we have exactly one page/folio just stash it into bi_private.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ