[Intel-wired-lan] [PATCH iwl-next 2/4] ice: refactor ice_sq_send_cmd and ice_shutdown_sq

2025-05-20 Thread Karol Kolacinski
Refactor ice_sq_send_cmd() and ice_shutdown_sq() to be able to use a simpler locking, e.g. for new methods, which depend on the control queue. Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_controlq.c | 155 -- 1 file changed

[Intel-wired-lan] [PATCH iwl-next 3/4] ice: use spin_lock for sideband queue send queue

2025-05-20 Thread Karol Kolacinski
eue type. Use ice_sq_spin_lock/unlock for sideband queue and ice_sq_mutex_lock/unlock for other queues. Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 8 +- drivers/net/ethernet/intel/ice/ice_common.h | 3 +- drivers/net/ether

[Intel-wired-lan] [PATCH iwl-next 0/4] ice: Read Tx timestamps in the IRQ top half

2025-05-20 Thread Karol Kolacinski
llows reading the sideband queue in the top half of the interrupt and allows to avoid bottom half scheduling delays, which speeds up Tx timestamping process significantly. Introduce new structure ice_sq_ops, which allows to assign lock/unlock operations based on the queue type on queue init.

[Intel-wired-lan] [PATCH iwl-next 4/4] ice: read Tx timestamps in the IRQ top half

2025-05-20 Thread Karol Kolacinski
With sideband queue using delays and spin locks, it is possible to read timestamps from the PHY in the top half of the interrupt. This removes bottom half scheduling delays and improves timestamping read times significantly, from >2 ms to <50 us. Reviewed-by: Milena Olech Signed-off-by:

[Intel-wired-lan] [PATCH iwl-next 1/4] ice: skip completion for sideband queue writes

2025-05-20 Thread Karol Kolacinski
SBQ by reading address 0 from the PHY 0 before issuing SYNC command to ensure that writes to all PHYs were completed and skip SBQ message completion if it's posted. Reviewed-by: Przemek Kitszel Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet

[Intel-wired-lan] [PATCH iwl-next 2/2] ice: update cached PHC time for all ports

2025-05-12 Thread Karol Kolacinski
kworker and use do_aux_work for PTP periodic work and system_unbound_wq for ov_work. Reviewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_ptp.c | 223 +++ drivers/net/ethernet/intel/ice/ice_ptp.h | 6 +- 2 files changed, 110

[Intel-wired-lan] [PATCH iwl-next 1/2] ice: move two ice_ptp_* functions

2025-05-12 Thread Karol Kolacinski
Move ice_ptp_maybe_trigger_tx_interrupt() and ice_ptp_periodic_work(). This will allow to assign ice_ptp_periodic_work() to PTP API's do_aux_work function pointer. Reviewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_ptp.c

[Intel-wired-lan] [PATCH v2 iwl-next 07/10] ice: add multiple TSPLL helpers

2025-04-10 Thread Karol Kolacinski
Add helpers for checking TSPLL params, disabling sticky bits, configuring TSPLL and getting default clock frequency to simplify the code flows. Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_tspll.c | 156 ++--- 1 file changed

[Intel-wired-lan] [PATCH v2 iwl-next 06/10] ice: use bitfields instead of unions for CGU regs

2025-04-10 Thread Karol Kolacinski
: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.h | 212 +++--- drivers/net/ethernet/intel/ice/ice_tspll.c | 236 +++- 2 files changed, 157 insertions(+), 291 deletions(-) diff --git a/drivers/net/ethernet/intel/ice/ice_common.h b/drivers/net/ethernet

[Intel-wired-lan] [PATCH v2 iwl-next 04/10] ice: add TSPLL log config helper

2025-04-09 Thread Karol Kolacinski
Add a helper function to print new/current TSPLL config. This helps avoid unnecessary casts from u8 to enums. Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_tspll.c | 54 -- 1 file changed, 30

[Intel-wired-lan] [PATCH v2 iwl-next 10/10] ice: move TSPLL init calls to ice_ptp.c

2025-04-09 Thread Karol Kolacinski
Initialize TSPLL after initializing PHC in ice_ptp.c instead of calling for each product in PHC init in ice_ptp_hw.c. Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_ptp.c| 11 +++ drivers/net/ethernet

[Intel-wired-lan] [PATCH v2 iwl-next 08/10] ice: wait before enabling TSPLL

2025-04-09 Thread Karol Kolacinski
To ensure proper operation, wait for 10 to 20 microseconds before enabling TSPLL. Adjust wait time after enabling TSPLL from 1-5 ms to 1-2 ms. Those values are empirical and tested on multiple HW configurations. Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net

[Intel-wired-lan] [PATCH v2 iwl-next 09/10] ice: fall back to TCXO on TSPLL lock fail

2025-04-09 Thread Karol Kolacinski
TSPLL can fail when trying to lock to TIME_REF as a clock source, e.g. when the external clock source is not stable or connected to the board. To continue operation after failure, try to lock again to internal TCXO and inform user about this. Reviewed-by: Milena Olech Signed-off-by: Karol

[Intel-wired-lan] [PATCH v2 iwl-next 05/10] ice: add ICE_READ/WRITE_CGU_REG_OR_DIE helpers

