Commit 9dda66a
net: mscc: ocelot: fix race condition with TX timestamping
The TX-timestampable skb is added late to the ocelot_port->tx_skbs. It
is in a race with the TX timestamp IRQ, which checks that queue trying
to match the timestamp with the skb by the ts_id. The skb should be
added to the queue before the IRQ can fire.
Fixes: 4e3b046 ("net: mscc: PTP Hardware Clock (PHC) support")
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: Horatiu Vultur <horatiu.vultur@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>1 parent 5f6857e commit 9dda66a
1 file changed
+8
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
330 | 330 | | |
331 | 331 | | |
332 | 332 | | |
| 333 | + | |
333 | 334 | | |
334 | 335 | | |
335 | 336 | | |
| |||
344 | 345 | | |
345 | 346 | | |
346 | 347 | | |
| 348 | + | |
| 349 | + | |
347 | 350 | | |
348 | 351 | | |
349 | | - | |
| 352 | + | |
350 | 353 | | |
| 354 | + | |
| 355 | + | |
351 | 356 | | |
352 | 357 | | |
353 | 358 | | |
| |||
380 | 385 | | |
381 | 386 | | |
382 | 387 | | |
383 | | - | |
384 | | - | |
385 | | - | |
386 | | - | |
| 388 | + | |
| 389 | + | |
387 | 390 | | |
388 | | - | |
389 | 391 | | |
390 | 392 | | |
391 | 393 | | |
| |||
0 commit comments