• David Brownell's avatar
    [PATCH] USB: ohci init refactor · fa4b40f4
    David Brownell authored
    Please merge, some recent changes made problems
    by making init take too long.  This also adds a bit of
    support for detecting the funky resume states that
    happen with suspend-to-disk (like swsusp, pmdisk).
    
    
    Refactor controller initialization ... this is most of the patch by volume.
    
     - A time-critical section now runs with IRQs blocked, rather than being split
       over two separate routines.  (I've recently seen init failures because of
       preemption in the middle of that 2msec timeout, presumably by khubd.)
    
     - Bus glue for PCI, LH7A404, OMAP, and SA-1100 now shares more init logic;
       that'll help shrink support for upcoming non-PCI patches too.
    
     - Move the root hub register macros to the header (for debug build issue)
    
     - More tweaks to the frame clock initialization, including slightly more
       helpful diagnostics on "init err".
    
    Better SWSUSP support.
    
     - Detects and handles some funky "resume after suspend-to-disk" cases.  These
       need to go through full driver re-init.
    
     - Restore root hub to CONFIGURED state on resume.
    Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
    Signed-off-by: default avatarGreg Kroah-Hartman <greg@kroah.com>
    fa4b40f4
ohci-lh7a404.c 8.23 KB