[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20160314.145759.727527672385295428.davem@davemloft.net>
Date: Mon, 14 Mar 2016 14:57:59 -0400 (EDT)
From: David Miller <davem@...emloft.net>
To: g.nault@...halink.fr
Cc: netdev@...r.kernel.org, paulus@...ba.org, alan@...ux.intel.com,
arnd@...db.de
Subject: Re: [PATCH net] ppp: ensure file->private_data can't be overridden
From: Guillaume Nault <g.nault@...halink.fr>
Date: Mon, 14 Mar 2016 18:59:40 +0100
> Testing ->private_data without lock in ppp_ioctl() before calling
> ppp_unattached_ioctl() is fine, because either ->private_data is
> not NULL and thus is stable, or it is and ppp_unattached_ioctl()
> takes care of not overriding ->private_data, should its value get
> modified before taking the mutex.
This is exactly the ambiguous behavior I want you to avoid.
The decision should be atomic from ppp_ioctl()'s test all the way
until ppp_unattached_ioctl() does it's work.
Powered by blists - more mailing lists