X86 platform drivers
 help / color / mirror / Atom feed
* [PATCH] platform/x86: x86-android-tablets: select PMIC_OPREGION to resolve a link error of intel_soc_pmic_exec_mipi_pmic_seq_element
@ 2023-03-10 19:29 Tom Rix
  2023-03-11 11:12 ` Hans de Goede
  0 siblings, 1 reply; 3+ messages in thread
From: Tom Rix @ 2023-03-10 19:29 UTC (permalink / raw)
  To: hdegoede, markgross; +Cc: platform-driver-x86, linux-kernel, Tom Rix

A rand config causes this link error
drivers/platform/x86/x86-android-tablets/lenovo.o: In function `lenovo_yt3_init':
lenovo.c:(.init.text+0x6c): undefined reference to `intel_soc_pmic_exec_mipi_pmic_seq_element'

The rand config has
CONFIG_X86_ANDROID_TABLETS=y
CONFIG_PMIC_OPREGION=n

PMIC_OPREGION should be selected to build the
intel_soc_pmic_exec_mipi_pmic_seq_element symbol.

Signed-off-by: Tom Rix <trix@redhat.com>
---
 drivers/platform/x86/x86-android-tablets/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/platform/x86/x86-android-tablets/Kconfig b/drivers/platform/x86/x86-android-tablets/Kconfig
index 2b3daca5380b..65980229d783 100644
--- a/drivers/platform/x86/x86-android-tablets/Kconfig
+++ b/drivers/platform/x86/x86-android-tablets/Kconfig
@@ -6,6 +6,7 @@
 config X86_ANDROID_TABLETS
 	tristate "X86 Android tablet support"
 	depends on I2C && SPI && SERIAL_DEV_BUS && ACPI && EFI && GPIOLIB
+	select PMIC_OPREGION
 	help
 	  X86 tablets which ship with Android as (part of) the factory image
 	  typically have various problems with their DSDTs. The factory kernels
-- 
2.27.0


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

* Re: [PATCH] platform/x86: x86-android-tablets: select PMIC_OPREGION to resolve a link error of intel_soc_pmic_exec_mipi_pmic_seq_element
  2023-03-10 19:29 [PATCH] platform/x86: x86-android-tablets: select PMIC_OPREGION to resolve a link error of intel_soc_pmic_exec_mipi_pmic_seq_element Tom Rix
@ 2023-03-11 11:12 ` Hans de Goede
  2023-03-11 14:16   ` Tom Rix
  0 siblings, 1 reply; 3+ messages in thread
From: Hans de Goede @ 2023-03-11 11:12 UTC (permalink / raw)
  To: Tom Rix, markgross; +Cc: platform-driver-x86, linux-kernel

Hi,

On 3/10/23 20:29, Tom Rix wrote:
> A rand config causes this link error
> drivers/platform/x86/x86-android-tablets/lenovo.o: In function `lenovo_yt3_init':
> lenovo.c:(.init.text+0x6c): undefined reference to `intel_soc_pmic_exec_mipi_pmic_seq_element'
> 
> The rand config has
> CONFIG_X86_ANDROID_TABLETS=y
> CONFIG_PMIC_OPREGION=n
> 
> PMIC_OPREGION should be selected to build the
> intel_soc_pmic_exec_mipi_pmic_seq_element symbol.
> 
> Signed-off-by: Tom Rix <trix@redhat.com>

Thanks, but this is a dup with:

https://patchwork.kernel.org/project/platform-driver-x86/patch/20230309094035.18736-1-hdegoede@redhat.com/

I just did not get around to pushing that out to pdx86/for-next yet.
I have just pushed this to pdx86/for-next to avoid further duplicate fixes.

FWIW, since all other users of PMIC_OPREGION use depends on, not select this
should have been a depends on too. Unless Kconfig symbols are explicitly
intended to be selected (typically these are hidden Kconfig symbols (1))
then you should usually use depends on. Mixing depends on and select leads
to Kconfig circular dependencies errors.

Regards,

Hans


1) A hidden Kconfig symbol is one which is e.g. just 'bool' not
'bool "Description of feature here"' these typically are libraries /

helpers.




> ---
>  drivers/platform/x86/x86-android-tablets/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/platform/x86/x86-android-tablets/Kconfig b/drivers/platform/x86/x86-android-tablets/Kconfig
> index 2b3daca5380b..65980229d783 100644
> --- a/drivers/platform/x86/x86-android-tablets/Kconfig
> +++ b/drivers/platform/x86/x86-android-tablets/Kconfig
> @@ -6,6 +6,7 @@
>  config X86_ANDROID_TABLETS
>  	tristate "X86 Android tablet support"
>  	depends on I2C && SPI && SERIAL_DEV_BUS && ACPI && EFI && GPIOLIB
> +	select PMIC_OPREGION
>  	help
>  	  X86 tablets which ship with Android as (part of) the factory image
>  	  typically have various problems with their DSDTs. The factory kernels


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

* Re: [PATCH] platform/x86: x86-android-tablets: select PMIC_OPREGION to resolve a link error of intel_soc_pmic_exec_mipi_pmic_seq_element
  2023-03-11 11:12 ` Hans de Goede
