1. 14 May, 2008 1 commit
    • Marcin Slusarz's avatar
      usbtest: comment on why this code "expects" negative and positive errnos · 6def7553
      Marcin Slusarz authored
      On Mon, May 12, 2008 at 01:02:22AM -0700, David Brownell wrote:
      > On Sunday 11 May 2008, Marcin Slusarz wrote:
      > > 
      > > test_ctrl_queue expects (?) positive and negative errnos.
      > > what is going on here?
      > The sign is just a way to flag something:
      >                 /* some faults are allowed, not required */
      > The negative ones are required.  Positive codes are optional,
      > in the sense that, depending on how the peripheral happens
      > to be implemented, they won't necessarily be triggered.
      > For example, the test to fetch a device qualifier desriptor
      > must succeed if the device is running at high speed.  So that
      > test is marked as negative.  But when it's full speed, it
      > could legitimately fail; marked as positive.  And so on for
      > other tests.
      > Look at how the codes are *interpreted* to see it work.
      Lets document it.
      Based on comment from David Brownell <david-b@pacbell.net>.
      Signed-off-by: default avatarMarcin Slusarz <marcin.slusarz@gmail.com>
      Cc: David Brownell <david-b@pacbell.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
  2. 02 May, 2008 1 commit
    • David Brownell's avatar
      USB: usbtest displays diagnostics again · 28ffd79c
      David Brownell authored
      Minor cleanup to the "usbtest" driver, mostly to resolve a regression:
      all the important diagnostics were at KERN_DEBUG, so that when the
      "#define DEBUG" was removed from the top of that file it stopped
      providing diagnostics.  Fix by using KERN_ERROR.  Also:
       - Stop using the legacy dbg() calls
       - Simplify the internal debug macros
       - Correct some test descriptions:
      	* Test #10 subcase 7 should *always* stall
      	* Test #10 subcase 8 *may* stall
       - Diagnostic about control queue test failures is more informative
       - Fix some whitespace "bugs"
      And add a warning about the rude interaction between usbfs ioctl()
      and khubd during device disconnect ... don't unplug a device under
      test, that will wedge.
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
  3. 24 Apr, 2008 4 commits
  4. 02 Apr, 2008 1 commit
  5. 01 Feb, 2008 4 commits
  6. 22 Oct, 2007 1 commit
  7. 19 Jul, 2007 1 commit
  8. 07 Dec, 2006 2 commits
  9. 01 Dec, 2006 1 commit
  10. 05 Oct, 2006 1 commit
    • David Howells's avatar
      IRQ: Maintain regs pointer globally rather than passing to IRQ handlers · 7d12e780
      David Howells authored
      Maintain a per-CPU global "struct pt_regs *" variable which can be used instead
      of passing regs around manually through all ~1800 interrupt handlers in the
      Linux kernel.
      The regs pointer is used in few places, but it potentially costs both stack
      space and code to pass it around.  On the FRV arch, removing the regs parameter
      from all the genirq function results in a 20% speed up of the IRQ exit path
      (ie: from leaving timer_interrupt() to leaving do_IRQ()).
      Where appropriate, an arch may override the generic storage facility and do
      something different with the variable.  On FRV, for instance, the address is
      maintained in GR28 at all times inside the kernel as part of general exception
      Having looked over the code, it appears that the parameter may be handed down
      through up to twenty or so layers of functions.  Consider a USB character
      device attached to a USB hub, attached to a USB controller that posts its
      interrupts through a cascaded auxiliary interrupt controller.  A character
      device driver may want to pass regs to the sysrq handler through the input
      layer which adds another few layers of parameter passing.
      I've build this code with allyesconfig for x86_64 and i386.  I've runtested the
      main part of the code on FRV and i386, though I can't test most of the drivers.
      I've also done partial conversion for powerpc and MIPS - these at least compile
      with minimal configurations.
      This will affect all archs.  Mostly the changes should be relatively easy.
      Take do_IRQ(), store the regs pointer at the beginning, saving the old one:
      	struct pt_regs *old_regs = set_irq_regs(regs);
      And put the old one back at the end:
      Don't pass regs through to generic_handle_irq() or __do_IRQ().
      In timer_interrupt(), this sort of change will be necessary:
      	-	update_process_times(user_mode(regs));
      	-	profile_tick(CPU_PROFILING, regs);
      	+	update_process_times(user_mode(get_irq_regs()));
      	+	profile_tick(CPU_PROFILING);
      I'd like to move update_process_times()'s use of get_irq_regs() into itself,
      except that i386, alone of the archs, uses something other than user_mode().
      Some notes on the interrupt handling in the drivers:
       (*) input_dev() is now gone entirely.  The regs pointer is no longer stored in
           the input_dev struct.
       (*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking.  It does
           something different depending on whether it's been supplied with a regs
           pointer or not.
       (*) Various IRQ handler function pointers have been moved to type
      Signed-Off-By: default avatarDavid Howells <dhowells@redhat.com>
      (cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)
  11. 11 Aug, 2006 1 commit
  12. 30 Jun, 2006 1 commit
  13. 21 Jun, 2006 2 commits
  14. 14 Apr, 2006 1 commit
    • David Brownell's avatar
      [PATCH] USB: usbtest: scatterlist OUT data pattern testing · 8b524901
      David Brownell authored
      Previously, scatterlist tests didn't write patterned data.  Given how many
      corner cases are addresed by them, this was a significant gap in Linux-USB
      test coverage.  Moreover, when peripherals checked for correct data patterns,
      false error reports would drown out the true ones.
      This adds the pattern on the way OUT from the host, so scatterlist tests can
      now be used to uncover bugs like host TX or peripheral RX paths failing for
      back-to-back short packets.  It's easy enough to get an error there with at
      least one of the {DMA,PIO}{RX,TX} code paths, or run into hardware races
      that need to be defended against.
      Note this patch doesn't add checking for correct data patterns on the way
      IN from peripherals, just a FIXME for later.
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
  15. 20 Mar, 2006 1 commit
  16. 04 Jan, 2006 1 commit
  17. 17 Nov, 2005 1 commit
  18. 29 Oct, 2005 1 commit
  19. 28 Oct, 2005 2 commits
    • Alan Stern's avatar
      [PATCH] Missing transfer_flags setting in usbtest · 3e8a556a
      Alan Stern authored
      This patch (as582) adds a missing transfer_flags setting to the usbtest
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
    • David Brownell's avatar
      [PATCH] usb_interface power state · db690874
      David Brownell authored
      This updates the handling of power state for USB interfaces.
        - Formalizes an existing invariant:  interface "power state" is a boolean:
          ON when I/O is allowed, and FREEZE otherwise.  It does so by defining
          some inlined helpers, then using them.
        - Adds a useful invariant:  the only interfaces marked active are those
          bound to non-suspended drivers.  Later patches build on this invariant.
        - Simplifies the interface driver API (and removes some error paths) by
          removing the requirement that they record power state changes during
          suspend and resume callbacks.  Now usbcore does that.
      A few drivers were simplified to address that last change.
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
       drivers/usb/core/hub.c       |   33 +++++++++------------
       drivers/usb/core/message.c   |    1
       drivers/usb/core/usb.c       |   65 +++++++++++++++++++++++++++++++++----------
       drivers/usb/core/usb.h       |   18 +++++++++++
       drivers/usb/input/hid-core.c |    2 -
       drivers/usb/misc/usbtest.c   |   10 ------
       drivers/usb/net/pegasus.c    |    2 -
       drivers/usb/net/usbnet.c     |    2 -
       8 files changed, 85 insertions(+), 48 deletions(-)
  20. 08 Sep, 2005 1 commit
    • Alan Stern's avatar
      [PATCH] USB: URB_ASYNC_UNLINK flag removed from the kernel · b375a049
      Alan Stern authored
      29 July 2005, Cambridge, MA:
      This afternoon Alan Stern submitted a patch to remove the URB_ASYNC_UNLINK
      flag from the Linux kernel.  Mr. Stern explained, "This flag is a relic
      from an earlier, less-well-designed system.  For over a year it hasn't
      been used for anything other than printing warning messages."
      An anonymous spokesman for the Linux kernel development community
      commented, "This is exactly the sort of thing we see happening all the
      time.  As the kernel evolves, support for old techniques and old code can
      be jettisoned and replaced by newer, better approaches.  Proprietary
      operating systems do not have the freedom or flexibility to change so
      Mr. Stern, a staff member at Harvard University's Rowland Institute who
      works on Linux only as a hobby, noted that the patch (labelled as548) did
      not update two files, keyspan.c and option.c, in the USB drivers' "serial"
      subdirectory.  "Those files need more extensive changes," he remarked.
      "They examine the status field of several URBs at times when they're not
      supposed to.  That will need to be fixed before the URB_ASYNC_UNLINK flag
      is removed."
      Greg Kroah-Hartman, the kernel maintainer responsible for overseeing all
      of Linux's USB drivers, did not respond to our inquiries or return our
      calls.  His only comment was "Applied, thanks."
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
  21. 05 Sep, 2005 1 commit
  22. 27 Jun, 2005 1 commit
    • David Brownell's avatar
      [PATCH] USB: usbtest updates · ff7c79e4
      David Brownell authored
      Updates to "usbtest" driver:
        * Improve some diagnostics.  One path that never generated diagnostics
          before should now generate two ... unless you hit a GCC bug that
          all my compilers seem to have, go figure.
        * Add suspend/resume support, so this behaves when the Linux host
          being used for testing suspends.
        * Don't test the "zero byte ep0 read" case unless real-world relevance
          for the testing is is irrelevant.
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
  23. 16 Apr, 2005 1 commit
    • Linus Torvalds's avatar
      Linux-2.6.12-rc2 · 1da177e4
      Linus Torvalds authored
      Initial git repository build. I'm not bothering with the full history,
      even though we have it. We can create a separate "historical" git
      archive of that later if we want to, and in the meantime it's about
      3.2GB when imported into git - space that would just make the early
      git days unnecessarily complicated, when we don't have a lot of good
      infrastructure for it.
      Let it rip!