aboutsummaryrefslogtreecommitdiff
path: root/lib/netdev-notifier-error-inject.c
diff options
context:
space:
mode:
authorEric Dumazet <[email protected]>2016-06-13 07:50:25 -0700
committerDavid S. Miller <[email protected]>2016-06-15 12:16:30 -0700
commit0c5ddb51e8f7be7170600f95a4ea92e5a32afad8 (patch)
treea99bf1c6db2c7fdbd535102c8668070b45d01425 /lib/netdev-notifier-error-inject.c
parent61e0979a497b07f5a82f3050e37ecc7093e2971d (diff)
net/mlx4_en: initialize cmd.context_lock spinlock earlier
Maciej Żenczykowski reported lockdep warning a spinlock was not registered before being held in mlx4_cmd_wake_completions() cmd.context_lock initialization is not at the right place. 1) mlx4_cmd_use_events() can be called multiple times. Calling spin_lock_init() on a live spinlock can lead to hangs. 2) mlx4_cmd_wake_completions() can be called while lock has not been initialized. Lockdep complains, and current logic is not race prone. It seems better to move the initialization earlier in mlx4_load_one() Signed-off-by: Eric Dumazet <[email protected]> Reported-by: Maciej Żenczykowski <[email protected]> Cc: Eugenia Emantayev <[email protected]> Cc: Tariq Toukan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'lib/netdev-notifier-error-inject.c')
0 files changed, 0 insertions, 0 deletions