RE: Re: omap_musb_board_data -- trouble specifying 500mA supply

2010-05-22 Thread David Brownell

 Actually in OMAP board files, power values have been
 provided
 With units of 1mA 

Everywhere (!!) in the Linux-USB stack, those units
should be 2mA (just like in config descriptors) ...

which gets divided to half in
 arch/arm/mach-omap2/usb-musb.c

... which is why there's a divide-by-two there.


 before sending it to musb
 driver.

... the divide-by-two should only be skipped when
talking to power supplies or regulators, which don't
have USB conventions to be concerned with.

Looks like some board files need bugfixing.

- Dave


--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: Re: omap_musb_board_data -- trouble specifying 500mA supply

2010-05-21 Thread David Brownell

   We are designing a custom OMAP board that
 will have a 500mA supply on
   the OTG port.  It looks like the power
 is set with:
  
   struct omap_musb_board_data {
         u8 
     interface_type;
         u8 
     mode;
         u8 
     power;
   };
  
   However, with a u8, the max value is
 255.  Should power be changed to a
   u16?

No.  The units are 2mA not 1mA, matching the USB specs.

So to specify 500mA (the max), say 250 ...



--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: Re: omap_musb_board_data -- trouble specifying 500mA supply

2010-05-21 Thread Gupta, Ajay Kumar
Hi,

We are designing a custom OMAP board that
  will have a 500mA supply on
the OTG port.  It looks like the power
  is set with:
   
struct omap_musb_board_data {
          u8
      interface_type;
          u8
      mode;
          u8
      power;
};
   
However, with a u8, the max value is
  255.  Should power be changed to a
u16?
 
 No.  The units are 2mA not 1mA, matching the USB specs.
 
 So to specify 500mA (the max), say 250 ...

David,
Actually in OMAP board files, power values have been provided
With units of 1mA which gets divided to half in
arch/arm/mach-omap2/usb-musb.c before sending it to musb driver.

-Ajay  
 
 

--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: Re: omap_musb_board_data -- trouble specifying 500mA supply

2010-05-03 Thread Gupta, Ajay Kumar
Hi,
  -Original Message-
  From: linux-omap-ow...@vger.kernel.org [mailto:linux-omap-
  ow...@vger.kernel.org] On Behalf Of Cliff Brake
  Sent: Wednesday, April 28, 2010 7:40 PM
  To: Linux OMAP Users
  Subject: omap_musb_board_data -- trouble specifying 500mA supply
 
  Hello,
 
  We are designing a custom OMAP board that will have a 500mA supply on
  the OTG port.  It looks like the power is set with:
 
  struct omap_musb_board_data {
u8  interface_type;
u8  mode;
u8  power;
  };
 
  However, with a u8, the max value is 255.  Should power be changed to a
  u16?
 
  There is already a fix submitted and is available at Greg's queue,
  http://www.kernel.org/pub/linux/kernel/people/gregkh/gregkh-
 2.6/patches/usb.current/musb-fix-power-field-to-hold-all-possible-
 values.patch
 
 I'm also having trouble figuring out the correct way to convince the
 OTG system not to use the internal phy VBUS power supply.  Are there
 any examples of a board config that does this?  Perhaps the AM35xx,
 etc?
You can refer OMAP3EVM (REV-G) or AM35x.

Ajay
 
 Thanks,
 Cliff
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: omap_musb_board_data -- trouble specifying 500mA supply

2010-04-30 Thread Cliff Brake
On Wed, Apr 28, 2010 at 10:53 AM, Gupta, Ajay Kumar ajay.gu...@ti.com wrote:
 Hi,
 -Original Message-
 From: linux-omap-ow...@vger.kernel.org [mailto:linux-omap-
 ow...@vger.kernel.org] On Behalf Of Cliff Brake
 Sent: Wednesday, April 28, 2010 7:40 PM
 To: Linux OMAP Users
 Subject: omap_musb_board_data -- trouble specifying 500mA supply

 Hello,

 We are designing a custom OMAP board that will have a 500mA supply on
 the OTG port.  It looks like the power is set with:

 struct omap_musb_board_data {
       u8      interface_type;
       u8      mode;
       u8      power;
 };

 However, with a u8, the max value is 255.  Should power be changed to a
 u16?

 There is already a fix submitted and is available at Greg's queue,
 http://www.kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/patches/usb.current/musb-fix-power-field-to-hold-all-possible-values.patch

I'm also having trouble figuring out the correct way to convince the
OTG system not to use the internal phy VBUS power supply.  Are there
any examples of a board config that does this?  Perhaps the AM35xx,
etc?

Thanks,
Cliff
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


omap_musb_board_data -- trouble specifying 500mA supply

2010-04-28 Thread Cliff Brake
Hello,

We are designing a custom OMAP board that will have a 500mA supply on
the OTG port.  It looks like the power is set with:

struct omap_musb_board_data {
u8  interface_type;
u8  mode;
u8  power;
};

However, with a u8, the max value is 255.  Should power be changed to a u16?

Thanks,
Cliff
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: omap_musb_board_data -- trouble specifying 500mA supply

2010-04-28 Thread Gupta, Ajay Kumar
Hi,
 -Original Message-
 From: linux-omap-ow...@vger.kernel.org [mailto:linux-omap-
 ow...@vger.kernel.org] On Behalf Of Cliff Brake
 Sent: Wednesday, April 28, 2010 7:40 PM
 To: Linux OMAP Users
 Subject: omap_musb_board_data -- trouble specifying 500mA supply
 
 Hello,
 
 We are designing a custom OMAP board that will have a 500mA supply on
 the OTG port.  It looks like the power is set with:
 
 struct omap_musb_board_data {
   u8  interface_type;
   u8  mode;
   u8  power;
 };
 
 However, with a u8, the max value is 255.  Should power be changed to a
 u16?

There is already a fix submitted and is available in Greg's queue below,
 
 Thanks,
 Cliff
 --
 To unsubscribe from this list: send the line unsubscribe linux-omap in
 the body of a message to majord...@vger.kernel.org
 More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: omap_musb_board_data -- trouble specifying 500mA supply

2010-04-28 Thread Gupta, Ajay Kumar
Hi,
 -Original Message-
 From: linux-omap-ow...@vger.kernel.org [mailto:linux-omap-
 ow...@vger.kernel.org] On Behalf Of Cliff Brake
 Sent: Wednesday, April 28, 2010 7:40 PM
 To: Linux OMAP Users
 Subject: omap_musb_board_data -- trouble specifying 500mA supply
 
 Hello,
 
 We are designing a custom OMAP board that will have a 500mA supply on
 the OTG port.  It looks like the power is set with:
 
 struct omap_musb_board_data {
   u8  interface_type;
   u8  mode;
   u8  power;
 };
 
 However, with a u8, the max value is 255.  Should power be changed to a
 u16?

There is already a fix submitted and is available at Greg's queue,
http://www.kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/patches/usb.current/musb-fix-power-field-to-hold-all-possible-values.patch

Ajay
 
 Thanks,
 Cliff
 --
 To unsubscribe from this list: send the line unsubscribe linux-omap in
 the body of a message to majord...@vger.kernel.org
 More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html