Re: [PATCH net v2] ip6mr: fix stale iterator

2018-01-31 Thread David Miller
From: Nikolay Aleksandrov Date: Wed, 31 Jan 2018 16:29:30 +0200 > When we dump the ip6mr mfc entries via proc, we initialize an iterator > with the table to dump but we don't clear the cache pointer which might > be initialized from a prior read on the same descriptor that ended. This > can resul

Re: [PATCH net v2] ip6mr: fix stale iterator

2018-01-31 Thread David Miller
From: Dmitry Vyukov Date: Wed, 31 Jan 2018 15:49:15 +0100 > Don't we need to Cc stable 2.6 in this case or something like this. We > want it to be backported. Networking changes do not CC: stable. Please read the netdev FAQ, thank you.

Re: [PATCH net v2] ip6mr: fix stale iterator

2018-01-31 Thread Dmitry Vyukov
On Wed, Jan 31, 2018 at 3:52 PM, Nikolay Aleksandrov wrote: > On 31/01/18 16:49, Dmitry Vyukov wrote: >> On Wed, Jan 31, 2018 at 3:29 PM, Nikolay Aleksandrov >> wrote: >>> When we dump the ip6mr mfc entries via proc, we initialize an iterator >>> with the table to dump but we don't clear the cach

Re: [PATCH net v2] ip6mr: fix stale iterator

2018-01-31 Thread Nikolay Aleksandrov
On 31/01/18 16:49, Dmitry Vyukov wrote: > On Wed, Jan 31, 2018 at 3:29 PM, Nikolay Aleksandrov > wrote: >> When we dump the ip6mr mfc entries via proc, we initialize an iterator >> with the table to dump but we don't clear the cache pointer which might >> be initialized from a prior read on the sa

Re: [PATCH net v2] ip6mr: fix stale iterator

2018-01-31 Thread Dmitry Vyukov
On Wed, Jan 31, 2018 at 3:29 PM, Nikolay Aleksandrov wrote: > When we dump the ip6mr mfc entries via proc, we initialize an iterator > with the table to dump but we don't clear the cache pointer which might > be initialized from a prior read on the same descriptor that ended. This > can result in

[PATCH net v2] ip6mr: fix stale iterator

2018-01-31 Thread Nikolay Aleksandrov
When we dump the ip6mr mfc entries via proc, we initialize an iterator with the table to dump but we don't clear the cache pointer which might be initialized from a prior read on the same descriptor that ended. This can result in lock imbalance (an unnecessary unlock) leading to other crashes and h