Re: [PATCH] Fix allnoconfig build with gcc4

From: Mika Kukkonen
Date: Sun Sep 11 2005 - 12:24:06 EST


On 9/11/05, Linus Torvalds <torvalds@xxxxxxxx> wrote:
>
>
(...)
> No, this would cause a compile error if CONFIG_NET and CONFIG_SYSCTL
> is enabled (because sysctl_net.c needs that declaration).

Ah yes. I got confused by googling which showed that there are some issues
with these declarations and gcc4 (see for example this thread:
http://gcc.gnu.org/ml/gcc/2005-02/msg00053.html).

> So the correct solution is apparently either one of
>
> - always declare an empty "struct ctl_table" regardless of whether SYSCTL
> is enabled or not.
>
> This might be a good idea, since it probably allows more code to be
> compiled without checking for CONFIG_SYSCTL.
>
> - put the ether_table[] declaration inside a #ifdef CONFIG_SYSCTL.

core_table in include/net/sock.h uses the latter option, so I'll send
you a patch
for that (with better email client).

--MiKu
-
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/