1. 27 Jun, 2005 17 commits
    • Alan Stern's avatar
      [PATCH] usbcore support for root-hub IRQ instead of polling · d5926ae7
      Alan Stern authored
      This is a revised version of an earlier patch to add support to usbcore
      for driving root hubs by interrupts rather than polling.
      
      There's a temporary flag added to struct usb_hcd, marking devices whose
      drivers are aware of the new mechanism.  By default that flag doesn't get
      set so drivers will continue to see the same polling behavior as before.
      This way we can convert the HCDs one by one to use interrupt-based event
      reporting, and the temporary flag can be removed when they're all done.
      
      Also included is a small change to the hcd_disable_endpoint routine.
      Although endpoints normally shouldn't be disabled while a controller is
      suspended, it's legal to do so when the controller's driver is being
      rmmod'ed.
      
      Lastly the patch adds a new callback, .hub_irq_enable, for use by HCDs
      where the root hub's port-change interrupts are level-triggered rather
      than edge-triggered.  The callback is invoked each time khubd has finished
      processing a root hub, to let the HCD know that the interrupt can safely
      be re-enabled.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      d5926ae7
    • Alan Stern's avatar
      [PATCH] USB UHCI: Add shutdown method · 02597d2d
      Alan Stern authored
      After all the discussion you might not be interested in this still, but
      nevertheless here it is.  This patch adds a shutdown method to the
      uhci-hcd driver.  Its prerequisite is the patch you wrote adding shutdown
      support for PCI.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      02597d2d
    • Alan Stern's avatar
      [PATCH] USB UHCI: improved reset handling · c074b416
      Alan Stern authored
      This patch improves the strategy uhci-hcd uses for performing controller
      resets and checking whether they are needed.
      
      	The HCRESET command doesn't affect the Suspend, Resume,
      	or Reset bits in the port status & control registers, so
      	the driver must clear them by itself.  This means the
      	code to figure out how many ports there are has to be moved
      	to an earlier spot in the driver.
      
      	The R/WC bits in the USBLEGSUP register can be set by the
      	hardware even in the absence of BIOS meddling with legacy
      	support features.  Hence it's not a good idea to check them
      	while trying to determine whether the BIOS has altered the
      	controller's state.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      c074b416
    • Alan Stern's avatar
      [PATCH] USB UHCI: Use root-hub IRQs while suspended · 6c1b445c
      Alan Stern authored
      This patch, which has as478b as a prerequisite, enables the uhci-hcd
      driver to take advantage of root-hub IRQs rather than polling during the
      time it is suspended.  (Unfortunately the hardware doesn't support
      port-change interrupts while the controller is running.)  It also turns
      off the driver's private timer while the controller is suspended, as it
      isn't needed then.  The combined elimination of polling interrupts and
      timer interrupts ought to be enough to allow some systems to save a
      noticeable amount of power while they are otherwise idle.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      6c1b445c
    • Alan Stern's avatar
      [PATCH] USB UHCI: Fix up loose ends · 4daaa87c
      Alan Stern authored
      This patch tidies up a few loose ends left by the preceding patches.
      It indicates the controller supports remote wakeup whenever the PM
      capability is present -- which shouldn't cause any harm if the
      assumption turns out to be wrong.  It refuses to suspend the
      controller if the root hub is still active, and it refuses to resume
      the root hub if the controller is suspended.  It adds checks for a
      dead controller in several spots, and it adds memory barriers as
      needed to insure that I/O operations are completed before moving on.
      
      Actually I'm not certain the last part is being done correctly.  With
      code like this:
      
      	outw(..., ...);
      	mb();
      	udelay(5);
      
      do we know for certain that the outw() will complete _before_ the
      delay begins?  If not, how should this be written?
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      4daaa87c
    • Alan Stern's avatar
      [PATCH] USB UHCI: Add root-hub suspend/resume support · a8bed8b6
      Alan Stern authored
      This patch implements (finally!) separate suspend and resume routines
      for the root hub and the controller in the UHCI driver.  It also
      changes the sequence used to reset the controller during initial
      probing, so as to preserve the existing state during a Resume-From-Disk.
      (This new sequence is what should be used in the PCI Quirks code for
      early USB handoffs, incidentally.)  Lastly it adds a notion of the
      controller being "inaccessible" while in a PCI low-power state, when
      normal I/O operations shouldn't be allowed.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      a8bed8b6
    • Alan Stern's avatar
      [PATCH] USB UHCI: Add root hub states · c8f4fe43
      Alan Stern authored
      This patch starts making some serious changes to the UHCI driver.
      There's a set of private states for the root hub, and the internal
      routines for suspending and resuming work completely differently, with
      transitions based on the new states.  Now the driver distinguishes
      between a privately auto-stopped state and a publicly suspended state,
      and it will properly suspend controllers with broken resume-detect
      interrupts instead of resetting them.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      c8f4fe43
    • Alan Stern's avatar
      [PATCH] USB UHCI: Minor improvements · f5946f82
      Alan Stern authored
      This patch makes a few small improvements in the UHCI driver.  Some
      code is moved between different source files and a more useful pointer
      is passed to a callback routine.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      f5946f82
    • Alan Stern's avatar
      [PATCH] USB UHCI: subroutine reordering · 014e73c9
      Alan Stern authored
      This patch moves a few subroutines around in the uhci-hcd source file.
      Nothing else is changed.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      014e73c9
    • David Brownell's avatar
      [PATCH] USB: turn a user mode driver error into a hard error · 72ebddb5
      David Brownell authored
      This patch turns a user mode driver error into a hard error, and updates
      the relevant diagnostic slightly to help troubleshooting.  gphoto was
      known to have this problem, hopefully it is now fixed (they have had
      plenty of warning...)
      
      This had been left as a soft error to give various user mode drivers a
      change to be properly fixed, with the statement that starting in about
      2.6.10 it would be changed.  It had been mostly safe as a soft error ...
      but that can not be guaranteed.  Now that a year has passed, it's time to
      really insist that the user mode drivers finally fix their relevant bugs.
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      72ebddb5
    • Olav Kongas's avatar
      [PATCH] USB: Fix oops at rmmod after failed probe in isp116x-hcd · 589a0083
      Olav Kongas authored
      This patch fixes an oops triggered at rmmod of isp116x-hcd
      after the probe() has failed.
      
      Also, it extends the error message printed, if the driver
      cannot detect "Chip's Clock Ready" after a software reset.
      As Ian Campbell recently reported, this happens if the
      chip's H_WAKEUP pin is not pulled low during software reset.
      Several people have already had this issue, hence the update
      to the error message.
      
      Also, extend the error message about the failed clock
      detection after the software reset.
      Signed-off-by: default avatarOlav Kongas <ok@artecdesign.ee>
      589a0083
    • Olav Kongas's avatar
      [PATCH] USB: Add isp116x-hcd USB host controller driver · 4808a1c0
      Olav Kongas authored
      This patch provides an "isp116x-hcd" driver for Philips'
      ISP1160/ISP1161 USB host controllers.
      
      The driver:
       - is relatively small, meant for use on embedded platforms.
       - runs usbtests 1-14 without problems for days.
       - has been in use by 6-7 different people on ARM and PPC platforms,
         running a range of devices including USB hubs.
       - supports suspend/resume of both the platform device and the root hub;
         supports remote wakeup of the root hub (but NOT the platform device)
         by USB devices.
       - does NOT support ISO transfers (nobody has asked for them).
       - is PIO-only.
      Signed-off-by: default avatarOlav Kongas <ok@artecdesign.ee>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      4808a1c0
    • David Brownell's avatar
      [PATCH] USB: omap_udc updates (mostly cleanups) · 313980c9
      David Brownell authored
      Various USB patches, mostly for portability:
      
        - Fifo mode 1 didn't work previously (oopsed), so now it's fixed and
          (why not) defines even more endpoints for composite devices.
      
        - OMAP 1710 doesn't have an internal transceiver.
      
        - Small PM update:  if the USB link is suspended, don't disconnect on
          entry to deep sleep.
      
        - Be more correct about handling zero length control reads.  OMAP
          seems to mis-handle that protocol peculiarity though; best avoided.
      
        - Platform device resources (for UDC and OTG controllers) now use
          physical addresses, so /proc/iomem is more consistent.
      
        - Minor cleanups, notably (by volume) for "sparse" NULL warnings.
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      313980c9
    • Alan Stern's avatar
      [PATCH] USB: g_file_storage: export "stall" parameter · d794ac7a
      Alan Stern authored
      This patch changes the g_file_storage driver to make the "stall" module
      parameter generally available; currently it is available only if the
      testing version of the module has been configured.  It also fixes a typo
      in a comment -- thanks, Pat!
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      d794ac7a
    • Alan Stern's avatar
      [PATCH] USB: g_file_storage: Consolidate min()s · 76f4af8e
      Alan Stern authored
      This patch simplifies the g_file_storage driver by consolidating a bunch
      of min() calculations at a single spot.
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      76f4af8e
    • Linus Torvalds's avatar
    • Linus Torvalds's avatar
      41b6c373
  2. 26 Jun, 2005 23 commits