All of lore.kernel.org
 help / color / mirror / Atom feed
* [Intel-wired-lan] [PATCH v2 1/1] e1000e: Enable GPT clock before sending message to CSME
@ 2022-05-08  7:09 Sasha Neftin
  2022-05-08  8:08 ` Paul Menzel
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Sasha Neftin @ 2022-05-08  7:09 UTC (permalink / raw)
  To: intel-wired-lan

On corporate (CSME) ADL systems, the Ethernet Controller may stop working
("HW unit hang") after exiting from the s0ix state. The reason is that
CSME misses the message sent by the host. Enabling the dynamic GPT clock
solves this problem. This clock is cleared upon HW initialization.

Fixes: 3e55d231716e ("e1000e: Add handshake with the CSME to support S0ix")
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=214821
Reviewed-by: Dima Ruinskiy <dima.ruinskiy@intel.com>
Signed-off-by: Sasha Neftin <sasha.neftin@intel.com>
---
v2:
Correct commit message and minor fix in comment.
 drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/net/ethernet/intel/e1000e/netdev.c b/drivers/net/ethernet/intel/e1000e/netdev.c
index fa06f68c8c80..c64102b29862 100644
--- a/drivers/net/ethernet/intel/e1000e/netdev.c
+++ b/drivers/net/ethernet/intel/e1000e/netdev.c
@@ -6494,6 +6494,10 @@ static void e1000e_s0ix_exit_flow(struct e1000_adapter *adapter)
 
 	if (er32(FWSM) & E1000_ICH_FWSM_FW_VALID &&
 	    hw->mac.type >= e1000_pch_adp) {
+		/* Keep the GPT clock enabled for CSME */
+		mac_data = er32(FEXTNVM);
+		mac_data |= BIT(3);
+		ew32(FEXTNVM, mac_data);
 		/* Request ME unconfigure the device from S0ix */
 		mac_data = er32(H2ME);
 		mac_data &= ~E1000_H2ME_START_DPG;
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [Intel-wired-lan] [PATCH v2 1/1] e1000e: Enable GPT clock before sending message to CSME
  2022-05-08  7:09 [Intel-wired-lan] [PATCH v2 1/1] e1000e: Enable GPT clock before sending message to CSME Sasha Neftin
@ 2022-05-08  8:08 ` Paul Menzel
  2022-05-19  8:42 ` Chia-Lin Kao
  2022-05-19  9:51 ` naamax.meir
  2 siblings, 0 replies; 4+ messages in thread
From: Paul Menzel @ 2022-05-08  8:08 UTC (permalink / raw)
  To: intel-wired-lan

Dear Sasha,


Am 08.05.22 um 09:09 schrieb Sasha Neftin:
> On corporate (CSME) ADL systems, the Ethernet Controller may stop working
> ("HW unit hang") after exiting from the s0ix state. The reason is that
> CSME misses the message sent by the host.

What message exactly by the way?

> Enabling the dynamic GPT clock solves this problem. This clock is
> cleared upon HW initialization.
?Enabling? sounds like it?s not running before. But reading the comment, 
it?s running. Could you make that more clear please? The GPT clock is 
running when in S0ix?

Lastly, is that a CSME firmware bug and what CSME firmware version was it?