2025-04-09 Thread Karol Kolacinski
Add ICE_READ_CGU_REG_OR_DIE() and ICE_WRITE_CGU_REG_OR_DIE() helpers to avoid multiple error checks after calling read/write functions. Suggested-by: Przemek Kitszel Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice

[Intel-wired-lan] [PATCH v2 iwl-next 03/10] ice: use designated initializers for TSPLL consts

2025-04-09 Thread Karol Kolacinski
TIME_REF clock source. Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.h | 19 +- drivers/net/ethernet/intel/ice/ice_tspll.c | 203 drivers/net/ethernet/intel/ice/ice_tspll.h | 29 +-- 3 files

[Intel-wired-lan] [PATCH v2 iwl-next 01/10] ice: move TSPLL functions to a separate file

2025-04-09 Thread Karol Kolacinski
Collect TSPLL related functions and definitions and move them to a separate file to have all TSPLL functionality in one place. Move CGU related functions and definitions to ice_common.* Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net

[Intel-wired-lan] [PATCH v2 iwl-next 02/10] ice: rename TSPLL and CGU functions and definitions

2025-04-09 Thread Karol Kolacinski
Rename TSPLL and CGU functions, definitions etc. to match the file name and have consistent naming scheme. Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 32 +- drivers/net/ethernet/intel/ice

[Intel-wired-lan] [PATCH v2 iwl-next 00/10] ice: Separate TSPLL from PTP and clean up

2025-04-09 Thread Karol Kolacinski
Separate TSPLL related functions and definitions from all PTP-related files and clean up the code by implementing multiple helpers. Adjust TSPLL wait times and fall back to TCXO on lock failure to ensure proper init flow of TSPLL. Karol Kolacinski (10): ice: move TSPLL functions to a separate

[Intel-wired-lan] [PATCH iwl-next 05/10] ice: add ICE_READ/WRITE_CGU_REG_OR_DIE helpers

2025-03-15 Thread Karol Kolacinski
Add ICE_READ_CGU_REG_OR_DIE() and ICE_WRITE_CGU_REG_OR_DIE() helpers to avoid multiple error checks after calling read/write functions. Suggested-by: Przemek Kitszel Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice

[Intel-wired-lan] [PATCH iwl-next 00/10] ice: Separate TSPLL from PTP and clean up

2025-03-11 Thread Karol Kolacinski
Separate TSPLL related functions and definitions from all PTP-related files and clean up the code by implementing multiple helpers. Adjust TSPLL wait times and fall back to TCXO on lock failure to ensure proper init flow of TSPLL. Karol Kolacinski (10): ice: move TSPLL functions to a separate

[Intel-wired-lan] [PATCH iwl-next 06/10] ice: use bitfields instead of unions for CGU regs

2025-03-11 Thread Karol Kolacinski
: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.h | 197 +++- drivers/net/ethernet/intel/ice/ice_tspll.c | 236 +++- 2 files changed, 157 insertions(+), 276 deletions(-) diff --git a/drivers/net/ethernet/intel/ice/ice_common.h b/drivers/net/ethernet

[Intel-wired-lan] [PATCH iwl-next 10/10] ice: move TSPLL init calls to ice_ptp.c

2025-03-10 Thread Karol Kolacinski
Initialize TSPLL after initializing PHC in ice_ptp.c instead of calling for each product in PHC init in ice_ptp_hw.c. Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_ptp.c| 11 ++ drivers/net/ethernet

[Intel-wired-lan] [PATCH iwl-next 08/10] ice: wait before enabling TSPLL

2025-03-10 Thread Karol Kolacinski
To ensure proper operation, wait for 10 to 20 microseconds before enabling TSPLL. Adjust wait time after enabling TSPLL from 1-5 ms to 1-2 ms. Those values are empirical and tested on multiple HW configurations. Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net

[Intel-wired-lan] [PATCH iwl-next 09/10] ice: fall back to TCXO on TSPLL lock fail

2025-03-10 Thread Karol Kolacinski
TSPLL can fail when trying to lock to TIME_REF as a clock source, e.g. when the external clock source is not stable or connected to the board. To continue operation after failure, try to lock again to internal TCXO and inform user about this. Reviewed-by: Milena Olech Signed-off-by: Karol

[Intel-wired-lan] [PATCH iwl-next 07/10] ice: add multiple TSPLL helpers

2025-03-10 Thread Karol Kolacinski
Add helpers for checking TSPLL params, disabling sticky bits, configuring TSPLL and getting default clock frequency to simplify the code flows. Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_tspll.c | 152 ++--- 1 file changed

[Intel-wired-lan] [PATCH iwl-next 04/10] ice: add TSPLL log config helper

2025-03-10 Thread Karol Kolacinski
Add a helper function to print new/current TSPLL config. This helps avoid unnecessary casts from u8 to enums. Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_tspll.c | 54 -- 1 file changed, 30

[Intel-wired-lan] [PATCH iwl-next 03/10] ice: use designated initializers for TSPLL consts

2025-03-10 Thread Karol Kolacinski
TIME_REF clock source. Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_tspll.c | 199 - drivers/net/ethernet/intel/ice/ice_tspll.h | 29 +-- 2 files changed, 45 insertions(+), 183 deletions(-) diff --git

[Intel-wired-lan] [PATCH iwl-next 01/10] ice: move TSPLL functions to a separate file

