[lkml]   [2010]   [Jan]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [RFC/PATCH 1/5] usb: otg: add notifier support
    On Tuesday 26 January 2010, Felipe Balbi wrote:
    > just remember of another problem which I couldn't solve yet:
    > if you boot the board with the usb cable already attached, then we miss
    > the first notification because when the notifier is called, usb
    > controller driver isn't probed yet.

    That's part of why the OTG transceiver driver has methods
    used by host and peripheral drivers to register themselves.

    Standard init sequence there is to do nothing until both
    drivers are fully initialized ... last step being to
    register the drivers with the transceiver. That way the
    transceiver can know when its peer drivers are ready.

    Example: VBUS present from a host. If the board runs
    in OTG mode, as soon as both drivers are registered then
    the B-Default state machine would start running ... and
    that involves (see the OTG state machine!) issuing a VBBUS

    Same thing can be done with the power events. As soon
    as an event listener is registered, it could be fed any
    events it missed. (Just one approach; one must sort
    out any other interdependencies too. In this case, it
    can make sense to consume 100mA current right away, and
    then adjust the draw later if needed.)

    - Dave

     \ /
      Last update: 2010-01-26 16:35    [W:0.020 / U:13.248 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site