> Fixes: 3e55d231716e ("e1000e: Add handshake with the CSME to support S0ix")
> Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=214821
> Reviewed-by: Dima Ruinskiy <dima.ruinskiy@intel.com>
> Signed-off-by: Sasha Neftin <sasha.neftin@intel.com>
> ---
> v2:
> Correct commit message and minor fix in comment.
>   drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++++
>   1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/net/ethernet/intel/e1000e/netdev.c b/drivers/net/ethernet/intel/e1000e/netdev.c
> index fa06f68c8c80..c64102b29862 100644
> --- a/drivers/net/ethernet/intel/e1000e/netdev.c
> +++ b/drivers/net/ethernet/intel/e1000e/netdev.c
> @@ -6494,6 +6494,10 @@ static void e1000e_s0ix_exit_flow(struct e1000_adapter *adapter)
>   
>   	if (er32(FWSM) & E1000_ICH_FWSM_FW_VALID &&
>   	    hw->mac.type >= e1000_pch_adp) {
> +		/* Keep the GPT clock enabled for CSME */
> +		mac_data = er32(FEXTNVM);
> +		mac_data |= BIT(3);
> +		ew32(FEXTNVM, mac_data);
>   		/* Request ME unconfigure the device from S0ix */
>   		mac_data = er32(H2ME);
>   		mac_data &= ~E1000_H2ME_START_DPG;


Kind regards,

Paul

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Intel-wired-lan] [PATCH v2 1/1] e1000e: Enable GPT clock before sending message to CSME
  2022-05-08  7:09 [Intel-wired-lan] [PATCH v2 1/1] e1000e: Enable GPT clock before sending message to CSME Sasha Neftin
  2022-05-08  8:08 ` Paul Menzel
@ 2022-05-19  8:42 ` Chia-Lin Kao
  2022-05-19  9:51 ` naamax.meir
  2 siblings, 0 replies; 4+ messages in thread
From: Chia-Lin Kao @ 2022-05-19  8:42 UTC (permalink / raw)
  To: intel-wired-lan

On Sun, May 08, 2022 at 10:09:05AM +0300, Sasha Neftin wrote:
> On corporate (CSME) ADL systems, the Ethernet Controller may stop working
> ("HW unit hang") after exiting from the s0ix state. The reason is that
> CSME misses the message sent by the host. Enabling the dynamic GPT clock
> solves this problem. This clock is cleared upon HW initialization.
> 
> Fixes: 3e55d231716e ("e1000e: Add handshake with the CSME to support S0ix")
> Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=214821
> Reviewed-by: Dima Ruinskiy <dima.ruinskiy@intel.com>
> Signed-off-by: Sasha Neftin <sasha.neftin@intel.com>

This commit fixed the hardware unit hang issue on my machine.

Tested-by: Chia-Lin Kao (AceLan) <acelan.kao@canonical.com>
> ---
> v2:
> Correct commit message and minor fix in comment.
>  drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/net/ethernet/intel/e1000e/netdev.c b/drivers/net/ethernet/intel/e1000e/netdev.c
> index fa06f68c8c80..c64102b29862 100644
> --- a/drivers/net/ethernet/intel/e1000e/netdev.c
> +++ b/drivers/net/ethernet/intel/e1000e/netdev.c
> @@ -6494,6 +6494,10 @@ static void e1000e_s0ix_exit_flow(struct e1000_adapter *adapter)
>  
>  	if (er32(FWSM) & E1000_ICH_FWSM_FW_VALID &&
>  	    hw->mac.type >= e1000_pch_adp) {
> +		/* Keep the GPT clock enabled for CSME */
> +		mac_data = er32(FEXTNVM);
> +		mac_data |= BIT(3);
> +		ew32(FEXTNVM, mac_data);
>  		/* Request ME unconfigure the device from S0ix */
>  		mac_data = er32(H2ME);
>  		mac_data &= ~E1000_H2ME_START_DPG;

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Intel-wired-lan] [PATCH v2 1/1] e1000e: Enable GPT clock before sending message to CSME
  2022-05-08  7:09 [Intel-wired-lan] [PATCH v2 1/1] e1000e: Enable GPT clock before sending message to CSME Sasha Neftin
  2022-05-08  8:08 ` Paul Menzel
  2022-05-19  8:42 ` Chia-Lin Kao
@ 2022-05-19  9:51 ` naamax.meir
  2 siblings, 0 replies; 4+ messages in thread
From: naamax.meir @ 2022-05-19  9:51 UTC (permalink / raw)
  To: intel-wired-lan

On 5/8/2022 10:09, Sasha Neftin wrote:
> On corporate (CSME) ADL systems, the Ethernet Controller may stop working
> ("HW unit hang") after exiting from the s0ix state. The reason is that
> CSME misses the message sent by the host. Enabling the dynamic GPT clock
> solves this problem. This clock is cleared upon HW initialization.
> 
> Fixes: 3e55d231716e ("e1000e: Add handshake with the CSME to support S0ix")
> Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=214821
> Reviewed-by: Dima Ruinskiy <dima.ruinskiy@intel.com>
> Signed-off-by: Sasha Neftin <sasha.neftin@intel.com>
> ---
> v2:
> Correct commit message and minor fix in comment.
>   drivers/net/ethernet/intel/e1000e/netdev.c | 4 ++++
>   1 file changed, 4 insertions(+)
Tested-by: Naama Meir <naamax.meir@linux.intel.com>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-05-19  9:51 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-08  7:09 [Intel-wired-lan] [PATCH v2 1/1] e1000e: Enable GPT clock before sending message to CSME Sasha Neftin
2022-05-08  8:08 ` Paul Menzel
2022-05-19  8:42 ` Chia-Lin Kao
2022-05-19  9:51 ` naamax.meir

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.