2025-03-10 Thread Karol Kolacinski
Collect TSPLL related functions and definitions and move them to a separate file to have all TSPLL functionality in one place. Move CGU related functions and definitions to ice_common.* Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net

[Intel-wired-lan] [PATCH iwl-next 02/10] ice: rename TSPLL and CGU functions and definitions

2025-03-10 Thread Karol Kolacinski
Rename TSPLL and CGU functions, definitions etc. to match the file name and have constistent naming scheme. Reviewed-by: Michal Kubiak Reviewed-by: Milena Olech Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 28 +- drivers/net/ethernet/intel/ice

[Intel-wired-lan] [PATCH v3 iwl-next] ice: Add in/out PTP pin delays

2024-12-04 Thread Karol Kolacinski
delays based on HW spec. Implement external timestamp (input) delay compensation. Remove existing definitions and wrappers for periodic output propagation delays. Reviewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V2 -> V3: rebased, renamed prop_delay to prop_delay_ns, rewor

[Intel-wired-lan] [PATCH v2 iwl-net 4/4] ice: Add correct PHY lane assignment

2024-10-10 Thread Karol Kolacinski
t PTP init for 2x50G E825C devices") Reviewed-by: Przemek Kitszel Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 40 + drivers/net/ethernet/intel/ice/ice_common.h | 1 + drivers/net/ethernet/intel/ice/

[Intel-wired-lan] [PATCH v2 iwl-net 2/4] ice: Fix quad registers read on E825

2024-10-10 Thread Karol Kolacinski
based on port. Rename rmn_0 to phy_0 and remove rmn_1 and rmn_2 as E82X HW does not support it. Rename eth56g_phy_1 to phy_0_peer. Fixes: 7cab44f1c35f ("ice: Introduce ETH56G PHY model for E825C products") Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- V1 -> V

[Intel-wired-lan] [PATCH v2 iwl-net 3/4] ice: Fix ETH56G FC-FEC Rx offset value

2024-10-10 Thread Karol Kolacinski
) Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_ptp_consts.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/intel/ice/ice_ptp_consts.h b/drivers/net/ethernet/intel/ice/ice_ptp_consts.h index e6

[Intel-wired-lan] [PATCH v2 iwl-net 1/4] ice: Fix E825 initialization

2024-10-10 Thread Karol Kolacinski
ned-off-by: Karol Kolacinski --- V1 -> V2: Removed net-next hunks drivers/net/ethernet/intel/ice/ice_ptp_hw.c | 22 - drivers/net/ethernet/intel/ice/ice_ptp_hw.h | 3 ++- 2 files changed, 10 insertions(+), 15 deletions(-) diff --git a/drivers/net/ethernet/intel/ice/ice_ptp_hw

[Intel-wired-lan] [PATCH v2 iwl-net 0/4] Fix E825 initialization

2024-10-10 Thread Karol Kolacinski
addition, E825 uses PF ID for indexing per PF registers and as a primary PHY lane number, which is incorrect. Karol Kolacinski (4): ice: Fix E825 initialization ice: Fix quad registers read on E825 ice: Fix ETH56G FC-FEC Rx offset value ice: Add correct PHY lane assignment drivers/net

[Intel-wired-lan] [PATCH v2 iwl-next 4/4] ice: Add correct PHY lane assignment

2024-10-09 Thread Karol Kolacinski
t PTP init for 2x50G E825C devices") Reviewed-by: Przemek Kitszel Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 40 + drivers/net/ethernet/intel/ice/ice_common.h | 1 + drivers/net/ethernet/intel/ice/

[Intel-wired-lan] [PATCH v2 iwl-next 3/4] ice: Fix ETH56G FC-FEC Rx offset value

2024-10-09 Thread Karol Kolacinski
) Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_ptp_consts.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/intel/ice/ice_ptp_consts.h b/drivers/net/ethernet/intel/ice/ice_ptp_consts.h index e6

[Intel-wired-lan] [PATCH v2 iwl-next 2/4] ice: Fix quad registers read on E825

2024-10-09 Thread Karol Kolacinski
based on port. Rename rmn_0 to phy_0 and remove rmn_1 and rmn_2 as E82X HW does not support it. Rename eth56g_phy_1 to phy_0_peer. Fixes: 7cab44f1c35f ("ice: Introduce ETH56G PHY model for E825C products") Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- V1 -> V

[Intel-wired-lan] [PATCH v2 iwl-next 1/4] ice: Fix E825 initialization

2024-10-09 Thread Karol Kolacinski
ned-off-by: Karol Kolacinski --- V1 -> V2: Removed net-next hunks drivers/net/ethernet/intel/ice/ice_ptp_hw.c | 22 - drivers/net/ethernet/intel/ice/ice_ptp_hw.h | 3 ++- 2 files changed, 10 insertions(+), 15 deletions(-) diff --git a/drivers/net/ethernet/intel/ice/ice_ptp_hw

[Intel-wired-lan] [PATCH v2 iwl-next 0/4] Fix E825 initialization

2024-10-09 Thread Karol Kolacinski
addition, E825 uses PF ID for indexing per PF registers and as a primary PHY lane number, which is incorrect. Karol Kolacinski (4): ice: Fix E825 initialization ice: Fix quad registers read on E825 ice: Fix ETH56G FC-FEC Rx offset value ice: Add correct PHY lane assignment drivers/net

