Re: RFC: kconfig select warnings bogus?

Stefan Richter
2007-05-22T17:03:18Z

Satyam Sharma wrote:
> On 5/20/07, Stefan Richter <stefanr@s5r6.in-berlin.de> wrote:
>> > On 5/20/07, Stefan Richter <stefanr@s5r6.in-berlin.de> wrote:
>> >> config A
>> >> bool-or-tristate "option A"
>> >> depends on !PLATFORM_X || HELPER_N_ON_PLATFORM_X
[...]
> Umm, if A requires helper code N (which is available only on platform X),
[And, I assumed, 'A' works without helper 'N' on all platforms except
'X'. This is a synthetic example which might not have a real-world
application.]
> then why/how do we want A to depend on platforms _other_ than X?

The expression means: 'A' can be enabled on all platforms. Except on
platform_X, there it can only be enabled if helper_N is built too.

[...]
>> depends on PM
>> depends on SWAP
>> depends on (X86 && !SMP) ||
>> (X86 && SUSPEND_SMP) ||
>> (PPC64_SWSUSP && !SMP) ||
>> (PPC64_SWSUSP && SUSPEND_SMP) ||
>> (FRV && !SMP) ||
>> (PPC32 && !SMP)
>
> Ok, so perhaps you actually meant X && N_ON_X above.

No. I meant "(X && N_ON_X) || Any_one_platform_other_than_X" above.

The 2nd example is a whitelist, while the 1st example is some kind of
blacklist. A real-world example of blacklist style:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=a73df4dfdb0e01a1cbf119416a00e520a5e22306
(Lived only 2 days in Linus' tree.)
--
Stefan Richter
-=====-=-=== -=-= =-==-