Re: REGRESSION: Re: [GIT] kconfig rc fixes

From: Arnaud Lacombe
Date: Thu Nov 04 2010 - 00:04:03 EST


Hi,

On Wed, Nov 3, 2010 at 11:19 PM, Mauro Carvalho Chehab
<mchehab@xxxxxxxxxx> wrote:
>>> config VIDEO_HELPER_CHIPS_AUTO
>>>        bool "Autoselect pertinent encoders/decoders and other helper chips"
>>>
>>> config VIDEO_IVTV
>>>        select VIDEO_WM8739 if VIDEO_HELPER_CHIPS_AUTO
>>>
>>> menu "Encoders/decoders and other helper chips"
>>>        depends on !VIDEO_HELPER_CHIPS_AUTO
>>>
>>> config VIDEO_WM8739
>>>        tristate "Wolfson Microelectronics WM8739 stereo audio ADC"
>>>
>
> I don't see anything wrong on such logic. It is valid in C, and it is also valid
> (and works properly) at Kconfig language.
no, it is not a valid Kconfig language, or at least, you create an
ambiguity in the dependency tree.

> So, the warning is a false positive.
>
no it is not. By saying:

menu "Encoders/decoders and other helper chips"
depends on !VIDEO_HELPER_CHIPS_AUTO

you create on all the menu's children an implicit dependency,
!VIDEO_HELPER_CHIPS_AUTO. This is something that has ever been there;
from `Documentation/kbuild/kconfig-language.txt':

"
[...]
menu "Network device support"
depends on NET

config NETDEVICES
...
endmenu

All entries within the "menu" ... "endmenu" block become a submenu of
"Network device support". All subentries inherit the dependencies from
the menu entry, e.g. this means the dependency "NET" is added to the
dependency list of the config option NETDEVICES.
"

Thus the warning as you also have:

config VIDEO_IVTV
select VIDEO_WM8739 if VIDEO_HELPER_CHIPS_AUTO

ie. VIDEO_IVTV selects VIDEO_WM8739 if VIDEO_HELPER_CHIPS_AUTO, but
VIDEO_WM8739 has inherited the !VIDEO_HELPER_CHIPS_AUTO dependency.

Now, if you want my true feeling, this warning should be fatal.

- Arnaud
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/