[Intel-wired-lan] [PATCH v2 iwl-next] ice: Add in/out PTP pin delays

2024-10-08 Thread Karol Kolacinski
-by: Karol Kolacinski --- V1 -> V2: removed duplicate gpio_pin variable and restored missing ICE_E810_E830_SYNC_DELAY drivers/net/ethernet/intel/ice/ice_ptp.c | 82 +++ drivers/net/ethernet/intel/ice/ice_ptp.h | 2 + .../net/ethernet/intel/ice/ice_ptp_const

[Intel-wired-lan] [PATCH iwl-next] ice: Add in/out PTP pin delays

2024-10-03 Thread Karol Kolacinski
-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_ptp.c | 81 +++ drivers/net/ethernet/intel/ice/ice_ptp.h | 2 + .../net/ethernet/intel/ice/ice_ptp_consts.h | 12 --- drivers/net/ethernet/intel/ice/ice_ptp_hw.h | 24 -- 4 files changed, 49 insertions

[Intel-wired-lan] [PATCH v12 iwl-next 7/7] ice: Implement PTP support for E830 devices

2024-09-30 Thread Karol Kolacinski
-by: Milena Olech Co-developed-by: Paul Greenwalt Signed-off-by: Paul Greenwalt Signed-off-by: Michal Michalik Co-developed-by: Karol Kolacinski Signed-off-by: Karol Kolacinski --- V11 -> V12: Fixed missing E830 case in ice_get_base_incval() V10 -> V11: Fixed adjustments not working on E

[Intel-wired-lan] [PATCH v12 iwl-next 3/7] ice: Use FIELD_PREP for timestamp values

2024-09-30 Thread Karol Kolacinski
Instead of using shifts and casts, use FIELD_PREP after reading 40b timestamp values. Reviewed-by: Simon Horman Signed-off-by: Karol Kolacinski --- V5 -> V6: Replaced removed macros with the new ones drivers/net/ethernet/intel/ice/ice_ptp_hw.c | 9 ++--- drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v12 iwl-next 6/7] ice: Refactor ice_ptp_init_tx_*

2024-09-30 Thread Karol Kolacinski
Unify ice_ptp_init_tx_* functions for most of the MAC types except E82X. This simplifies the code for the future use with new MAC types. Reviewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V7 -> V8: Renamed the patch and reworded the commit message drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v12 iwl-next 4/7] ice: Process TSYN IRQ in a separate function

2024-09-30 Thread Karol Kolacinski
iewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 timestamp handling to "ice: Implement PTP support for E830 devices" drivers/net/ethernet/intel/ice/ice_main.c | 18 + drivers/net/ethernet/intel/ice/ice_ptp.c | 49 ++

[Intel-wired-lan] [PATCH v12 iwl-next 5/7] ice: Add unified ice_capture_crosststamp

2024-09-30 Thread Karol Kolacinski
Reviewed-by: Przemek Kitszel Signed-off-by: Jacob Keller Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 cross timestamp handling to "ice: Implement PTP support for E830 devices" and explained the rest of previous changes in the commit description V4 -&g

[Intel-wired-lan] [PATCH v12 iwl-next 2/7] ice: Remove unncecessary ice_is_e8xx() functions

2024-09-30 Thread Karol Kolacinski
nally, because all further function calls check the MAC type anyway and this allows simpler code in the future with addition of the new MAC types. Reorder ICE_MAC_* cases in switches in ice_ptp* as in enum ice_mac_type. Signed-off-by: Karol Kolacinski --- V9 -> V10: Fixed E825C MAC cond

[Intel-wired-lan] [PATCH v12 iwl-next 1/7] ice: Don't check device type when checking GNSS presence

2024-09-30 Thread Karol Kolacinski
ce_id first, then set other variables. Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 90 drivers/net/ethernet/intel/ice/ice_common.h | 2 + drivers/net/ethernet/intel/ice/ice_gnss.c | 29 +++ drivers/net/ethernet/intel/ice/ice_gnss.h

[Intel-wired-lan] [PATCH v12 iwl-next 0/7] ice: Implement PTP support for E830 devices

2024-09-30 Thread Karol Kolacinski
. Jacob Keller (1): ice: Add unified ice_capture_crosststamp Karol Kolacinski (5): ice: Don't check device type when checking GNSS presence ice: Remove unncecessary ice_is_e8xx() functions ice: Use FIELD_PREP for timestamp values ice: Process TSYN IRQ in a separate function ice: Ref

[Intel-wired-lan] [PATCH iwl-net 5/5] ice: Add correct PHY lane assignment

2024-09-30 Thread Karol Kolacinski
t PTP init for 2x50G E825C devices") Reviewed-by: Przemek Kitszel Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 40 + drivers/net/ethernet/intel/ice/ice_common.h | 1 + drivers/net/ethernet/intel/ice/

[Intel-wired-lan] [PATCH iwl-net 4/5] ice: Remove unnecessary offset calculation for PF scoped registers

2024-09-30 Thread Karol Kolacinski
uot;) Fixes: 03cb4473be92 ("ice: add low level PTP clock access functions") Fixes: 13a64f0b9894 ("ice: support crosstimestamping on E822 devices if supported") Reviewed-by: Przemek Kitszel Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Jacob Keller Signed-off-by: Karol Ko