@ 2023-03-11 14:16   ` Tom Rix
  0 siblings, 0 replies; 3+ messages in thread
From: Tom Rix @ 2023-03-11 14:16 UTC (permalink / raw)
  To: Hans de Goede, markgross; +Cc: platform-driver-x86, linux-kernel


On 3/11/23 3:12 AM, Hans de Goede wrote:
> Hi,
>
> On 3/10/23 20:29, Tom Rix wrote:
>> A rand config causes this link error
>> drivers/platform/x86/x86-android-tablets/lenovo.o: In function `lenovo_yt3_init':
>> lenovo.c:(.init.text+0x6c): undefined reference to `intel_soc_pmic_exec_mipi_pmic_seq_element'
>>
>> The rand config has
>> CONFIG_X86_ANDROID_TABLETS=y
>> CONFIG_PMIC_OPREGION=n
>>
>> PMIC_OPREGION should be selected to build the
>> intel_soc_pmic_exec_mipi_pmic_seq_element symbol.
>>
>> Signed-off-by: Tom Rix <trix@redhat.com>
> Thanks, but this is a dup with:
>
> https://patchwork.kernel.org/project/platform-driver-x86/patch/20230309094035.18736-1-hdegoede@redhat.com/
>
> I just did not get around to pushing that out to pdx86/for-next yet.
> I have just pushed this to pdx86/for-next to avoid further duplicate fixes.
>
> FWIW, since all other users of PMIC_OPREGION use depends on, not select this
> should have been a depends on too. Unless Kconfig symbols are explicitly
> intended to be selected (typically these are hidden Kconfig symbols (1))
> then you should usually use depends on. Mixing depends on and select leads
> to Kconfig circular dependencies errors.

Ok, thanks for the pointer.

Tom

>
> Regards,
>
> Hans
>
>
> 1) A hidden Kconfig symbol is one which is e.g. just 'bool' not
> 'bool "Description of feature here"' these typically are libraries /
>
> helpers.
>
>
>
>
>> ---
>>   drivers/platform/x86/x86-android-tablets/Kconfig | 1 +
>>   1 file changed, 1 insertion(+)
>>
>> diff --git a/drivers/platform/x86/x86-android-tablets/Kconfig b/drivers/platform/x86/x86-android-tablets/Kconfig
>> index 2b3daca5380b..65980229d783 100644
>> --- a/drivers/platform/x86/x86-android-tablets/Kconfig
>> +++ b/drivers/platform/x86/x86-android-tablets/Kconfig
>> @@ -6,6 +6,7 @@
>>   config X86_ANDROID_TABLETS
>>   	tristate "X86 Android tablet support"
>>   	depends on I2C && SPI && SERIAL_DEV_BUS && ACPI && EFI && GPIOLIB
>> +	select PMIC_OPREGION
>>   	help
>>   	  X86 tablets which ship with Android as (part of) the factory image
>>   	  typically have various problems with their DSDTs. The factory kernels


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

end of thread, other threads:[~2023-03-11 14:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-03-10 19:29 [PATCH] platform/x86: x86-android-tablets: select PMIC_OPREGION to resolve a link error of intel_soc_pmic_exec_mipi_pmic_seq_element Tom Rix
2023-03-11 11:12 ` Hans de Goede
2023-03-11 14:16   ` Tom Rix

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox