Re: [PATCH] watchdog: simatic: add PCI dependency

From: Hans de Goede
Date: Mon Aug 14 2023 - 04:52:36 EST


Hi,

On 8/14/23 10:48, Arnd Bergmann wrote:
> On Mon, Aug 14, 2023, at 10:27, xingtong.wu wrote:
>
>>>
>>> config SIEMENS_SIMATIC_IPC_WDT
>>> tristate "Siemens Simatic IPC Watchdog"
>>> - depends on SIEMENS_SIMATIC_IPC
>>> + depends on SIEMENS_SIMATIC_IPC && PCI
>>
>> The SIEMENS_SIMATIC_IPC_WDT does not depends on PCI directly,
>> it should depends on P2SB, then P2SB depends on PCI
>>
>>> default y
>>> select WATCHDOG_CORE
>>> select P2SB
>>
>> You can replace the "select" to "depends on" instead.
>
> That would also work, but it's generally best not to mix
> 'depends on' and 'select' for the same symbol. Changing
> all three 'select P2SB' to 'depends on P2SB', or removing
> the prompt to turn P2SB itself into a hidden symbol is
> probably a good follow-up patch, but I'd keep that separate
> from the regression fix.

Right P2SB would benefit from being changed into a hidden
symbol.

Andy, any comments on making P2SB a hidden symbol ?

Regards,

Hans


>
> Arnd
>