* #ifdef CONFIG_ checks not working
@ 2010-10-26 14:28 Elvis Dowson
2010-10-26 14:35 ` Elvis Dowson
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Elvis Dowson @ 2010-10-26 14:28 UTC (permalink / raw)
To: Linux Kernel Mailing List, Luciano Coelho
Hi,
I just noticed that with the 2.6.36-rc8 kernel, the #ifdef checks aren't working.
So for example, if I add the following code fragment in my omap3_beagle_init function, CONFIG_WL1271 doesn't get detected, even though in my .config file, CONFIG_WL1271=m.
This way, the mux settings might also fail, right, which might be the source of a few of the problems that I'm facing.
Would you happen to know why this is not working. This type of checks used to work with the 2.6.32 kernel versions.
#ifdef CONFIG_WL1271
printk(KERN_INFO "%s: CONFIG_WL1271 detected\n", __func__);
#else
printk(KERN_INFO "%s: CONFIG_WL1271 not detected\n", __func__);
#endif
Boot message:
[ 0.000000] omap3_beagle_init: CONFIG_WL1271 not detected
Best regards,
Elvis Dowson
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: #ifdef CONFIG_ checks not working
2010-10-26 14:28 #ifdef CONFIG_ checks not working Elvis Dowson
@ 2010-10-26 14:35 ` Elvis Dowson
2010-10-26 14:48 ` Alan Cox
2010-10-26 15:26 ` David Miller
2 siblings, 0 replies; 4+ messages in thread
From: Elvis Dowson @ 2010-10-26 14:35 UTC (permalink / raw)
To: Linux Kernel Mailing List; +Cc: Luciano Coelho
On Oct 26, 2010, at 6:28 PM, Elvis Dowson wrote:
> I just noticed that with the 2.6.36-rc8 kernel, the #ifdef checks aren't working.
>
> So for example, if I add the following code fragment in my omap3_beagle_init function, CONFIG_WL1271 doesn't get detected, even though in my .config file, CONFIG_WL1271=m.
Ok, I guess its because should have been CONFIG_WL1271=y.
Best regards,
Elvis
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: #ifdef CONFIG_ checks not working
2010-10-26 14:28 #ifdef CONFIG_ checks not working Elvis Dowson
2010-10-26 14:35 ` Elvis Dowson
@ 2010-10-26 14:48 ` Alan Cox
2010-10-26 15:26 ` David Miller
2 siblings, 0 replies; 4+ messages in thread
From: Alan Cox @ 2010-10-26 14:48 UTC (permalink / raw)
To: Elvis Dowson; +Cc: Linux Kernel Mailing List, Luciano Coelho
On Tue, 26 Oct 2010 18:28:22 +0400
Elvis Dowson <elvis.dowson@mac.com> wrote:
> Hi,
> I just noticed that with the 2.6.36-rc8 kernel, the #ifdef checks aren't working.
They seem to be working fine
> So for example, if I add the following code fragment in my omap3_beagle_init function, CONFIG_WL1271 doesn't get detected, even though in my .config file, CONFIG_WL1271=m.
You are checking for Y/N not for modular (check how other drivers check
for both)
> Would you happen to know why this is not working. This type of checks used to work with the 2.6.32 kernel versions.
>
> #ifdef CONFIG_WL1271
> printk(KERN_INFO "%s: CONFIG_WL1271 detected\n", __func__);
> #else
> printk(KERN_INFO "%s: CONFIG_WL1271 not detected\n", __func__);
> #endif
The code looks wrong anyway - if you didn't compile it in then presumably
you *did* detect it but didn't have a driver ?
Alan
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: #ifdef CONFIG_ checks not working
2010-10-26 14:28 #ifdef CONFIG_ checks not working Elvis Dowson
2010-10-26 14:35 ` Elvis Dowson
2010-10-26 14:48 ` Alan Cox
@ 2010-10-26 15:26 ` David Miller
2 siblings, 0 replies; 4+ messages in thread
From: David Miller @ 2010-10-26 15:26 UTC (permalink / raw)
To: elvis.dowson; +Cc: linux-kernel, luciano.coelho
From: Elvis Dowson <elvis.dowson@mac.com>
Date: Tue, 26 Oct 2010 18:28:22 +0400
> #ifdef CONFIG_WL1271
> printk(KERN_INFO "%s: CONFIG_WL1271 detected\n", __func__);
> #else
> printk(KERN_INFO "%s: CONFIG_WL1271 not detected\n", __func__);
> #endif
If you set WL1271=m then CONFIG_WL1271_MODULE will be set, not
CONFIG_WL1271.
The latter will only be set if you enable the option with "y".
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-10-26 15:26 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-10-26 14:28 #ifdef CONFIG_ checks not working Elvis Dowson
2010-10-26 14:35 ` Elvis Dowson
2010-10-26 14:48 ` Alan Cox
2010-10-26 15:26 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).