Repository navigation
Commit db81c14
net: lan78xx: Fix race in tx skb size calculation (raspberrypi#2614)
The skb size calculation in lan78xx_tx_bh is in race with the start_xmit,
which could lead to kernel oopses. So protect the whole skb walk with
a spin lock. As a benefit we can unlink the skb directly.
See: raspberrypi#2608
Signed-off-by: Floris Bos <bos@je-eigen-domein.nl>
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Fixes: 55d7de9 ("Microchip's LAN7800 family USB 2/3 to 10/100/1000 Ethernet")1 parent 9499603 commit db81c14
1 file changed
Lines changed: 4 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3292 | 3292 | | |
3293 | 3293 | | |
3294 | 3294 | | |
| 3295 | + | |
3295 | 3296 | | |
3296 | 3297 | | |
3297 | 3298 | | |
| |||
3300 | 3301 | | |
3301 | 3302 | | |
3302 | 3303 | | |
3303 | | - | |
| 3304 | + | |
| 3305 | + | |
3304 | 3306 | | |
3305 | 3307 | | |
3306 | 3308 | | |
| |||
3309 | 3311 | | |
3310 | 3312 | | |
3311 | 3313 | | |
| 3314 | + | |
3312 | 3315 | | |
3313 | 3316 | | |
3314 | 3317 | | |
| |||
0 commit comments