lkml.org 
[lkml]   [2015]   [Apr]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] usb: chipidea: Use extcon framework for VBUS and ID detection
From
Date

> On Apr 13, 2015, at 6:53 AM, Peter Chen <peter.chen@freescale.com> wrote:
>
> On Thu, Apr 09, 2015 at 11:33:38AM +0300, Ivan T. Ivanov wrote:
>> On recent Qualcomm platforms VBUS and ID lines are not routed to
>> USB PHY LINK controller. Use extcon framework to receive connect
>> and disconnect ID and VBUS notification.
>>
>>

<snip>

>>
>> +Optional properties:
>> +- extcon: phandles to external connector devices. First phandle
>> + should point to external connector, which provide "USB"
>> + cable events, the second should point to external connector
>> + device, which provide "USB-HOST" cable events. If one of
>> + the external connector devices is not required empty <0>
>> + phandle should be specified.
>
> You mean if id connector is not needed, we write dts like below:
> extcon = <&usb_vbus>, <0>;
>
> If it is, you may miss ',' between "required" and "empty <0>”.

Yes. Will fix it.

>> u32 hw_read_otgsc(struct ci_hdrc *ci, u32 mask)
>> {
>> - return hw_read(ci, OP_OTGSC, mask);
>> + u32 val = hw_read(ci, OP_OTGSC, mask);
>> +
>> + if ((mask & OTGSC_BSV) && ci->vbus.conn.edev) {
>
> You may use "||" since you can't get vbus and id value from
> cpu register (otgsc).

The idea is to not rely on the register content for these
bits if user have defined these DT bindings.

Will fix rest of the comments and resend.

Thank you,
Ivan

\
 
 \ /
  Last update: 2015-04-13 09:41    [W:0.052 / U:4.184 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site