linux-stable/drivers/net/ethernet/intel/igc
Vinicius Costa Gomes 48a933d8b9 igc: Fix missing time sync events
[ Upstream commit 244ae992e3 ]

Fix "double" clearing of interrupts, which can cause external events
or timestamps to be missed.

The IGC_TSIRC Time Sync Interrupt Cause register can be cleared in two
ways, by either reading it or by writing '1' into the specific cause
bit. This is documented in section 8.16.1.

The following flow was used:
 1. read IGC_TSIRC into 'tsicr';
 2. handle the interrupts present in 'tsirc' and mark them in 'ack';
 3. write 'ack' into IGC_TSICR;

As both (1) and (3) will clear the interrupt cause, if the same
interrupt happens again between (1) and (3) it will be ignored,
causing events to be missed.

Remove the extra clear in (3).

Fixes: 2c344ae245 ("igc: Add support for TX timestamping")
Reviewed-by: Kurt Kanzenbach <kurt@linutronix.de>
Tested-by: Kurt Kanzenbach <kurt@linutronix.de> # Intel i225
Signed-off-by: Vinicius Costa Gomes <vinicius.gomes@intel.com>
Tested-by: Naama Meir <naamax.meir@linux.intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-03-26 18:16:53 -04:00
..
Makefile
igc.h Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2024-01-04 18:06:46 -08:00
igc_base.c igc: field get conversion 2023-12-18 11:20:43 -08:00
igc_base.h igc: Add support for PTP .getcyclesx64() 2023-11-13 15:17:09 -08:00
igc_defines.h igc: Add support for PTP .getcyclesx64() 2023-11-13 15:17:09 -08:00
igc_diag.c
igc_diag.h
igc_dump.c
igc_ethtool.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2024-01-04 18:06:46 -08:00
igc_hw.h igc: offload queue max SDU from tc-taprio 2023-03-07 13:45:56 -08:00
igc_i225.c igc: field get conversion 2023-12-18 11:20:43 -08:00
igc_i225.h
igc_mac.c intel/igc:fix repeated words in comments 2022-06-30 11:06:23 -07:00
igc_mac.h
igc_main.c igc: Fix missing time sync events 2024-03-26 18:16:53 -04:00
igc_nvm.c
igc_nvm.h
igc_phy.c igc: Remove temporary workaround 2024-02-14 09:43:09 -08:00
igc_phy.h igc: Change type of the 'igc_check_downshift' method 2022-05-10 14:02:53 -07:00
igc_ptp.c igc: Add support for PTP .getcyclesx64() 2023-11-13 15:17:09 -08:00
igc_regs.h igc: Add support for PTP .getcyclesx64() 2023-11-13 15:17:09 -08:00
igc_tsn.c igc: Fix hicredit calculation 2024-01-03 11:19:47 -08:00
igc_tsn.h igc: Remove reset adapter task for i226 during disable tsn config 2023-01-03 09:36:25 -08:00
igc_xdp.c drivers: net: turn on XDP features 2023-02-02 20:48:23 -08:00
igc_xdp.h