[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <cc3d357d-b3f5-e363-cd4a-dbf02a412acb@mellanox.com>
Date: Thu, 8 Mar 2018 19:10:47 +0200
From: Paul Blakey <paulb@...lanox.com>
To: Herbert Xu <herbert@...dor.apana.org.au>
Cc: paulb@...lanox.com, Thomas Graf <tgraf@...g.ch>,
David Miller <davem@...emloft.net>, netdev@...r.kernel.org
Subject: Re: [PATCH net] test_rhashtable: Add missing rcu_read_lock()
On 08/03/2018 17:58, Herbert Xu wrote:
> On Thu, Mar 08, 2018 at 01:54:57PM +0200, Paul Blakey wrote:
>> Suppress "suspicious rcu_dereference_protected() usage!" on duplicate
>> insertion test.
>>
>> Fixes: 499ac3b60f65 ('test_rhashtable: add test case for rhl_table with duplicate objects')
>> Signed-off-by: Paul Blakey <paulb@...lanox.com>
>
> This shouldn't be doing a table walk in the first place.
>
> You should convert it to using the table walk interface.
>
> Direct table walks are forbidden because they will break when
> you hit a resize.
>
> Cheers,
>
I know but I wanted to show the inner structure for the failure case,
iirc walk doesn't provide this.
---- ht: ----
bucket[1] -> [[ val 1 (tid=0) ]] -> [[ val 21 (tid=1) ]]
-------------
[ 3599.715501]
---- ht: ----
bucket[1] -> [[ val 1 (tid=2), val 1 (tid=0) ]] -> [[
val 21 (tid=1) ]]
-------------
[ 3599.738600]
---- ht: ----
bucket[1] -> [[ val 21 (tid=1) ]] -> [[ val 1 (tid=0) ]]
-------------
[ 3599.759443]
---- ht: ----
bucket[1] -> [[ val 21 (tid=1) ]] -> [[ val 1 (tid=2),
val 1 (tid=0) ]]
Powered by blists - more mailing lists