From mboxrd@z Thu Jan 1 00:00:00 1970 From: Adrian Bunk Subject: Re: [linux-usb-devel] [PATCH 2/2] usbnet: use MII hooks only if CONFIG_MII is enabled Date: Wed, 1 Nov 2006 02:23:46 +0100 Message-ID: <20061101012346.GB27968@stusta.de> References: <200610310940.16619.david-b@pacbell.net> <20061031180712.GQ27968@stusta.de> <200610311136.54058.david-b@pacbell.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linux-usb-devel@lists.sourceforge.net, Randy Dunlap , akpm@osdl.org, zippel@linux-m68k.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, link@miggy.org, Christoph Hellwig , torvalds@osdl.org, greg@kroah.com, toralf.foerster@gmx.de Return-path: To: David Brownell Content-Disposition: inline In-Reply-To: <200610311136.54058.david-b@pacbell.net> Sender: linux-kernel-owner@vger.kernel.org List-Id: netdev.vger.kernel.org On Tue, Oct 31, 2006 at 11:36:52AM -0800, David Brownell wrote: > > > > ... > > > depends on MII if MII != n > > > > > > except that Kconfig doesn't comprehend conditionals like that. > > > > You can express this in Kconfig: > > depends MII || MII=n > > Except that: > > Warning! Found recursive dependency: USB_USBNET USB_NET_AX8817X MII USB_USBNET > > I think this is another case where Kconfig gets in the way and forces > introduction of a pseudovariable. I'll give that a try. > > > But my suggestion was: > > #if defined(CONFIG_MII) || (defined(CONFIG_MII_MODULE) && defined(MODULE)) > > > > Or simply select MII ... > > Nope; those both prevent completely legit configurations. > MII is not required, except for those two adapter options. What should work (with the USB_NET_MCS7830 part from Randy's patch removed) together with your patch and the #if defined(CONFIG_MII) || (defined(CONFIG_MII_MODULE) && defined(MODULE)) is: config USB_USBNET tristate "Multi-purpose USB Networking Framework" select MII if USB_NET_AX8817X!=n || USB_NET_MCS7830!=n ---help--- ... 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