All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] platform/x86: intel_pmc_core: add ACPI dependency
@ 2021-04-21 13:49 Arnd Bergmann
  2021-04-21 14:14 ` Hans de Goede
  2021-04-21 17:32 ` David E. Box
  0 siblings, 2 replies; 3+ messages in thread
From: Arnd Bergmann @ 2021-04-21 13:49 UTC (permalink / raw)
  To: Hans de Goede, Mark Gross, David E. Box, Gayatri Kammela
  Cc: Arnd Bergmann, Andy Shevchenko, Lee Jones, Maximilian Luz,
	Mika Westerberg, platform-driver-x86, linux-kernel

From: Arnd Bergmann <arnd@arndb.de>

The driver now fails to build without ACPI:

drivers/platform/x86/intel_pmc_core.c: In function 'pmc_core_get_tgl_lpm_reqs':
drivers/platform/x86/intel_pmc_core.c:617:41: error: invalid use of undefined type 'struct acpi_device'
  617 |         out_obj = acpi_evaluate_dsm(adev->handle, &s0ix_dsm_guid, 0,

This could probably be made optional, but it won't be used without
ACPI in practice, so just add a Kconfig dependency.

Fixes: 428131364f00 ("platform/x86: intel_pmc_core: Get LPM requirements for Tiger Lake")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/platform/x86/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/platform/x86/Kconfig b/drivers/platform/x86/Kconfig
index 697fc446ac41..2714f7c3843e 100644
--- a/drivers/platform/x86/Kconfig
+++ b/drivers/platform/x86/Kconfig
@@ -1194,6 +1194,7 @@ config INTEL_MRFLD_PWRBTN
 config INTEL_PMC_CORE
 	tristate "Intel PMC Core driver"
 	depends on PCI
+	depends on ACPI
 	help
 	  The Intel Platform Controller Hub for Intel Core SoCs provides access
 	  to Power Management Controller registers via various interfaces. This
-- 
2.29.2


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

* Re: [PATCH] platform/x86: intel_pmc_core: add ACPI dependency
  2021-04-21 13:49 [PATCH] platform/x86: intel_pmc_core: add ACPI dependency Arnd Bergmann
@ 2021-04-21 14:14 ` Hans de Goede
  2021-04-21 17:32 ` David E. Box
  1 sibling, 0 replies; 3+ messages in thread
From: Hans de Goede @ 2021-04-21 14:14 UTC (permalink / raw)
  To: Arnd Bergmann, Mark Gross, David E. Box, Gayatri Kammela
  Cc: Arnd Bergmann, Andy Shevchenko, Lee Jones, Maximilian Luz,
	Mika Westerberg, platform-driver-x86, linux-kernel

Hi,

On 4/21/21 3:49 PM, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> The driver now fails to build without ACPI:
> 
> drivers/platform/x86/intel_pmc_core.c: In function 'pmc_core_get_tgl_lpm_reqs':
> drivers/platform/x86/intel_pmc_core.c:617:41: error: invalid use of undefined type 'struct acpi_device'
>   617 |         out_obj = acpi_evaluate_dsm(adev->handle, &s0ix_dsm_guid, 0,
> 
> This could probably be made optional, but it won't be used without
> ACPI in practice, so just add a Kconfig dependency.
> 
> Fixes: 428131364f00 ("platform/x86: intel_pmc_core: Get LPM requirements for Tiger Lake")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Thank you for your patch, I've applied this patch to my review-hans 
branch:
https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/log/?h=review-hans

Note it will show up in my review-hans branch once I've pushed my
local branch there, which might take a while.

Once I've run some tests on this branch the patches there will be
added to the platform-drivers-x86/for-next branch and eventually
will be included in the pdx86 pull-request to Linus for the next
merge-window.

Regards,

Hans




> ---
>  drivers/platform/x86/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/platform/x86/Kconfig b/drivers/platform/x86/Kconfig
> index 697fc446ac41..2714f7c3843e 100644
> --- a/drivers/platform/x86/Kconfig
> +++ b/drivers/platform/x86/Kconfig
> @@ -1194,6 +1194,7 @@ config INTEL_MRFLD_PWRBTN
>  config INTEL_PMC_CORE
>  	tristate "Intel PMC Core driver"
>  	depends on PCI
> +	depends on ACPI
>  	help
>  	  The Intel Platform Controller Hub for Intel Core SoCs provides access
>  	  to Power Management Controller registers via various interfaces. This
> 


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

* Re: [PATCH] platform/x86: intel_pmc_core: add ACPI dependency
  2021-04-21 13:49 [PATCH] platform/x86: intel_pmc_core: add ACPI dependency Arnd Bergmann
  2021-04-21 14:14 ` Hans de Goede
@ 2021-04-21 17:32 ` David E. Box
  1 sibling, 0 replies; 3+ messages in thread
From: David E. Box @ 2021-04-21 17:32 UTC (permalink / raw)
  To: Arnd Bergmann, Hans de Goede, Mark Gross, Gayatri Kammela
  Cc: Arnd Bergmann, Andy Shevchenko, Lee Jones, Maximilian Luz,
	Mika Westerberg, platform-driver-x86, linux-kernel

Thanks for the fix Arnd. Thought I could get away with not adding the
dependency since the function is stubbed but didn't realize struct
acpi_device wouldn't be defined. Should have build tested it.

David

On Wed, 2021-04-21 at 15:49 +0200, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> The driver now fails to build without ACPI:
> 
> drivers/platform/x86/intel_pmc_core.c: In function
> 'pmc_core_get_tgl_lpm_reqs':
> drivers/platform/x86/intel_pmc_core.c:617:41: error: invalid use of
> undefined type 'struct acpi_device'
>   617 |         out_obj = acpi_evaluate_dsm(adev->handle,
> &s0ix_dsm_guid, 0,
> 
> This could probably be made optional, but it won't be used without
> ACPI in practice, so just add a Kconfig dependency.
> 
> Fixes: 428131364f00 ("platform/x86: intel_pmc_core: Get LPM
> requirements for Tiger Lake")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  drivers/platform/x86/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/platform/x86/Kconfig
> b/drivers/platform/x86/Kconfig
> index 697fc446ac41..2714f7c3843e 100644
> --- a/drivers/platform/x86/Kconfig
> +++ b/drivers/platform/x86/Kconfig
> @@ -1194,6 +1194,7 @@ config INTEL_MRFLD_PWRBTN
>  config INTEL_PMC_CORE
>         tristate "Intel PMC Core driver"
>         depends on PCI
> +       depends on ACPI
>         help
>           The Intel Platform Controller Hub for Intel Core SoCs
> provides access
>           to Power Management Controller registers via various
> interfaces. This



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

end of thread, other threads:[~2021-04-21 17:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-21 13:49 [PATCH] platform/x86: intel_pmc_core: add ACPI dependency Arnd Bergmann
2021-04-21 14:14 ` Hans de Goede
2021-04-21 17:32 ` David E. Box

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.