[Intel-wired-lan] [PATCH iwl-net 3/5] ice: Fix ETH56G FC-FEC Rx offset value

2024-09-30 Thread Karol Kolacinski
) Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_ptp_consts.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/intel/ice/ice_ptp_consts.h b/drivers/net/ethernet/intel/ice/ice_ptp_consts.h index e6

[Intel-wired-lan] [PATCH iwl-net 1/5] ice: Fix E825 initialization

2024-09-30 Thread Karol Kolacinski
PF_SB_REM_DEV_CTL modification. Configure synchronization delay for E825 product to ensure proper PHY timers initialization on SYNC command. Fixes: 7cab44f1c35f ("ice: Introduce ETH56G PHY model for E825C products") Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- d

[Intel-wired-lan] [PATCH iwl-net 2/5] ice: Fix quad registers read on E825

2024-09-30 Thread Karol Kolacinski
based on port. Rename rmn_0 to phy_0 and remove rmn_1 and rmn_2 as E82X HW does not support it. Rename eth56g_phy_1 to phy_0_peer. Fixes: 7cab44f1c35f ("ice: Introduce ETH56G PHY model for E825C products") Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- drivers/ne

[Intel-wired-lan] [PATCH iwl-net 0/5] Fix E825 initialization

2024-09-30 Thread Karol Kolacinski
addition, E825 uses PF ID for indexing per PF registers and as a primary PHY lane number, which is incorrect. Jacob Keller (1): ice: Remove unnecessary offset calculation for PF scoped registers Karol Kolacinski (4): ice: Fix E825 initialization ice: Fix quad registers read on E825 ice: Fix

[Intel-wired-lan] [PATCH v11 iwl-next 7/7] ice: Implement PTP support for E830 devices

2024-09-18 Thread Karol Kolacinski
-by: Milena Olech Co-developed-by: Paul Greenwalt Signed-off-by: Paul Greenwalt Signed-off-by: Michal Michalik Co-developed-by: Karol Kolacinski Signed-off-by: Karol Kolacinski --- V10 -> V11: Fixed adjustments not working on E830 V9 -> V10: Removed ICE_FLAG_PTP_SUPPORTED check for E830,

[Intel-wired-lan] [PATCH v11 iwl-next 6/7] ice: Refactor ice_ptp_init_tx_*

2024-09-18 Thread Karol Kolacinski
Unify ice_ptp_init_tx_* functions for most of the MAC types except E82X. This simplifies the code for the future use with new MAC types. Reviewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V7 -> V8: Renamed the patch and reworded the commit message drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v11 iwl-next 5/7] ice: Add unified ice_capture_crosststamp

2024-09-18 Thread Karol Kolacinski
Reviewed-by: Przemek Kitszel Signed-off-by: Jacob Keller Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 cross timestamp handling to "ice: Implement PTP support for E830 devices" and explained the rest of previous changes in the commit description V4 -&g

[Intel-wired-lan] [PATCH v11 iwl-next 4/7] ice: Process TSYN IRQ in a separate function

2024-09-18 Thread Karol Kolacinski
iewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 timestamp handling to "ice: Implement PTP support for E830 devices" drivers/net/ethernet/intel/ice/ice_main.c | 18 + drivers/net/ethernet/intel/ice/ice_ptp.c | 49 ++

[Intel-wired-lan] [PATCH v11 iwl-next 3/7] ice: Use FIELD_PREP for timestamp values

2024-09-18 Thread Karol Kolacinski
Instead of using shifts and casts, use FIELD_PREP after reading 40b timestamp values. Reviewed-by: Simon Horman Signed-off-by: Karol Kolacinski --- V5 -> V6: Replaced removed macros with the new ones drivers/net/ethernet/intel/ice/ice_ptp_hw.c | 9 ++--- drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v11 iwl-next 0/7] ice: Implement PTP support for E830 devices

2024-09-18 Thread Karol Kolacinski
. Jacob Keller (1): ice: Add unified ice_capture_crosststamp Karol Kolacinski (5): ice: Don't check device type when checking GNSS presence ice: Remove unncecessary ice_is_e8xx() functions ice: Use FIELD_PREP for timestamp values ice: Process TSYN IRQ in a separate function ice: Ref

[Intel-wired-lan] [PATCH v11 iwl-next 2/7] ice: Remove unncecessary ice_is_e8xx() functions

2024-09-18 Thread Karol Kolacinski
nally, because all further function calls check the MAC type anyway and this allows simpler code in the future with addition of the new MAC types. Reorder ICE_MAC_* cases in switches in ice_ptp* as in enum ice_mac_type. Signed-off-by: Karol Kolacinski --- V9 -> V10: Fixed E825C MAC cond

[Intel-wired-lan] [PATCH v11 iwl-next 1/7] ice: Don't check device type when checking GNSS presence

2024-09-18 Thread Karol Kolacinski
ce_id first, then set other variables. Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 90 drivers/net/ethernet/intel/ice/ice_common.h | 2 + drivers/net/ethernet/intel/ice/ice_gnss.c | 29 +++ drivers/net/ethernet/intel/ice/ice_gnss.h

[Intel-wired-lan] [PATCH v10 iwl-next 7/7] ice: Implement PTP support for E830 devices

