Stanislaw Gruszka
731073b9c9
sky2: initialize napi before registering device
...
There is race condition when call netif_napi_add() after
register_netdevice(), as ->open() can be called without napi initialized
and trigger BUG_ON() on napi_enable(), like on below messages:
[ 9.699863] sky2: driver version 1.30
[ 9.699960] sky2 0000:02:00.0: Yukon-2 EC Ultra chip revision 2
[ 9.700020] sky2 0000:02:00.0: irq 45 for MSI/MSI-X
[ 9.700498] ------------[ cut here ]------------
[ 9.703391] kernel BUG at include/linux/netdevice.h:501!
[ 9.703391] invalid opcode: 0000 [#1 ] PREEMPT SMP
<snip>
[ 9.830018] Call Trace:
[ 9.830018] [<fa996169>] sky2_open+0x309/0x360 [sky2]
[ 9.830018] [<c1007210>] ? via_no_dac+0x40/0x40
[ 9.830018] [<c1007210>] ? via_no_dac+0x40/0x40
[ 9.830018] [<c135ed4b>] __dev_open+0x9b/0x120
[ 9.830018] [<c1431cbe>] ? _raw_spin_unlock_bh+0x1e/0x20
[ 9.830018] [<c135efd9>] __dev_change_flags+0x89/0x150
[ 9.830018] [<c135f148>] dev_change_flags+0x18/0x50
[ 9.830018] [<c13bb8e0>] devinet_ioctl+0x5d0/0x6e0
[ 9.830018] [<c13bcced>] inet_ioctl+0x6d/0xa0
To fix the problem patch changes the order of initialization.
Bug report:
https://bugzilla.kernel.org/show_bug.cgi?id=67151
Reported-and-tested-by: ebrahim.azarisooreh@gmail.com
Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Signed-off-by: David S. Miller <davem@davemloft.net>
2014-01-27 16:39:53 -08:00
..
2014-01-24 15:51:02 -08:00
2014-01-24 15:51:02 -08:00
2013-12-26 13:31:34 -05:00
2014-01-25 13:18:00 -08:00
2014-01-10 10:59:40 -05:00
2014-01-23 16:36:53 -08:00
2014-01-08 13:44:29 -05:00
2014-01-25 15:33:41 -08:00
2014-01-23 18:56:08 -08:00
2014-01-23 18:45:38 -08:00
2014-01-24 17:13:49 -08:00
2013-12-30 11:55:20 +01:00
2014-01-23 18:49:36 -08:00
2014-01-23 18:36:55 -08:00
2014-01-23 18:45:38 -08:00
2014-01-20 12:10:27 -08:00
2014-01-17 14:57:29 -07:00
2014-01-09 09:53:30 +09:00
2014-01-24 15:51:02 -08:00
2014-01-23 18:49:36 -08:00
2014-01-24 15:51:02 -08:00
2014-01-24 15:51:02 -08:00
2014-01-24 15:51:02 -08:00
2014-01-24 17:13:49 -08:00
2014-01-24 15:51:02 -08:00
2014-01-24 15:51:02 -08:00
2014-01-24 15:51:02 -08:00
2014-01-22 21:21:55 -08:00
2014-01-25 11:17:34 -08:00
2014-01-24 17:17:30 -08:00
2014-01-24 15:51:02 -08:00
2014-01-25 10:49:30 -08:00
2014-01-25 11:17:34 -08:00
2014-01-22 21:21:55 -08:00
2014-01-20 09:24:31 -08:00
2014-01-23 16:36:53 -08:00
2014-01-24 17:41:50 -08:00
2014-01-25 11:17:34 -08:00
2014-01-23 16:37:04 -08:00
2014-01-14 12:14:25 -07:00
2014-01-25 13:19:10 -08:00
2014-01-22 21:21:55 -08:00
2014-01-26 11:00:41 -08:00
2014-01-22 21:21:55 -08:00
2014-01-27 16:39:53 -08:00
2014-01-09 01:27:20 +01:00
2014-01-25 11:17:34 -08:00
2014-01-20 16:05:23 -08:00
2014-01-24 15:51:02 -08:00
2014-01-22 16:39:28 -08:00
2014-01-25 11:17:34 -08:00
2014-01-23 18:45:38 -08:00
2014-01-24 15:51:02 -08:00
2014-01-12 23:48:18 +01:00
2014-01-25 11:17:34 -08:00
2013-12-22 01:27:51 +01:00
2014-01-15 14:51:22 -08:00
2014-01-21 08:28:00 +00:00
2014-01-25 13:19:10 -08:00
2014-01-23 19:11:50 -08:00
2014-01-25 11:17:34 -08:00
2014-01-24 17:18:32 -08:00
2014-01-25 13:20:36 -08:00
2014-01-03 15:37:01 -05:00
2014-01-25 11:17:34 -08:00
2014-01-24 17:13:49 -08:00
2014-01-23 18:49:36 -08:00
2013-12-20 08:49:17 -08:00
2014-01-24 15:51:02 -08:00
2013-12-20 12:19:44 -08:00
2014-01-24 17:42:31 -08:00
2014-01-24 17:16:31 -08:00
2014-01-22 22:24:35 -08:00
2014-01-23 16:36:55 -08:00
2014-01-23 16:37:04 -08:00
2014-01-23 18:49:36 -08:00
2014-01-24 15:51:02 -08:00