From: Florian Fainelli <florian@openwrt.org>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: linux-kernel@vger.kernel.org, arnd@arndb.de,
gregkh@linuxfoundation.org, linux-usb@vger.kernel.org
Subject: Re: [RFC PATCH 1/5] USB: drop depends on USB and enclose everything into an if USB block
Date: Tue, 26 Mar 2013 20:56:16 +0100 [thread overview]
Message-ID: <5151FD60.8090703@openwrt.org> (raw)
In-Reply-To: <Pine.LNX.4.44L0.1303261456400.999-100000@iolanthe.rowland.org>
Le 26/03/2013 20:04, Alan Stern a écrit :
> On Tue, 26 Mar 2013, Florian Fainelli wrote:
>
>> This patch removes the depends on USB from all config symbols in
>> drivers/usb/host/Kconfig and replace that with an if USB / endif block
>> as suggested by Alan Stern.
>
> I'm afraid this patch is filled with errors.
Which is the reason why I stated this was a RFC, I did not meant to get
it good for everything from the first try.
>
> For one thing, it doesn't appreciate the difference between host-side
> USB and device-side USB. CONFIG_USB describes support for the
> host-side part of the stack, whereas CONFIG_USB_GADGET describes
> support for the device-side (or gadget-side) part. This means you must
> not make things like drivers/usb/gadget/Kconfig dependent on
> CONFIG_USB.
Ok.
>
> For another, the patch doesn't understand the difference between && and
> ||. As an example, putting chipidea/Kconfig inside "if USB" and then
> doing this:
>
>> --- a/drivers/usb/chipidea/Kconfig
>> +++ b/drivers/usb/chipidea/Kconfig
>> @@ -1,6 +1,6 @@
>> config USB_CHIPIDEA
>> tristate "ChipIdea Highspeed Dual Role Controller"
>> - depends on USB || USB_GADGET
>> + depends on USB_GADGET
>> help
>> Say Y here if your system has a dual role high speed USB
>> controller based on ChipIdea silicon IP. Currently, only the
>
> effectively changes the || to an &&. This is not what we want.
>
> You need to be a lot more careful about the distinction between hosts
> and gadgets. The situation becomes even more complicated when you
> realize that some of the code applies to Dual-Role Devices, which can
> be either hosts or gadgets (this includes OTG). In addition, there are
> a few things (such as gadget/dummy_hcd.c) which require _both_
> host-side and device-side support.
Ok, thanks for the hint, I will address these issues.
--
Florian
next prev parent reply other threads:[~2013-03-26 20:03 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-26 18:06 [RFC PATCH 0/5] USB: Kconfig cleanups Florian Fainelli
2013-03-26 18:06 ` [RFC PATCH 1/5] USB: drop depends on USB and enclose everything into an if USB block Florian Fainelli
2013-03-26 19:04 ` Alan Stern
2013-03-26 19:56 ` Florian Fainelli [this message]
2013-03-26 18:06 ` [RFC PATCH 2/5] USB: remove USB_EHCI_BIG_ENDIAN_{DESC,MMIO} depends on architecture symbol Florian Fainelli
2013-03-26 18:10 ` Arnd Bergmann
2013-03-26 19:08 ` Alan Stern
2013-03-29 21:31 ` Anatolij Gustschin
2013-03-26 18:06 ` [RFC PATCH 3/5] USB: enclose EHCI HCD drivers within an if USB_EHCI_HCD block Florian Fainelli
2013-03-26 18:06 ` [RFC PATCH 4/5] USB: enclose all depends on USB_OHCI_HCD within an if USB_OHCI_HCD block Florian Fainelli
2013-03-26 18:06 ` [RFC PATCH 5/5] USB: enclose USB_XHCI_HCD related symbols within a if USB_XHCI_HCD block Florian Fainelli
2013-04-02 17:05 ` [PATCH 0/5] USB: Kconfig cleanups Florian Fainelli
2013-04-02 17:05 ` [PATCH 1/5] USB: regroup all depends on USB within an if USB block Florian Fainelli
2013-04-02 17:05 ` [PATCH 2/5] USB: remove USB_EHCI_BIG_ENDIAN_{DESC,MMIO} depends on architecture symbol Florian Fainelli
2013-04-02 17:05 ` [PATCH 3/5] USB: enclose EHCI HCD drivers within an if USB_EHCI_HCD block Florian Fainelli
2013-04-02 17:05 ` [PATCH 4/5] USB: enclose all depends on USB_OHCI_HCD within an if USB_OHCI_HCD block Florian Fainelli
2013-04-02 17:05 ` [PATCH 5/5] USB: enclose USB_XHCI_HCD related symbols within a if USB_XHCI_HCD block Florian Fainelli
2013-04-02 17:10 ` [PATCH 0/5] USB: Kconfig cleanups Florian Fainelli
2013-04-02 17:10 ` [PATCH 0/5 v2] " Florian Fainelli
2013-04-02 17:10 ` [PATCH 1/5 v2] USB: regroup all depends on USB within an if USB block Florian Fainelli
2013-04-02 18:06 ` Alan Stern
2013-04-03 12:11 ` Florian Fainelli
2013-04-03 12:15 ` Felipe Balbi
2013-04-03 12:18 ` Florian Fainelli
2013-04-03 12:21 ` Felipe Balbi
2013-04-03 18:10 ` Alan Stern
2013-04-02 18:19 ` balbi
2013-04-03 11:54 ` Florian Fainelli
2013-04-02 17:10 ` [PATCH 2/5 v2] USB: remove USB_EHCI_BIG_ENDIAN_{DESC,MMIO} depends on architecture symbol Florian Fainelli
2013-04-02 18:21 ` Alan Stern
2013-04-02 17:10 ` [PATCH 3/5 v2] USB: enclose EHCI HCD drivers within an if USB_EHCI_HCD block Florian Fainelli
2013-04-02 18:33 ` Alan Stern
2013-04-02 17:10 ` [PATCH 4/5 v2] USB: enclose all depends on USB_OHCI_HCD within an if USB_OHCI_HCD block Florian Fainelli
2013-04-02 18:42 ` Alan Stern
2013-04-02 17:10 ` [PATCH 5/5 v2] USB: enclose USB_XHCI_HCD related symbols within a if USB_XHCI_HCD block Florian Fainelli
2013-04-02 18:43 ` Alan Stern
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5151FD60.8090703@openwrt.org \
--to=florian@openwrt.org \
--cc=arnd@arndb.de \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=stern@rowland.harvard.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.