platform-driver-x86.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] platform/x86: pmc_atom: Add Lex 3I380NX industrial PC to critclk_systems DMI table
@ 2022-07-19 12:48 Paul Spooren
  2022-07-28 18:31 ` Hans de Goede
  0 siblings, 1 reply; 2+ messages in thread
From: Paul Spooren @ 2022-07-19 12:48 UTC (permalink / raw)
  To: Hans de Goede, Mark Gross
  Cc: platform-driver-x86, linux-kernel, Paul Spooren, Michael Schöne

The Lex 3I380NX industrial PC has 4 ethernet controllers on board
which need pmc_plt_clk0 - 3 to function, add it to the critclk_systems
DMI table, so that drivers/clk/x86/clk-pmc-atom.c will mark the clocks
as CLK_CRITICAL and they will not get turned off.

This commit is nearly redundant to 3d0818f5eba8 ("platform/x86:
pmc_atom: Add Lex 3I380D industrial PC to critclk_systems DMI table")
but for the 3I380NX device.

The original vendor firmware is only available using the WaybackMachine:
http://www.lex.com.tw/products/3I380NX.html

Signed-off-by: Michael Schöne <michael.schoene@rhebo.com>
Signed-off-by: Paul Spooren <paul.spooren@rhebo.com>
---
 drivers/platform/x86/pmc_atom.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/drivers/platform/x86/pmc_atom.c b/drivers/platform/x86/pmc_atom.c
index b8b1ed1406de..15973a400e43 100644
--- a/drivers/platform/x86/pmc_atom.c
+++ b/drivers/platform/x86/pmc_atom.c
@@ -397,6 +397,15 @@ static const struct dmi_system_id critclk_systems[] = {
 			DMI_MATCH(DMI_PRODUCT_NAME, "3I380D"),
 		},
 	},
+	{
+		/* pmc_plt_clk0 - 3 are used for the 4 ethernet controllers */
+		.ident = "Lex 3I380NX",
+		.callback = dmi_callback,
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "Lex BayTrail"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "3I380NX"),
+		},
+	},
 	{
 		/* pmc_plt_clk* - are used for ethernet controllers */
 		.ident = "Lex 2I385SW",
-- 
2.32.1 (Apple Git-133)


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

* Re: [PATCH] platform/x86: pmc_atom: Add Lex 3I380NX industrial PC to critclk_systems DMI table
  2022-07-19 12:48 [PATCH] platform/x86: pmc_atom: Add Lex 3I380NX industrial PC to critclk_systems DMI table Paul Spooren
@ 2022-07-28 18:31 ` Hans de Goede
  0 siblings, 0 replies; 2+ messages in thread
From: Hans de Goede @ 2022-07-28 18:31 UTC (permalink / raw)
  To: Paul Spooren, Mark Gross
  Cc: platform-driver-x86, linux-kernel, Michael Schöne

Hi,

On 7/19/22 14:48, Paul Spooren wrote:
> The Lex 3I380NX industrial PC has 4 ethernet controllers on board
> which need pmc_plt_clk0 - 3 to function, add it to the critclk_systems
> DMI table, so that drivers/clk/x86/clk-pmc-atom.c will mark the clocks
> as CLK_CRITICAL and they will not get turned off.
> 
> This commit is nearly redundant to 3d0818f5eba8 ("platform/x86:
> pmc_atom: Add Lex 3I380D industrial PC to critclk_systems DMI table")
> but for the 3I380NX device.
> 
> The original vendor firmware is only available using the WaybackMachine:
> http://www.lex.com.tw/products/3I380NX.html
> 
> Signed-off-by: Michael Schöne <michael.schoene@rhebo.com>
> Signed-off-by: Paul Spooren <paul.spooren@rhebo.com>

Thank you for the patch.

The last week I have received 2 different patches adding
a total of 3 new "Lex BayTrail" entries to critclk_systems[]
on top of the existing 2.

Looking at: https://www.lex.com.tw/products/embedded-ipc-board/
we can see that Lex BayTrail makes many embedded boards with
multiple ethernet boards and none of their products are battery
powered so we don't need to worry (too much) about power consumption
when suspended.

So instead of adding 3 new entries I've written a patch to
simply disable the turning off of the clocks on all
systems which have "Lex BayTrail" as their DMI sys_vendor:

https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/commit/?h=review-hans&id=f046d13750b759f090cae13e47cab06b023a700b

I've added a Reported-by tag to give you credit for the work
you have done on this.

I will send this alternative fix to Linus as part of
the other pdx86 patches for 5.21.

Regards,

Hans




> ---
>  drivers/platform/x86/pmc_atom.c | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/drivers/platform/x86/pmc_atom.c b/drivers/platform/x86/pmc_atom.c
> index b8b1ed1406de..15973a400e43 100644
> --- a/drivers/platform/x86/pmc_atom.c
> +++ b/drivers/platform/x86/pmc_atom.c
> @@ -397,6 +397,15 @@ static const struct dmi_system_id critclk_systems[] = {
>  			DMI_MATCH(DMI_PRODUCT_NAME, "3I380D"),
>  		},
>  	},
> +	{
> +		/* pmc_plt_clk0 - 3 are used for the 4 ethernet controllers */
> +		.ident = "Lex 3I380NX",
> +		.callback = dmi_callback,
> +		.matches = {
> +			DMI_MATCH(DMI_SYS_VENDOR, "Lex BayTrail"),
> +			DMI_MATCH(DMI_PRODUCT_NAME, "3I380NX"),
> +		},
> +	},
>  	{
>  		/* pmc_plt_clk* - are used for ethernet controllers */
>  		.ident = "Lex 2I385SW",


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

end of thread, other threads:[~2022-07-28 18:31 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-19 12:48 [PATCH] platform/x86: pmc_atom: Add Lex 3I380NX industrial PC to critclk_systems DMI table Paul Spooren
2022-07-28 18:31 ` Hans de Goede

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).