Lucid SRU: UBUNTU: SAUCE: igb: Protect stats update
tim.gardner at canonical.com
Wed Sep 21 14:56:14 UTC 2011
On 09/21/2011 08:48 AM, Stefan Bader wrote:
> On 21.09.2011 16:43, Tim Gardner wrote:
>> On 09/21/2011 08:29 AM, Stefan Bader wrote:
>>> On 21.09.2011 15:43, Tim Gardner wrote:
>>>> This patch is a partial backport of upstream
>>>> 12dcd86b75d571772512676ab301279952efc0b0. Its purpose is twofold; 1) Protect
>>>> simultaneous readers and writers, 2) refresh statistics when read from ethtool.
>>> Wondering whether there is any chance of a running user task holding the
>>> spinlock by that watchdog work...
>> If by 'running user task' you mean the ethtool interface, then yes the lock
>> _should_ be held whilst the statistics update is in progress.
> Yeah, no (if that makes any sense). I was more wondering whether the lock may be
> tried to be taken from the watchdog task (scheduled_work) while a user-space
> process does something like ethtool on the same cpu...
That could only happen if CONFIG_PREEMPT=y, in which case the spin lock
logic should do the right thing.
Tim Gardner tim.gardner at canonical.com
More information about the kernel-team