2024-09-12 Thread Karol Kolacinski
-by: Milena Olech Co-developed-by: Paul Greenwalt Signed-off-by: Paul Greenwalt Signed-off-by: Michal Michalik Co-developed-by: Karol Kolacinski Signed-off-by: Karol Kolacinski --- V9 -> V10: Removed ICE_FLAG_PTP_SUPPORTED check for E830, which was disabling PTP only for E830 V7 -&

[Intel-wired-lan] [PATCH v10 iwl-next 6/7] ice: Refactor ice_ptp_init_tx_*

2024-09-12 Thread Karol Kolacinski
Unify ice_ptp_init_tx_* functions for most of the MAC types except E82X. This simplifies the code for the future use with new MAC types. Reviewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V7 -> V8: Renamed the patch and reworded the commit message drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v10 iwl-next 5/7] ice: Add unified ice_capture_crosststamp

2024-09-12 Thread Karol Kolacinski
Reviewed-by: Przemek Kitszel Signed-off-by: Jacob Keller Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 cross timestamp handling to "ice: Implement PTP support for E830 devices" and explained the rest of previous changes in the commit description V4 -&g

[Intel-wired-lan] [PATCH v10 iwl-next 4/7] ice: Process TSYN IRQ in a separate function

2024-09-12 Thread Karol Kolacinski
iewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 timestamp handling to "ice: Implement PTP support for E830 devices" drivers/net/ethernet/intel/ice/ice_main.c | 18 + drivers/net/ethernet/intel/ice/ice_ptp.c | 49 ++

[Intel-wired-lan] [PATCH v10 iwl-next 3/7] ice: Use FIELD_PREP for timestamp values

2024-09-12 Thread Karol Kolacinski
Instead of using shifts and casts, use FIELD_PREP after reading 40b timestamp values. Reviewed-by: Simon Horman Signed-off-by: Karol Kolacinski --- V5 -> V6: Replaced removed macros with the new ones drivers/net/ethernet/intel/ice/ice_ptp_hw.c | 9 ++--- drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v10 iwl-next 2/7] ice: Remove unncecessary ice_is_e8xx() functions

2024-09-12 Thread Karol Kolacinski
nally, because all further function calls check the MAC type anyway and this allows simpler code in the future with addition of the new MAC types. Reorder ICE_MAC_* cases in switches in ice_ptp* as in enum ice_mac_type. Signed-off-by: Karol Kolacinski --- V9 -> V10: Fixed E825C MAC cond

[Intel-wired-lan] [PATCH v10 iwl-next 1/7] ice: Don't check device type when checking GNSS presence

2024-09-12 Thread Karol Kolacinski
ce_id first, then set other variables. Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 90 drivers/net/ethernet/intel/ice/ice_common.h | 2 + drivers/net/ethernet/intel/ice/ice_gnss.c | 29 +++ drivers/net/ethernet/intel/ice/ice_gnss.h

[Intel-wired-lan] [PATCH v10 iwl-next 0/7] ice: Implement PTP support for E830 devices

2024-09-12 Thread Karol Kolacinski
. Jacob Keller (1): ice: Add unified ice_capture_crosststamp Karol Kolacinski (5): ice: Don't check device type when checking GNSS presence ice: Remove unncecessary ice_is_e8xx() functions ice: Use FIELD_PREP for timestamp values ice: Process TSYN IRQ in a separate function ice: Ref

[Intel-wired-lan] [PATCH v4 iwl-next 6/7] ice: Read SDP section from NVM for pin definitions

2024-08-30 Thread Karol Kolacinski
. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Yochai Hagvi Co-developed-by: Karol Kolacinski Signed-off-by: Karol Kolacinski Reviewed-by: Simon Horman --- .../net/ethernet/intel/ice/ice_adminq_cmd.h | 9 ++ drivers/net/ethernet/intel/ice/ice_ptp.c | 138 ++ drivers

[Intel-wired-lan] [PATCH v4 iwl-next 7/7] ice: Enable 1PPS out from CGU for E825C products

2024-08-30 Thread Karol Kolacinski
Kubalewski Signed-off-by: Sergey Temerkhanov Co-developed-by: Karol Kolacinski Signed-off-by: Karol Kolacinski Reviewed-by: Simon Horman --- V1 -> V2: Added return value description, renamed the function and enable parameter. Reworded commit message. drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v4 iwl-next 5/7] ice: Disable shared pin on E810 on setfunc

2024-08-30 Thread Karol Kolacinski
When setting a new supported function for a pin on E810, disable other enabled pin that shares the same GPIO. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski Reviewed-by: Simon Horman --- V1 -> V2: Fixed incorrect call to ice_ptp_set_sma_cfg_e810t() drivers/net/ether

[Intel-wired-lan] [PATCH v4 iwl-next 4/7] ice: Cache perout/extts requests and check flags

2024-08-30 Thread Karol Kolacinski
Signed-off-by: Karol Kolacinski Reviewed-by: Simon Horman --- V1 -> V2: Fixed unresolved merge conflict drivers/net/ethernet/intel/ice/ice_ptp.c | 360 +- drivers/net/ethernet/intel/ice/ice_ptp.h | 27 +- .../net/ethernet/intel/ice/ice_ptp_consts.h | 2 +- drivers/

[Intel-wired-lan] [PATCH v4 iwl-next 3/7] ice: Align E810T GPIO to other products

