Re: build #337 failed for 2.6.24-rc1-gb1d08ac In function`usbnet_set_settings':

From: Adrian Bunk
Date: Fri Nov 02 2007 - 16:06:22 EST


On Fri, Nov 02, 2007 at 11:45:15AM -0700, David Brownell wrote:
>...
> --- a.orig/drivers/net/usb/usbnet.c 2007-10-13 15:16:10.000000000 -0700
> +++ a/drivers/net/usb/usbnet.c 2007-11-02 11:39:59.000000000 -0700
> @@ -682,10 +682,17 @@ done_nopm:
> /* ethtool methods; minidrivers may need to add some more, but
> * they'll probably want to use this base set.
> */
> +#undef HAVE_MII
>
> -#if defined(CONFIG_MII) || defined(CONFIG_MII_MODULE)
> +#if defined(CONFIG_MII)
> #define HAVE_MII
>
> +#elif defined(CONFIG_MII_MODULE) && defined(MODULE)
> +#define HAVE_MII
> +#endif
> +
> +#ifdef HAVE_MII
> +
> int usbnet_get_settings (struct net_device *net, struct ethtool_cmd *cmd)
> {
> struct usbnet *dev = netdev_priv(net);
>

Despite all what you do in Kconfig and what you wrongly blame on
"select" the bug is in usbnet.c and this fix to usbnet.c _alone_
would be enough to fix the bug.

But since you said you care about not including bloat you should better
take my second patch that results in smaller code in some configurations.

cu
Adrian

--

"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed

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