All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] musb: set MUSB speed based on CONFIG
Date: Fri, 10 Jul 2015 16:36:44 +0200	[thread overview]
Message-ID: <559FD87C.7060905@redhat.com> (raw)
In-Reply-To: <559FD6FC.4010606@redhat.com>

Hi,

On 10-07-15 16:30, Hans de Goede wrote:
> Hi,
>
> On 10-07-15 15:16, Samuel Egli wrote:
>> From: Bin Liu <b-liu@ti.com>
>>
>> Do not config MUSB to highspeed mode if CONFIG_USB_GADGET_DUALSPEED
>> is not set, in which case Ether gadget only operates in fullspeed.
>>
>> Note:
>> This patch is necessary for devices like some siemens boards
>> that allow only FULL SPEED USB 1.1, e.g. DFU download.
>>
>> Signed-off-by: Bin Liu <b-liu@ti.com>
>> Reviewed-by: Tom Rini <trini@konsulko.com>
>> Tested-by: Samuel Egli <samuel.egli@siemens.com>
>> CC: Marek Vasut <marex@denx.de>
>> CC: Heiko Schocher <hs@denx.de>
>> CC: Daniel Mack <zonque@gmail.com>
>> CC: Roger Meier <r.meier@siemens.com>
>
> Nack this breaks highspeed mode on boards which use the musb
> in host mode, and thus do not set CONFIG_USB_GADGET_DUALSPEED.

p.s.

Given that you want to use this as a hack to work around the broken
pcb design of your board I suggest adding a new option for this
titled: CONFIG_USB_MUSB_NO_HIGHSPEED and then do:

+#ifndef CONFIG_USB_MUSB_NO_HIGHSPEED
                            | MUSB_POWER_HSENAB
+#endif

Using CONFIG_USB_GADGET_DUALSPEED for this seems wrong, since this
has nothing to do with enabling dualspeed mode for the gadget code
really.

Regards,

Hans


>
> Regards,
>
> Hans
>
>
>> ---
>>   drivers/usb/musb-new/musb_core.c |    2 ++
>>   1 file changed, 2 insertions(+)
>>
>> diff --git a/drivers/usb/musb-new/musb_core.c b/drivers/usb/musb-new/musb_core.c
>> index 242cc30..4edd6d7 100644
>> --- a/drivers/usb/musb-new/musb_core.c
>> +++ b/drivers/usb/musb-new/musb_core.c
>> @@ -942,7 +942,9 @@ void musb_start(struct musb *musb)
>>
>>       /* put into basic highspeed mode and start session */
>>       musb_writeb(regs, MUSB_POWER, MUSB_POWER_ISOUPDATE
>> +#ifdef CONFIG_USB_GADGET_DUALSPEED
>>                           | MUSB_POWER_HSENAB
>> +#endif
>>                           /* ENSUSPEND wedges tusb */
>>                           /* | MUSB_POWER_ENSUSPEND */
>>                           );
>> --
>> 1.7.10.4
>>
>> _______________________________________________
>> U-Boot mailing list
>> U-Boot at lists.denx.de
>> http://lists.denx.de/mailman/listinfo/u-boot
>>
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot

  reply	other threads:[~2015-07-10 14:36 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-10 13:16 [U-Boot] (no subject) Samuel Egli
2015-07-10 13:16 ` [U-Boot] [PATCH] musb: set MUSB speed based on CONFIG Samuel Egli
2015-07-10 14:30   ` Hans de Goede
2015-07-10 14:36     ` Hans de Goede [this message]
2015-07-10 14:50       ` Egli, Samuel
2015-07-10 15:12         ` Heiko Schocher
2015-07-10 15:31           ` Bin Liu
2015-07-11 13:01             ` Hans de Goede
2015-07-11 13:04             ` Hans de Goede
2015-07-13 14:16               ` Bin Liu
2015-07-19 11:01                 ` Hans de Goede
2015-07-21 17:04                   ` Bin Liu
2015-07-13  4:24             ` Heiko Schocher
  -- strict thread matches above, loose matches on Subject: below --
2013-03-21 15:27 [U-Boot] [PATCH] musb: am335x: disable bulk split-combine feature Bin Liu
2013-03-21 15:27 ` [U-Boot] [PATCH] musb: set MUSB speed based on CONFIG Bin Liu

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=559FD87C.7060905@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=u-boot@lists.denx.de \
    /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.