2024-08-30 Thread Karol Kolacinski
Instead of having separate PTP GPIO implementation for E810T, use existing one from all other products. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski Reviewed-by: Simon Horman --- V1 -> V2: restored blank line and moved enable and verify assignment drivers/net/ether

[Intel-wired-lan] [PATCH v4 iwl-next 2/7] ice: Add SDPs support for E825C

2024-08-30 Thread Karol Kolacinski
Add support of PTP SDPs (Software Definable Pins) for E825C products. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski Reviewed-by: Simon Horman --- V1 -> V2: Removed redundant n_pins assignment and enable and verify move drivers/net/ethernet/intel/ice/ice_ptp.c |

[Intel-wired-lan] [PATCH v4 iwl-next 1/7] ice: Implement ice_ptp_pin_desc

2024-08-30 Thread Karol Kolacinski
Add a new internal structure describing PTP pins. Use the new structure for all non-E810T products. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski Reviewed-by: Simon Horman --- V1 -> V2: Removed unused err variable drivers/net/ethernet/intel/ice/ice_ptp.c |

[Intel-wired-lan] [PATCH v4 iwl-next 0/7] ice: Cleanup and refactor PTP pin handling

2024-08-30 Thread Karol Kolacinski
This series cleans up current PTP GPIO pin handling, fixes minor bugs, refactors implementation for all products, introduces SDP (Software Definable Pins) for E825C and implements reading SDP section from NVM for E810 products. Karol Kolacinski (5): ice: Implement ice_ptp_pin_desc ice: Add

[Intel-wired-lan] [PATCH v9 iwl-next 7/7] ice: Implement PTP support for E830 devices

2024-08-29 Thread Karol Kolacinski
-by: Milena Olech Co-developed-by: Paul Greenwalt Signed-off-by: Paul Greenwalt Signed-off-by: Michal Michalik Co-developed-by: Karol Kolacinski Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 parts of other patches to this patch V6 -> V7: Fixed timestamp acquisition V4 -> V

[Intel-wired-lan] [PATCH v9 iwl-next 6/7] ice: Refactor ice_ptp_init_tx_*

2024-08-29 Thread Karol Kolacinski
Unify ice_ptp_init_tx_* functions for most of the MAC types except E82X. This simplifies the code for the future use with new MAC types. Reviewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V7 -> V8: Renamed the patch and reworded the commit message drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v9 iwl-next 5/7] ice: Add unified ice_capture_crosststamp

2024-08-29 Thread Karol Kolacinski
Reviewed-by: Przemek Kitszel Signed-off-by: Jacob Keller Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 cross timestamp handling to "ice: Implement PTP support for E830 devices" and explained the rest of previous changes in the commit description V4 -&g

[Intel-wired-lan] [PATCH v9 iwl-next 2/7] ice: Remove unncecessary ice_is_e8xx() functions

2024-08-29 Thread Karol Kolacinski
nally, because all further function calls check the MAC type anyway and this allows simpler code in the future with addition of the new MAC types. Reorder ICE_MAC_* cases in switches in ice_ptp* as in enum ice_mac_type. Signed-off-by: Karol Kolacinski --- V8 -> V9: Fixed compilation issue after r

[Intel-wired-lan] [PATCH v9 iwl-next 4/7] ice: Process TSYN IRQ in a separate function

2024-08-29 Thread Karol Kolacinski
iewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 timestamp handling to "ice: Implement PTP support for E830 devices" drivers/net/ethernet/intel/ice/ice_main.c | 18 + drivers/net/ethernet/intel/ice/ice_ptp.c | 49 ++

[Intel-wired-lan] [PATCH v9 iwl-next 3/7] ice: Use FIELD_PREP for timestamp values

2024-08-29 Thread Karol Kolacinski
Instead of using shifts and casts, use FIELD_PREP after reading 40b timestamp values. Reviewed-by: Simon Horman Signed-off-by: Karol Kolacinski --- V5 -> V6: Replaced removed macros with the new ones drivers/net/ethernet/intel/ice/ice_ptp_hw.c | 9 ++--- drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v9 iwl-next 1/7] ice: Don't check device type when checking GNSS presence

2024-08-29 Thread Karol Kolacinski
ce_id first, then set other variables. Signed-off-by: Karol Kolacinski --- drivers/net/ethernet/intel/ice/ice_common.c | 90 drivers/net/ethernet/intel/ice/ice_common.h | 2 + drivers/net/ethernet/intel/ice/ice_gnss.c | 29 +++ drivers/net/ethernet/intel/ice/ice_gnss.h

[Intel-wired-lan] [PATCH v9 iwl-next 0/7] ice: Implement PTP support for E830 devices

2024-08-29 Thread Karol Kolacinski
. Jacob Keller (1): ice: Add unified ice_capture_crosststamp Karol Kolacinski (5): ice: Don't check device type when checking GNSS presence ice: Remove unncecessary ice_is_e8xx() functions ice: Use FIELD_PREP for timestamp values ice: Process TSYN IRQ in a separate function ice: Ref

[Intel-wired-lan] [PATCH v3 iwl-next 7/7] ice: Enable 1PPS out from CGU for E825C products

