public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
From: Olof Johansson <olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org>
To: Maulik <x0082077-l0cyMroinI0@public.gmane.org>
Cc: 'Tony Lindgren' <tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>,
	linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	'Felipe Balbi'
	<felipe.balbi-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org>,
	'Greg Kroah-Hartman' <gregkh-l3A5Bk7waGM@public.gmane.org>,
	'David Brownell'
	<david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org>
Subject: Re: [PATCH 2/4] USB: MUSB: Enable MUSB for OMAP4 in Kconfig
Date: Mon, 1 Mar 2010 09:43:29 -0600	[thread overview]
Message-ID: <20100301154329.GA4154@lixom.net> (raw)
In-Reply-To: <001b01cab901$dadec9a0$808918ac-wD+IZp/g4/2mHdYHvhjUOg@public.gmane.org>

On Mon, Mar 01, 2010 at 11:11:29AM +0530, Maulik wrote:
> > Olof,
> > 
> > We have such an option "USB_MUSB_SOC" that takes care of all platforms
> where
> > MUSB is present. But the Inventra DMA case is typical. Not all
> architectures
> > that have MUSB use Inventra DMA for e.g Davinci uses CPPI DMA.
> 
> >>Yeah, sorry. I didn't mean the INVENTRA_DMA config option as much as the
> >>top
> >>MUSB one. So you should be able to switch to that instead of adding a
> >>check for
> >>OMAP4 there then?
> 
> Olof,
> So you suggest adding something like below for OMAP4 and all others as well
> right?
> 
> comment "OMAP 44xx high speed USB support"
>         depends on USB_MUSB_HDRC && USB_MUSB_SOC


Hmm. I must be missing something, but it looks odd to have both the
USB_MUSB_HDRC and USB_MUSB_SOC high-level config options, especially since
the depends are duplicated across them.

In general, options like these tend to scale badly:

config USB_MUSB_SOC
        boolean
        depends on USB_MUSB_HDRC
        default y if ARCH_DAVINCI
        default y if ARCH_OMAP2430
        default y if ARCH_OMAP34XX
        default y if (BF54x && !BF544)
        default y if (BF52x && !BF522 && !BF523)

I.e. every single platform needs to add a new line. It's better
to have a config option that is selected from the platform code
(arch/arm/mach-omap2/Kconfig for the specific SOC in this case), that
for example does a :

config ARCH_OMAP34XX
        bool "OMAP34xx Based System"
        depends on ARCH_OMAP3
        select USB_ARCH_HAS_EHCI
	select USB_ARCH_HAS_MUSB

and then just do the USB_MUSB_HDRC or USB_MUSB_SOC config option based on:

config USB_MUSB_SOC
	boolena
	depends on USB_ARCH_HAS_MUSB
	default y

That way a new platform doesn't need to change the common files.

I also don't see the direct need to provide a specific comment saying
"44xx high speed USB support" when you configure for 44xx. With the
work Tony is doing you can build one kernel that boots across OMAP2/3/4,
which comment should then be displayed? It's better to just do a generic
comment such as "OMAP on-chip OTG USB support"

The DMA config is also a bit confusing. I scratched my head over that one
a few times, the fact that one is described with OMAP in the name, and
the other one (INVENTRA) is the one actually used on newer OMAP platforms.


-Olof
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2010-03-01 15:43 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-25  6:35 [PATCH 2/4] USB: MUSB: Enable MUSB for OMAP4 in Kconfig Maulik Mankad
     [not found] ` <1267079758-14480-1-git-send-email-x0082077-l0cyMroinI0@public.gmane.org>
2010-02-25 18:48   ` Tony Lindgren
2010-02-26  0:42     ` Olof Johansson
2010-02-26  8:40       ` Maulik
2010-02-26 18:54         ` Olof Johansson
     [not found]           ` <20100226185414.GA10835-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org>
2010-03-01  5:41             ` Maulik
     [not found]               ` <001b01cab901$dadec9a0$808918ac-wD+IZp/g4/2mHdYHvhjUOg@public.gmane.org>
2010-03-01 15:43                 ` Olof Johansson [this message]
     [not found]                   ` <20100301154329.GA4154-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org>
2010-03-10 10:17                     ` Maulik
     [not found]                       ` <00f701cac03a$da51cab0$808918ac-wD+IZp/g4/2mHdYHvhjUOg@public.gmane.org>
2010-03-10 18:27                         ` Olof Johansson

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=20100301154329.GA4154@lixom.net \
    --to=olof-nzht3qvonbneowh0uzbu5w@public.gmane.org \
    --cc=david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org \
    --cc=felipe.balbi-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org \
    --cc=gregkh-l3A5Bk7waGM@public.gmane.org \
    --cc=linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org \
    --cc=x0082077-l0cyMroinI0@public.gmane.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox