From: Sergei Shtylyov <sshtylyov-Igf4POYTYCDQT0dZR+AlfA@public.gmane.org>
To: Hema HK <hemahk-l0cyMroinI0@public.gmane.org>
Cc: linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Felipe Balbi <balbi-l0cyMroinI0@public.gmane.org>,
Tony Lindgren <tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>,
Kevin Hilman
<khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org>,
"Cousson, Benoit" <b-cousson-l0cyMroinI0@public.gmane.org>,
Paul Walmsley <paul-DWxLp4Yu+b8AvxtiuMwx3w@public.gmane.org>
Subject: Re: [PATCH 5/6] OMAP2+: musb: hwmod adaptation for musb registration
Date: Wed, 16 Feb 2011 15:49:54 +0300 [thread overview]
Message-ID: <4D5BC7F2.9000804@ru.mvista.com> (raw)
In-Reply-To: <1297859298-27861-6-git-send-email-hemahk-l0cyMroinI0@public.gmane.org>
Hello.
On 16-02-2011 15:28, Hema HK wrote:
> Using omap_device_build API instead of platform_device_register for
> OMAP2430,OMAP3xxx, OMAP4430 and AM35x musb device registration.
> The device specific resources defined in centralized
> database will be used.
> Signed-off-by: Hema HK<hemahk-l0cyMroinI0@public.gmane.org>
> Cc: Felipe Balbi<balbi-l0cyMroinI0@public.gmane.org>
> Cc: Tony Lindgren<tony-4v6yS6AI5VpBDgjK7y7TUQ@public.gmane.org>
> Cc: Kevin Hilman<khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org>
> Cc: Cousson, Benoit<b-cousson-l0cyMroinI0@public.gmane.org>
> Cc: Paul Walmsley<paul-DWxLp4Yu+b8AvxtiuMwx3w@public.gmane.org>
[...]
> Index: linux-2.6/arch/arm/mach-omap2/usb-musb.c
> ===================================================================
> --- linux-2.6.orig/arch/arm/mach-omap2/usb-musb.c
> +++ linux-2.6/arch/arm/mach-omap2/usb-musb.c
[...]
> @@ -115,8 +88,35 @@ void __init usb_musb_init(struct omap_mu
> musb_plat.mode = board_data->mode;
> musb_plat.extvbus = board_data->extvbus;
>
> - if (platform_device_register(&musb_device)< 0)
> - printk(KERN_ERR "Unable to register HS-USB (MUSB) device\n");
> + if (cpu_is_omap3517() || cpu_is_omap3505()) {
> + oh_name = "am35x_otg_hs";
> + name = "musb-am35x";
> + } else {
> + oh_name = "usb_otg_hs";
> + name = "musb-omap2430";
> + }
The following code is over-indented...
> + oh = omap_hwmod_lookup(oh_name);
> + if (!oh) {
> + pr_err("Could not look up %s\n", oh_name);
> + return;
> + }
> +
> + od = omap_device_build(name, bus_id, oh, &musb_plat,
> + sizeof(*pdata), omap_musb_latency,
> + ARRAY_SIZE(omap_musb_latency), false);
> + if (IS_ERR(od)) {
> + pr_err("Could not build omap_device for %s %s\n",
> + name, oh_name);
> + return;
> +
Empty line not needed here...
> + }
> + pdev =&od->pdev;
> + dev =&pdev->dev;
> + get_device(dev);
> + dev->dma_mask = &musb_dmamask;
> + dev->coherent_dma_mask = musb_dmamask;
> + put_device(dev);
> +
And here...
> }
>
> #else
WBR, Sergei
--
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
next prev parent reply other threads:[~2011-02-16 12:49 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-16 12:28 [PATCH 0/6 v7]usb: musb: hwmod and runtime pm support for musb Hema HK
2011-02-16 12:28 ` [PATCH 1/6 v7] OMAP2430: hwmod data: Add USBOTG Hema HK
2011-02-16 12:28 ` [PATCH 2/6 v7] OMAP3xxx: " Hema HK
2011-02-16 12:28 ` [PATCH 3/6 v7] AM35xx: " Hema HK
2011-02-16 12:28 ` [PATCH 5/6] OMAP2+: musb: hwmod adaptation for musb registration Hema HK
[not found] ` <1297859298-27861-6-git-send-email-hemahk-l0cyMroinI0@public.gmane.org>
2011-02-16 12:49 ` Sergei Shtylyov [this message]
[not found] ` <1297859298-27861-1-git-send-email-hemahk-l0cyMroinI0@public.gmane.org>
2011-02-16 12:28 ` [PATCH 4/6 v7] OMAP4430: hwmod data: Adding USBOTG Hema HK
2011-02-16 12:28 ` [PATCH 6/6 v7] usb: musb: Using runtime pm APIs for musb Hema HK
[not found] ` <1297859298-27861-7-git-send-email-hemahk-l0cyMroinI0@public.gmane.org>
2011-02-16 12:56 ` Sergei Shtylyov
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=4D5BC7F2.9000804@ru.mvista.com \
--to=sshtylyov-igf4poytycdqt0dzr+alfa@public.gmane.org \
--cc=b-cousson-l0cyMroinI0@public.gmane.org \
--cc=balbi-l0cyMroinI0@public.gmane.org \
--cc=hemahk-l0cyMroinI0@public.gmane.org \
--cc=khilman-1D3HCaltpLuhEniVeURVKkEOCMrvLtNR@public.gmane.org \
--cc=linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=paul-DWxLp4Yu+b8AvxtiuMwx3w@public.gmane.org \
--cc=tony-4v6yS6AI5VpBDgjK7y7TUQ@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