2024-08-29 Thread Karol Kolacinski
Kubalewski Signed-off-by: Sergey Temerkhanov Co-developed-by: Karol Kolacinski Signed-off-by: Karol Kolacinski --- V1 -> V2: Added return value description, renamed the function and enable parameter. Reworded commit message. drivers/net/ethernet/intel/ice/ice_ptp.c|

[Intel-wired-lan] [PATCH v3 iwl-next 6/7] ice: Read SDP section from NVM for pin definitions

2024-08-29 Thread Karol Kolacinski
. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Yochai Hagvi Co-developed-by: Karol Kolacinski Signed-off-by: Karol Kolacinski --- .../net/ethernet/intel/ice/ice_adminq_cmd.h | 9 ++ drivers/net/ethernet/intel/ice/ice_ptp.c | 138 ++ drivers/net/ethernet/intel/ice

[Intel-wired-lan] [PATCH v3 iwl-next 5/7] ice: Disable shared pin on E810 on setfunc

2024-08-29 Thread Karol Kolacinski
When setting a new supported function for a pin on E810, disable other enabled pin that shares the same GPIO. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- V1 -> V2: Fixed incorrect call to ice_ptp_set_sma_cfg_e810t() drivers/net/ethernet/intel/ice/ice_ptp.c |

[Intel-wired-lan] [PATCH v3 iwl-next 4/7] ice: Cache perout/extts requests and check flags

2024-08-29 Thread Karol Kolacinski
Signed-off-by: Karol Kolacinski --- V1 -> V2: Fixed unresolved merge conflict drivers/net/ethernet/intel/ice/ice_ptp.c | 354 +- drivers/net/ethernet/intel/ice/ice_ptp.h | 27 +- .../net/ethernet/intel/ice/ice_ptp_consts.h | 2 +- drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v3 iwl-next 3/7] ice: Align E810T GPIO to other products

2024-08-29 Thread Karol Kolacinski
Instead of having separate PTP GPIO implementation for E810T, use existing one from all other products. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- V1 -> V2: restored blank line and moved enable and verify assignment drivers/net/ethernet/intel/ice/ice_gnss.c |

[Intel-wired-lan] [PATCH v3 iwl-next 2/7] ice: Add SDPs support for E825C

2024-08-29 Thread Karol Kolacinski
Add support of PTP SDPs (Software Definable Pins) for E825C products. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- V1 -> V2: Removed redundant n_pins assignment and enable and verify move drivers/net/ethernet/intel/ice/ice_ptp.c | 20 ++-- 1 f

[Intel-wired-lan] [PATCH v3 iwl-next 1/7] ice: Implement ice_ptp_pin_desc

2024-08-29 Thread Karol Kolacinski
Add a new internal structure describing PTP pins. Use the new structure for all non-E810T products. Reviewed-by: Arkadiusz Kubalewski Signed-off-by: Karol Kolacinski --- V1 -> V2: Removed unused err variable drivers/net/ethernet/intel/ice/ice_ptp.c | 270 +++ drivers/

[Intel-wired-lan] [PATCH v3 iwl-next 0/7] ice: Cleanup and refactor PTP pin handling

2024-08-29 Thread Karol Kolacinski
This series cleans up current PTP GPIO pin handling, fixes minor bugs, refactors implementation for all products, introduces SDP (Software Definable Pins) for E825C and implements reading SDP section from NVM for E810 products. Karol Kolacinski (5): ice: Implement ice_ptp_pin_desc ice: Add

[Intel-wired-lan] [PATCH v8 iwl-next 7/7] ice: Implement PTP support for E830 devices

2024-08-27 Thread Karol Kolacinski
-by: Milena Olech Co-developed-by: Paul Greenwalt Signed-off-by: Paul Greenwalt Signed-off-by: Michal Michalik Co-developed-by: Karol Kolacinski Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 parts of other patches to this patch V6 -> V7: Fixed timestamp acquisition V4 -> V

[Intel-wired-lan] [PATCH v8 iwl-next 6/7] ice: Refactor ice_ptp_init_tx_*

2024-08-27 Thread Karol Kolacinski
Unify ice_ptp_init_tx_* functions for most of the MAC types except E82X. This simplifies the code for the future use with new MAC types. Reviewed-by: Przemek Kitszel Signed-off-by: Karol Kolacinski --- V7 -> V8: Renamed the patch and reworded the commit message drivers/net/ethernet/intel/

[Intel-wired-lan] [PATCH v8 iwl-next 5/7] ice: Add unified ice_capture_crosststamp

2024-08-27 Thread Karol Kolacinski
Reviewed-by: Przemek Kitszel Signed-off-by: Jacob Keller Signed-off-by: Karol Kolacinski --- V7 -> V8: Moved E830 cross timestamp handling to "ice: Implement PTP support for E830 devices" and explained the rest of previous changes in the commit description V4 -&g

[Intel-wired-lan] [PATCH v8 iwl-next 3/7] ice: Use FIELD_PREP for timestamp values

2024-08-27 Thread Karol Kolacinski
Instead of using shifts and casts, use FIELD_PREP after reading 40b timestamp values. Reviewed-by: Simon Horman Signed-off-by: Karol Kolacinski --- V5 -> V6: Replaced removed macros with the new ones drivers/net/ethernet/intel/ice/ice_ptp_hw.c | 9 ++--- drivers/net/ethernet/intel/

  1   2   3   4   >