[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YV3AvszXKVBA5BNz@kroah.com>
Date: Wed, 6 Oct 2021 17:29:02 +0200
From: Greg KH <gregkh@...uxfoundation.org>
To: Wei Yang <richard.weiyang@...il.com>
Cc: kuba@...nel.org, neilb@...e.com, mojha@...eaurora.org,
jkosina@...e.cz, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] hashtable: remove a redundant check in
hash_for_each_xxx()
On Wed, Oct 06, 2021 at 03:21:00PM +0000, Wei Yang wrote:
> The three hash_for_each_xxx() helper iterate the hash table with help
> of hlist_for_each_entry_xxx(), which breaks the loop only when obj is
> NULL.
>
> This means the check during each iteration is redundant. This patch
> removes it.
Are you sure that the compiler didn't already remove it? Is the code
output the same or different with this change?
How did you test this?
thanks,
greg k-h
Powered by blists - more mailing lists