dscc4.c tests for "#ifndef MODULE" even though it must be modular

From: Robert P. J. Day <hidden>
Date: 2007-09-12 13:27:25

  from drivers/net/wan/dscc4.c:

=====
#ifndef MODULE
static int __init dscc4_setup(char *str)
{
        int *args[] = { &debug, &quartz, NULL }, **p = args;

        while (*p && (get_option(&str, *p) == 2))
                p++;
        return 1;
}

__setup("dscc4.setup=", dscc4_setup);
#endif
=====

  but from drivers/net/wan/Kconfig:

...
config DSCC4
        tristate "Etinc PCISYNC serial board support"
        depends on HDLC && PCI && m
...

  if i read this correctly, doesn't the depends on of "&& m" mean that
that Kconfig selection can be *at most* modular, so that that
preprocessor conditional can never be satisfied?  a quick test under
"make menuconfig" seems to confirm that.

  besides, the kernel parm being defined in that call to __setup()
really violates the spirit of defining kernel parms. :-)

rday
-- 
========================================================================
Robert P. J. Day
Linux Consulting, Training and Annoying Kernel Pedantry
Waterloo, Ontario, CANADA

http://crashcourse.ca
========================================================================
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help