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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 4 Jun 2013 14:44:35 -0400
From:	Jörn Engel <joern@...fs.org>
To:	Arne Jansen <sensille@....net>
Cc:	Chris Mason <clmason@...ionio.com>,
	Christoph Hellwig <hch@...radead.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"linux-btrfs@...r.kernel.org" <linux-btrfs@...r.kernel.org>
Subject: Re: [PATCH 0/2] introduce list_for_each_entry_del

On Tue, 4 June 2013 22:09:13 +0200, Arne Jansen wrote:
> On 06/04/13 16:53, Chris Mason wrote:
> > Quoting Christoph Hellwig (2013-06-04 10:48:56)
> >> On Mon, Jun 03, 2013 at 03:55:55PM -0400, J??rn Engel wrote:
> >>> Actually, when I compare the two invocations, I prefer the
> >>> list_for_each_entry_del() variant over list_pop_entry().
> >>>
> >>>         while ((ref = list_pop_entry(&prefs, struct __prelim_ref, list))) {
> >>>         list_for_each_entry_del(ref, &prefs, list) {
> >>>
> >>> Christoph?
> >>
> >> I really don't like something that looks like an iterator (*for_each*)
> >> to modify a list.  Maybe it's just me, so I'd love to hear others chime
> >> in.
> > 
> > Have to agree with Christoph.  I just couldn't put my finger on why I
> > didn't like it until I saw the list_pop_entry suggestion.
> 
> list_pop_each_entry?

Or while_list_drain?

I agree the *for_each* cover didn't exactly match the content.  But if
we find a better name and you are not opposed to the concept, ...

Jörn

--
tglx1 thinks that joern should get a (TM) for "Thinking Is Hard"
-- Thomas Gleixner
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