All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
To: linux-sh@vger.kernel.org
Subject: Re: [RFC][PATCH] ARM: shmobile: kzm9g: add r8a66597_udc support
Date: Thu, 05 Jul 2012 00:53:58 +0000	[thread overview]
Message-ID: <87fw97qb8c.wl%kuninori.morimoto.gx@renesas.com> (raw)
In-Reply-To: <4FF2921A.2080803@kmckk.co.jp>


Hi Kobayashi-san

> > I'm not sure the maintainer's opinion,
> > but if this patch is only for the "test", then #ifdef xx_TEST_xx is better name.
> >
> > OTOH, if you add "choice" in Kconfig to select UDC/HCD (not for test),
> > it is better for users.
> >
> Now in my mind, I will choose the latter. KZM-A9-GT is an *evaluation* 
> board, so someone want to evaluate R8A66597_UDC.

cool !

> >> +#ifdef USE_R8A66597_UDC
> >> +	/*
> >> +	 * Do not enable usb_host_device because r8a66597_udc and r8a66597_hcd
> >> +	 * can not use at the same time.
> >> +	 * Also, do not enable usbhs_device for simplify.
> >> +	 */
> >> +	&usb1_gadget_device,
> >> +#else
> >>   	&usb_host_device,
> >>   	&usbhs_device,
> >> +#endif
> >
> > Why is usbhs_device disabled for simplify ?
> > what's happen if it was enabled ?

> If the board has only one USB gadget, it is simple and almost
> board has only one USB gadget.
> But I don't understand yet how it works if the board has 2 or more
> USB devices. Is it possible one for mass storage and the other for
> ethernet over USB, or so?

I think so on latest kernel. (old kernel didn't support it)
I forgot detail of it, but 2usb-gadget worked correctly on other board (= mackerel ?)
 > insmod g_mass_strage file=xxx
 > insmod g_ether
If it doesn't work correctly, driver seems broken

# Current kzm9g board is using r8a66597_hcd/udc driver, since renesas_usbhs still doesn't support
# "external" chip yet.
# But in the future, it should be switched to use renesas_usbhs instead of r8a66597_xxx.

I don't care if you disabled renesas_usbhs or not.
(I don't know maintainer's opinion)
But when you use that style, please care compile warning.
I got this

/opt/usr/src/WORK/morimoto/gitlinux/linux-2.6/arch/arm/mach-shmobile/board-kzm9g.c:123:31: warning: 'usb_host_device' defined but not used [-Wunused-variable]
/opt/usr/src/WORK/morimoto/gitlinux/linux-2.6/arch/arm/mach-shmobile/board-kzm9g.c:298:31: warning: 'usbhs_device' defined but not used [-Wunused-variable]


Best regards
---
Kuninori Morimoto

  parent reply	other threads:[~2012-07-05  0:53 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-03  6:32 [RFC][PATCH] ARM: shmobile: kzm9g: add r8a66597_udc support Tetsuyuki Kobayashi
2012-07-04  2:54 ` Kuninori Morimoto
2012-07-04 11:40 ` Tetsuyuki Kobayashi
2012-07-05  0:53 ` Kuninori Morimoto [this message]
2012-07-05 12:03 ` Tetsuyuki Kobayashi
2012-08-25  2:01 ` Simon Horman
2012-08-30  6:22 ` Paul Mundt
2012-08-31  2:50 ` Tetsuyuki Kobayashi

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=87fw97qb8c.wl%kuninori.morimoto.gx@renesas.com \
    --to=kuninori.morimoto.gx@renesas.com \
    --cc=linux-sh@vger.kernel.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 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.