1GbE Intel Wired LAN Driver Updates 2020-11-30
Subsystems (4)
Tony Nguyen
maintainerThis series contains updates to e1000e driver only.
Mario Limonciello allows s0ix on supported ME systems and adds additional supported systems.
Vitaly changes configuration to allow for S0i3.2 substate.
The following are changes since commit e71d2b957ee49fe3ed35a384a4e31774de1316c1:
Merge branch 'net-ipa-start-adding-ipa-v4-5-support'
and are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue 1GbE
Mario Limonciello (3):
e1000e: allow turning s0ix flows on for systems with ME
e1000e: Add Dell's Comet Lake systems into s0ix heuristics
e1000e: Add more Dell CML systems into s0ix heuristics
Vitaly Lifshits (1):
e1000e: fix S0ix flow to allow S0i3.2 subset entry
.../device_drivers/ethernet/intel/e1000e.rst | 23 ++ drivers/net/ethernet/intel/Kconfig | 1 + drivers/net/ethernet/intel/e1000e/e1000.h | 7 + drivers/net/ethernet/intel/e1000e/netdev.c | 72 +++--- drivers/net/ethernet/intel/e1000e/param.c | 209 ++++++++++++++++++ 5 files changed, 270 insertions(+), 42 deletions(-)
Signature · 1 line
2.26.2
Tony Nguyen
maintainerPATCH 1/4 e1000e: allow turning s0ix flows on for systems with ME
From: Mario Limonciello <[email protected]>
S0ix for GBE flows are needed for allowing the system to get into deepest power state, but these require coordination of components outside of control of Linux kernel. For systems that have confirmed to coordinate this properly, allow turning on the s0ix flows at load time or runtime.
--- .../device_drivers/ethernet/intel/e1000e.rst | 23 ++++ drivers/net/ethernet/intel/e1000e/e1000.h | 7 ++ drivers/net/ethernet/intel/e1000e/netdev.c | 64 +++++----- drivers/net/ethernet/intel/e1000e/param.c | 110 ++++++++++++++++++ 4 files changed, 166 insertions(+), 38 deletions(-)
Documentation/networking/device_drivers/ethernet/intel/e1000e.rst +23 -0
@@ -249,6 +249,29 @@ Debug This parameter adjusts the level of debug messages displayed in the system logs. +EnableS0ix +---------- +:Valid Range: 0, 1, 2 +:Default Value: 1 (Use Heuristics) + + +-------+----------------+ + | Value | EnableS0ix | + +=======+================+ + | 0 | Disabled | + +-------+----------------+ + | 1 | Use Heuristics | + +-------+----------------+ + | 2 | Enabled | + +-------+----------------+ + +Controls whether the e1000e driver will attempt s0ix flows. S0ix flows require +correct platform configuration. By default the e1000e driver will use some heuristics +to decide whether to enable s0ix. This parameter can be used to override heuristics. + +Additionally a sysfs file "enable_s0ix" will be present that can change the value at +runtime. + +Note: This option is only effective on Cannon Point or later hardware. Additional Features and Configurations ======================================
drivers/net/ethernet/intel/e1000e/e1000.h +7 -0
@@ -436,6 +436,7 @@ s32 e1000e_get_base_timinca(struct e1000_adapter *adapter, u32 *timinca);#define FLAG2_DFLT_CRC_STRIPPING BIT(12)#define FLAG2_CHECK_RX_HWTSTAMP BIT(13)#define FLAG2_CHECK_SYSTIM_OVERFLOW BIT(14) +#define FLAG2_ENABLE_S0IX_FLOWS BIT(15)#define E1000_RX_DESC_PS (R , i) \ (&(((union e1000_rx_desc_packet_split *)((R).desc))[i]))
@@ -462,6 +463,12 @@ enum latency_range {extern char e1000e_driver_name[];void e1000e_check_options (struct e1000_adapter *adapter); +ssize_t enable_s0ix_store (struct device *dev, +struct device_attribute *attr, +const char *buf,size_t count); +ssize_t enable_s0ix_show (struct device *dev, +struct device_attribute *attr, +char *buf);void e1000e_set_ethtool_ops (struct net_device *netdev);int e1000e_open (struct net_device *netdev);
drivers/net/ethernet/intel/e1000e/netdev.c +26 -38
115 lines not on this page · raw message
drivers/net/ethernet/intel/e1000e/param.c +110 -0
126 lines not on this page · raw message
Signature · 1 line
2.26.2
Re: [net-next 1/4] e1000e: allow turning s0ix flows on for systems with ME
Quoted 43 lines · Tony Nguyen
From: Mario Limonciello <[email protected]>
S0ix for GBE flows are needed for allowing the system to get into deepest power state, but these require coordination of components outside of control of Linux kernel. For systems that have confirmed to coordinate this properly, allow turning on the s0ix flows at load time or runtime.
Fixes e086ba2fccda ("e1000e: disable s0ix entry and exit flows for ME systems")Signed-off-by Mario Limonciello <[email protected]>Tested-by Aaron Brown <[email protected]>Signed-off-by Tony Nguyen <[email protected]>--- .../device_drivers/ethernet/intel/e1000e.rst | 23 ++++ drivers/net/ethernet/intel/e1000e/e1000.h | 7 ++ drivers/net/ethernet/intel/e1000e/netdev.c | 64 +++++----- drivers/net/ethernet/intel/e1000e/param.c | 110 ++++++++++++++++++ 4 files changed, 166 insertions(+), 38 deletions(-)Documentation/networking/device_drivers/ethernet/intel/e1000e.rst +16
-0@@ -249,6 +249,29 @@ Debug This parameter adjusts the level of debug messages displayed in the system logs. +EnableS0ix +---------- +:Valid Range: 0, 1, 2 +:Default Value: 1 (Use Heuristics) + + +-------+----------------+ + | Value | EnableS0ix | + +=======+================+ + | 0 | Disabled | + +-------+----------------+ + | 1 | Use Heuristics | + +-------+----------------+ + | 2 | Enabled | + +-------+----------------+ + +Controls whether the e1000e driver will attempt s0ix flows. S0ix flows require
Documentation/networking/device_drivers/ethernet/intel/e1000e.rst Debug · line 277
Quoted 10 lines
Documentation/networking/device_drivers/ethernet/intel/e1000e.rst +7
-0+correct platform configuration. By default the e1000e driver will use some heuristics +to decide whether to enable s0ix. This parameter can be used to override heuristics. + +Additionally a sysfs file "enable_s0ix" will be present that can change the value at +runtime. + +Note: This option is only effective on Cannon Point or later hardware. Additional Features and Configurations ======================================
Generally the use of module parameters and sysfs usage are frowned upon. Based on the configuration isn't this something that could just be controlled via an ethtool priv flag? Couldn't you just have this default to whatever the heuristics decide at probe on and then support enabling/disabling it via the priv flag? You could look at igb_get_priv_flags/igb_set_priv_flags for an example of how to do what I am proposing.
I think it would simplify this quite a bit since you wouldn't have to implement sysfs show/store operations for the value and would instead be allowing for reading/setting via the get_priv_flags/set_priv_flags operations. In addition you could leave the code for checking what supports this in place and have it set a flag that can be read or overwritten.
RE: [net-next 1/4] e1000e: allow turning s0ix flows on for systems with ME
Quoted 3 lines
Generally the use of module parameters and sysfs usage are frowned upon.
I was trying to build on the existing module parameters that existed already for e1000e. So I guess I would ask, why are those not done in ethtool? Should those parameters go away and they migrate to ethtool for the same reasons as this?
Quoted 6 lines
Based on the configuration isn't this something that could just be controlled via an ethtool priv flag? Couldn't you just have this default to whatever the heuristics decide at probe on and then support enabling/disabling it via the priv flag? You could look at igb_get_priv_flags/igb_set_priv_flags for an example of how to do what I am proposing.
I don't disagree this solution would work, but it adds a new dependency on having ethtool and the kernel move together to enable it.
One advantage of the way this is done it allows shipping a system with an older Linux kernel that isn't yet recognized in the kernel heuristics to turn on by default with a small udev rule or kernel command line change.
For example systems that aren't yet released could have this documented on RHEL certification pages at release time for older RHEL releases before a patch to add to the heuristics has been backported.
Quoted 7 lines
I think it would simplify this quite a bit since you wouldn't have to implement sysfs show/store operations for the value and would instead be allowing for reading/setting via the get_priv_flags/set_priv_flags operations. In addition you could leave the code for checking what supports this in place and have it set a flag that can be read or overwritten.
If the consensus is to move in this direction, yes I'll redo the patch series and modify ethtool as well.
Re: [net-next 1/4] e1000e: allow turning s0ix flows on for systems with ME
Quoted 9 lines · Mario
Quoted 4 lines
Generally the use of module parameters and sysfs usage are frowned upon.
I was trying to build on the existing module parameters that existed already for e1000e. So I guess I would ask, why are those not done in ethtool? Should those parameters go away and they migrate to ethtool for the same reasons as this?
What it comes down to is that the existing module parameters are grandfathered in and we should not break things by removing them. New drivers aren't allowed to add them, and we are not supposed to add to them.
Quoted 9 lines
Quoted 6 lines
Based on the configuration isn't this something that could just be controlled via an ethtool priv flag? Couldn't you just have this default to whatever the heuristics decide at probe on and then support enabling/disabling it via the priv flag? You could look at igb_get_priv_flags/igb_set_priv_flags for an example of how to do what I am proposing.
I don't disagree this solution would work, but it adds a new dependency on having ethtool and the kernel move together to enable it.
Actually ethtool wouldn't have to change. The priv-flags are passed as strings to ethtool from the driver and set as a u32 bit flag array if I recall correctly.
Quoted 7 lines
One advantage of the way this is done it allows shipping a system with an older Linux kernel that isn't yet recognized in the kernel heuristics to turn on by default with a small udev rule or kernel command line change.
For example systems that aren't yet released could have this documented on RHEL certification pages at release time for older RHEL releases before a patch to add to the heuristics has been backported.
I suggest taking a look at the priv-flags interface. I am not suggesting adding a new interface to ethtool. It is an existing interface designed to allow for one-off features to be enabled/disabled on a given port.
Quoted 10 lines
Quoted 7 lines
I think it would simplify this quite a bit since you wouldn't have to implement sysfs show/store operations for the value and would instead be allowing for reading/setting via the get_priv_flags/set_priv_flags operations. In addition you could leave the code for checking what supports this in place and have it set a flag that can be read or overwritten.
If the consensus is to move in this direction, yes I'll redo the patch series and modify ethtool as well.
No changes needed to ethtool. The flags are driver specific which is why this would work, or are you saying this change will be needed for other drivers? If so then yes I would recommend coming up with a standard interface we can use for those drivers as well.
RE: [net-next 1/4] e1000e: allow turning s0ix flows on for systems with ME
Quoted 25 lines
Quoted 9 lines · Mario
Quoted 4 lines
Generally the use of module parameters and sysfs usage are frowned upon.
I was trying to build on the existing module parameters that existed already for e1000e. So I guess I would ask, why are those not done in ethtool? Should those parameters go away and they migrate to ethtool for the same reasons as this?
What it comes down to is that the existing module parameters are grandfathered in and we should not break things by removing them. New drivers aren't allowed to add them, and we are not supposed to add to them.
Quoted 7 lines
Quoted 6 lines
Based on the configuration isn't this something that could just be controlled via an ethtool priv flag? Couldn't you just have this default to whatever the heuristics decide at probe on and then support enabling/disabling it via the priv flag? You could look at igb_get_priv_flags/igb_set_priv_flags for an example of how to do what I am proposing.
Quoted 6 lines
Quoted 2 lines
I don't disagree this solution would work, but it adds a new dependency on having ethtool and the kernel move together to enable it.
Actually ethtool wouldn't have to change. The priv-flags are passed as strings to ethtool from the driver and set as a u32 bit flag array if I recall correctly.
Ah thanks, yeah I see that. So should this just be passing in and out priv->flags shifted and ORed with priv->flags2? IIRC both of those are 16 bits.
And like my suggested change a new bit in priv->flags2.
Quoted 5 lines
Quoted 5 lines
One advantage of the way this is done it allows shipping a system with an older Linux kernel that isn't yet recognized in the kernel heuristics to turn on by default with a small udev rule or kernel command line change.
Quoted 8 lines
Quoted 3 lines
For example systems that aren't yet released could have this documented on RHEL certification pages at release time for older RHEL releases before a patch to add to the heuristics has been backported.
I suggest taking a look at the priv-flags interface. I am not suggesting adding a new interface to ethtool. It is an existing interface designed to allow for one-off features to be enabled/disabled on a given port.
Yes, this makes more sense to me now, thanks.
Quoted 9 lines
Quoted 9 lines
Quoted 8 lines
I think it would simplify this quite a bit since you wouldn't have to implement sysfs show/store operations for the value and would instead be allowing for reading/setting via the get_priv_flags/set_priv_flags operations. In addition you could leave the code for checking what supports this in place and have it set a flag that can be read or overwritten.
Quoted 7 lines
Quoted 2 lines
If the consensus is to move in this direction, yes I'll redo the patch series and modify ethtool as well.
No changes needed to ethtool. The flags are driver specific which is why this would work, or are you saying this change will be needed for other drivers? If so then yes I would recommend coming up with a standard interface we can use for those drivers as well.
I don't expect this to be needed in any other drivers right now.
Jakub Kicinski
maintainerRe: [net-next 1/4] e1000e: allow turning s0ix flows on for systems with ME
In reply to Tony NguyenQuoted 6 lines · On Mon, 30 Nov 2020 13:29:04 -0800 Tony Nguyen wrote:
From: Mario Limonciello <[email protected]>
S0ix for GBE flows are needed for allowing the system to get into deepest power state, but these require coordination of components outside of control of Linux kernel. For systems that have confirmed to coordinate this properly, allow turning on the s0ix flows at load time or runtime.
Please CC PCI, power management, (and ACPI?) people on the next version of this change.
Alex's suggestion of ethtool flags is definitely an improvement, but it'd be even better if we didn't have to add PCI/PM specific knobs to networking APIs.
Tony Nguyen
maintainerPATCH 2/4 e1000e: Add Dell's Comet Lake systems into s0ix heuristics
In reply to Tony NguyenFrom: Mario Limonciello <[email protected]>
Dell's Comet Lake Latitude and Precision systems containing i219LM are properly configured and should use the s0ix flows.
--- drivers/net/ethernet/intel/Kconfig | 1 + drivers/net/ethernet/intel/e1000e/param.c | 80 ++++++++++++++++++++++- 2 files changed, 80 insertions(+), 1 deletion(-)
drivers/net/ethernet/intel/Kconfig +1 -0
@@ -58,6 +58,7 @@ config E1000 config E1000E tristate "Intel(R) PRO/1000 PCI-Express Gigabit Ethernet support" depends on PCI && (!SPARC32 || BROKEN) + depends on DMI select CRC32 imply PTP_1588_CLOCK help
drivers/net/ethernet/intel/e1000e/param.c +79 -1
99 lines not on this page · raw message
Signature · 1 line
2.26.2
Re: [net-next 2/4] e1000e: Add Dell's Comet Lake systems into s0ix heuristics
Quoted 19 lines · Tony Nguyen
From: Mario Limonciello <[email protected]>
Dell's Comet Lake Latitude and Precision systems containing i219LM are properly configured and should use the s0ix flows.
Signed-off-by Mario Limonciello <[email protected]>Tested-by Yijun Shen <[email protected]>Signed-off-by Tony Nguyen <[email protected]>--- drivers/net/ethernet/intel/Kconfig | 1 + drivers/net/ethernet/intel/e1000e/param.c | 80 ++++++++++++++++++++++- 2 files changed, 80 insertions(+), 1 deletion(-)drivers/net/ethernet/intel/Kconfig +0
-0
drivers/net/ethernet/intel/Kconfig config E1000 · line 64
Quoted 7 lines
drivers/net/ethernet/intel/Kconfig +1
-0@@ -58,6 +58,7 @@ config E1000 config E1000E tristate "Intel(R) PRO/1000 PCI-Express Gigabit Ethernet support" depends on PCI && (!SPARC32 || BROKEN) + depends on DMI select CRC32 imply PTP_1588_CLOCK help
Is DMI the only way we can identify systems that want to enable S0ix states? I'm just wondering if we could identify these parts using a 4 tuple device ID or if the DMI ID is the only way we can do this?
Quoted 80 lines
drivers/net/ethernet/intel/e1000e/param.c +65
-0@@ -1,6 +1,7 @@// SPDX-License-Identifier: GPL-2.0 /* Copyright(c) 1999 - 2018 Intel Corporation. */ +#include <linux/dmi.h> #include <linux/netdevice.h> #include <linux/module.h> #include <linux/pci.h> @@ -201,6 +202,80 @@ static const struct e1000e_me_supported me_supported[] = { {0} }; +static const struct dmi_system_id s0ix_supported_systems[] = { + { +/* Dell Latitude 5310 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"099F" ), + }, + }, + { +/* Dell Latitude 5410 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09A0" ), + }, + }, + { +/* Dell Latitude 5410 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C9" ), + }, + }, + { +/* Dell Latitude 5510 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09A1" ), + }, + }, + { +/* Dell Precision 3550 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09A2" ), + }, + }, + { +/* Dell Latitude 5411 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C0" ), + }, + }, + { +/* Dell Latitude 5511 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C1" ), + }, + }, + { +/* Dell Precision 3551 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C2" ), + }, + }, + { +/* Dell Precision 7550 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C3" ), + }, + },
drivers/net/ethernet/intel/e1000e/param.c static const struct e1000e_me_supported me_supported[] = { · line 278
Quoted 10 lines
drivers/net/ethernet/intel/e1000e/param.c +10
-0+ { +/* Dell Precision 7750 */ + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_SKU, "09C4"), + }, + }, + { } +}; +
So which "product" are we verifying here? Are these SKU values for the platform or for the NIC? Just wondering if this is something we could retrieve via PCI as I mentioned or if this is something that can only be retrieved via DMI.
Quoted 6 lines
drivers/net/ethernet/intel/e1000e/param.c +0
-0static bool e1000e_check_me (u16 device_id) {struct e1000e_me_supported *id;@@ -599,8 +674,11 @@ void e1000e_check_options(struct e1000_adapter *adapter) }
drivers/net/ethernet/intel/e1000e/param.c void e1000e_check_options(struct e1000_adapter *adapter) · line 684
Quoted 10 lines
drivers/net/ethernet/intel/e1000e/param.c +4
-1if (enabled ==S0IX_HEURISTICS ) { +/* check for allowlist of systems */ +if (dmi_check_system (s0ix_supported_systems)) + enabled =S0IX_FORCE_ON ;/* default to off for ME configurations */ -if (e1000e_check_me (hw->adapter->pdev->device)) +else if (e1000e_check_me (hw->adapter->pdev->device)) enabled =S0IX_FORCE_OFF ; }
Is there really a need to set it to SOIX_FORCE_ON when the if statement below this section will essentially treat it as though it is set that way anyway? Seems like we only really need to just do a (!dmi_check_system() && e1000e_check_me()) in the code block that is setting SOIX_FORCE_OFF rather than bothering to even set enabled to SOIX_FORCE_ON.
RE: [net-next 2/4] e1000e: Add Dell's Comet Lake systems into s0ix heuristics
Quoted 18 lines
Quoted 9 lines · Tony Nguyen
From: Mario Limonciello <[email protected]>
Dell's Comet Lake Latitude and Precision systems containing i219LM are properly configured and should use the s0ix flows.
Signed-off-by Mario Limonciello <[email protected]>Tested-by Yijun Shen <[email protected]>Signed-off-by Tony Nguyen <[email protected]>Review
Quoted 6 lines
--- drivers/net/ethernet/intel/Kconfig | 1 + drivers/net/ethernet/intel/e1000e/param.c | 80 ++++++++++++++++++++++- 2 files changed, 80 insertions(+), 1 deletion(-)(quoted diff) +0
-0b/drivers/net/ethernet/intel/Kconfig
Quoted 15 lines
drivers/net/ethernet/intel/Kconfig config E1000 · line 64
Quoted 11 lines
index
5aa86318ed3e..280af47d74d2100644drivers/net/ethernet/intel/Kconfig +1
-0@@ -58,6 +58,7 @@ config E1000 config E1000E tristate "Intel(R) PRO/1000 PCI-Express Gigabit Ethernet support" depends on PCI && (!SPARC32 || BROKEN) + depends on DMI select CRC32 imply PTP_1588_CLOCK helpIs DMI the only way we can identify systems that want to enable S0ix states? I'm just wondering if we could identify these parts using a 4 tuple device ID or if the DMI ID is the only way we can do this?
I'll have to check if the PCI susbsystem vendor ID is set on this device. That's the only other thing that comes to mind for me.
Quoted 90 lines
Review
Quoted 2 lines
(quoted diff) +0
-0
b/drivers/net/ethernet/intel/e1000e/param.cdrivers/net/ethernet/intel/e1000e/param.c static const struct e1000e_me_supported me_supported[]
Quoted 12 lines
index
56316b797521..d05f55201541100644drivers/net/ethernet/intel/e1000e/param.c +1
-0@@ -1,6 +1,7 @@// SPDX-License-Identifier: GPL-2.0 /* Copyright(c) 1999 - 2018 Intel Corporation. */ +#include <linux/dmi.h> #include <linux/netdevice.h> #include <linux/module.h> #include <linux/pci.h> @@ -201,6 +202,80 @@ static const struct e1000e_me_supported me_supported[]= {
Quoted 74 lines
drivers/net/ethernet/intel/e1000e/param.c +71
-0{0} }; +static const struct dmi_system_id s0ix_supported_systems[] = { + { +/* Dell Latitude 5310 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"099F" ), + }, + }, + { +/* Dell Latitude 5410 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09A0" ), + }, + }, + { +/* Dell Latitude 5410 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C9" ), + }, + }, + { +/* Dell Latitude 5510 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09A1" ), + }, + }, + { +/* Dell Precision 3550 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09A2" ), + }, + }, + { +/* Dell Latitude 5411 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C0" ), + }, + }, + { +/* Dell Latitude 5511 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C1" ), + }, + }, + { +/* Dell Precision 3551 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C2" ), + }, + }, + { +/* Dell Precision 7550 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C3" ), + }, + }, + { +/* Dell Precision 7750 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_SKU ,"09C4" ), + }, + },
Quoted 8 lines
drivers/net/ethernet/intel/e1000e/param.c static const struct e1000e_me_supported me_supported[] = { · line 278
Quoted 3 lines
drivers/net/ethernet/intel/e1000e/param.c +3
-0+ { } +}; +So which "product" are we verifying here? Are these SKU values for the platform or for the NIC? Just wondering if this is something we could retrieve via PCI as I mentioned or if this is something that can only be retrieved via DMI.
These are for the platform. The platform needs to be properly configured for doing s0ix flows.
Quoted 19 lines
drivers/net/ethernet/intel/e1000e/param.c void e1000e_check_options(struct e1000_adapter
Quoted 5 lines
drivers/net/ethernet/intel/e1000e/param.c +0
-0static bool e1000e_check_me (u16 device_id) {struct e1000e_me_supported *id;@@ -599,8 +674,11 @@ void e1000e_check_options(struct e1000_adapter*adapter)
drivers/net/ethernet/intel/e1000e/param.c void e1000e_check_options(struct e1000_adapter *adapter) · line 684
Quoted 12 lines
drivers/net/ethernet/intel/e1000e/param.c +4
-1}if (enabled ==S0IX_HEURISTICS ) { +/* check for allowlist of systems */ +if (dmi_check_system (s0ix_supported_systems)) + enabled =S0IX_FORCE_ON ;/* default to off for ME configurations */ -if (e1000e_check_me (hw->adapter->pdev->device)) +else if (e1000e_check_me (hw->adapter->pdev->device)) enabled =S0IX_FORCE_OFF ; }
Quoted 6 lines
Is there really a need to set it to
SOIX_FORCE_ONwhen the if statement below this section will essentially treat it as though it is set that way anyway? Seems like we only really need to just do a (!dmi_check_system() &&e1000e_check_me()) in the code block that is settingSOIX_FORCE_OFFrather than bothering to even set enabled toSOIX_FORCE_ON.
Yes there are possible logic optimizations, but I wanted to make it very explicit what was happening so that when new heuristics get added later it makes sense.
Tony Nguyen
maintainerPATCH 3/4 e1000e: Add more Dell CML systems into s0ix heuristics
In reply to Tony NguyenFrom: Mario Limonciello <[email protected]>
These comet lake systems are not yet released, but have been validated on pre-release hardware.
This is being submitted separately from released hardware in case of a regression between pre-release and release hardware so this commit can be reverted alone.
--- drivers/net/ethernet/intel/e1000e/param.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+)
drivers/net/ethernet/intel/e1000e/param.c +21 -0
@@ -273,6 +273,27 @@ static const struct dmi_system_id s0ix_supported_systems[] = { DMI_MATCH(DMI_PRODUCT_SKU, "09C4"), }, }, + { + /* Dell Notebook 0x0A40 */ + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_SKU, "0A40"), + }, + }, + { + /* Dell Notebook 0x0A41 */ + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_SKU, "0A41"), + }, + }, + { + /* Dell Notebook 0x0A42 */ + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_SKU, "0A42"), + }, + }, { } };
Signature · 1 line
2.26.2
Tony Nguyen
maintainerPATCH 4/4 e1000e: fix S0ix flow to allow S0i3.2 subset entry
In reply to Tony NguyenFrom: Vitaly Lifshits <[email protected]>
Change configuration in the flows to align with architecture requirements to achieve S0i3.2 substate.
Also fix a typo in the previous commit 632fbd5eb5b0 ("e1000e: fix S0ix flows for cable connected case").
--- drivers/net/ethernet/intel/e1000e/netdev.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/net/ethernet/intel/e1000e/netdev.c +4 -4
@@ -6447,13 +6447,13 @@ static void e1000e_s0ix_entry_flow(struct e1000_adapter *adapter)/* Ungate PGCB clock */ mac_data =er32 (FEXTNVM9 ); - mac_data |=BIT (28 ); + mac_data &= ~BIT (28 );ew32 (FEXTNVM9 , mac_data);/* Enable K1 off to enable mPHY Power Gating */ mac_data =er32 (FEXTNVM6 ); mac_data |=BIT (31 ); -ew32 (FEXTNVM12 , mac_data); +ew32 (FEXTNVM6 , mac_data);/* Enable mPHY power gating for any link and speed */ mac_data =er32 (FEXTNVM8 );
@@ -6497,11 +6497,11 @@ static void e1000e_s0ix_exit_flow(struct e1000_adapter *adapter)/* Disable K1 off */ mac_data =er32 (FEXTNVM6 ); mac_data &= ~BIT (31 ); -ew32 (FEXTNVM12 , mac_data); +ew32 (FEXTNVM6 , mac_data);/* Disable Ungate PGCB clock */ mac_data =er32 (FEXTNVM9 ); - mac_data &= ~BIT (28 ); + mac_data |=BIT (28 );ew32 (FEXTNVM9 , mac_data);/* Cancel not waking from dynamic
Signature · 1 line
2.26.2