Skip to content
  1. Jul 15, 2009
  2. Jul 14, 2009
    • Linus Torvalds's avatar
      Linux 2.6.31-rc3 · 6847e154
      Linus Torvalds authored
      6847e154
    • Linus Torvalds's avatar
      Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 · 1cf29683
      Linus Torvalds authored
      * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4:
        jbd2: fix race between write_metadata_buffer and get_write_access
        ext4: Fix ext4_mb_initialize_context() to initialize all fields
        ext4: fix null handler of ioctls in no journal mode
        ext4: Fix buffer head reference leak in no-journal mode
        ext4: Move __ext4_journalled_writepage() to avoid forward declaration
        ext4: Fix mmap/truncate race when blocksize < pagesize && !nodellaoc
        ext4: Fix mmap/truncate race when blocksize < pagesize && delayed allocation
        ext4: Don't look at buffer_heads outside i_size.
        ext4: Fix goal inum check in the inode allocator
        ext4: fix no journal corruption with locale-gen
        ext4: Calculate required journal credits for inserting an extent properly
        ext4: Fix truncation of symlinks after failed write
        jbd2: Fix a race between checkpointing code and journal_get_write_access()
        ext4: Use rcu_barrier() on module unload.
        ext4: naturally align struct ext4_allocation_request
        ext4: mark several more functions in mballoc.c as noinline
        ext4: Fix potential reclaim deadlock when truncating partial block
        jbd2: Remove GFP_ATOMIC kmalloc from inside spinlock critical region
        ext4: Fix type warning on 64-bit platforms in tracing events header
      1cf29683
    • dingdinghua's avatar
      jbd2: fix race between write_metadata_buffer and get_write_access · 96577c43
      dingdinghua authored
      
      
      The function jbd2_journal_write_metadata_buffer() calls
      jbd_unlock_bh_state(bh_in) too early; this could potentially allow
      another thread to call get_write_access on the buffer head, modify the
      data, and dirty it, and allowing the wrong data to be written into the
      journal.  Fortunately, if we lose this race, the only time this will
      actually cause filesystem corruption is if there is a system crash or
      other unclean shutdown of the system before the next commit can take
      place.
      
      Signed-off-by: default avatardingdinghua <dingdinghua85@gmail.com>
      Signed-off-by: default avatar"Theodore Ts'o" <tytso@mit.edu>
      96577c43
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6 · 4a390e07
      Linus Torvalds authored
      * git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6:
        Staging: stlc45xx: convert config_interface to bss_info_changed, fixing a build error
        Staging: comedi: s626: use subvendor:subdevice ids for SAA7146 board
        Staging: prevent rtl8192su from crashing dev_ioctl in SIOCGIWNAME
        Staging: prevent rtl8187se from crashing dev_ioctl() in SIOCGIWNAME
        Staging: rtl8192su: convert to net_device_ops
        Staging: serqt_usb2: declare qt_open static in serqt_usb2
        Staging: serqt_usb2: fix qt_close parameters in serqt_usb2
        Staging: comedi: jr3_pci.c: add required includes
        Staging: meilhaus: add email address to TODO
        Staging: rspiusb: use NULL virtual address instead of a bogus one
        Staging: vt6655: compile fix
        Staging: rt2870: Add USB ID for Sitecom WL-608
      4a390e07
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6 · a4dc3237
      Linus Torvalds authored
      * git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6:
        wm97xx_batery: replace driver_data with dev_get_drvdata()
        omap: video: remove direct access of driver_data
        Sound: remove direct access of driver_data
        driver model: fix show/store prototypes in doc.
        Firmware: firmware_class, fix lock imbalance
        Driver Core: remove BUS_ID_SIZE
        sparc: remove driver-core BUS_ID_SIZE
        partitions: fix broken uevent_suppress conversion
        devres: WARN() and return, don't crash on device_del() of uninitialized device
      a4dc3237
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6 · 51feb98d
      Linus Torvalds authored
      * git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (48 commits)
        USB: otg: fix module reinsert issue
        USB: handle zero-length usbfs submissions correctly
        USB: EHCI: report actual_length for iso transfers
        USB: option: remove unnecessary and erroneous code
        USB: cypress_m8: remove invalid Clear-Halt
        USB: musb_host: undo incorrect change in musb_advance_schedule()
        USB: fix LANGID=0 regression
        USB: serial: sierra driver id_table additions
        USB serial: Add ID for Turtelizer, an FT2232L-based JTAG/RS-232 adapter.
        USB: fix race leading to a write after kfree in usbfs
        USB: Sierra: fix oops upon device close
        USB: option.c: add A-Link 3GU device id
        USB: Serial: Add support for Arkham Technology adapters
        USB: Fix option_ms regression in 2.6.31-rc2
        USB: gadget audio: select SND_PCM
        USB: ftdi: support NDI devices
        Revert USB: usbfs: deprecate and hide option for !embedded
        USB: usb.h: fix kernel-doc notation
        USB: RNDIS gadget, fix issues talking from PXA
        USB: serial: FTDI with product code FB80 and vendor id 0403
        ...
      51feb98d
    • Dave Kleikamp's avatar
      update JFS entry in MAINTAINERS · 8f8f0134
      Dave Kleikamp authored
      
      
      JFS hasn't really been supported for a while.  It's still maintained,
      but saying it's supported is a stretch.  Updating my preferred email
      address as well.
      
      Signed-off-by: default avatarDave Kleikamp <shaggy@linux.vnet.ibm.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      8f8f0134
    • Huang Weiyi's avatar
      mn10300: remove duplicated #include · 5fddcdb7
      Huang Weiyi authored
      
      
      Remove duplicated #include('s) in
        arch/mn10300/kernel/sys_mn10300.c
      
      Signed-off-by: default avatarHuang Weiyi <weiyi.huang@gmail.com>
      Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      5fddcdb7
    • Jean Delvare's avatar
      Fix staging drivers after smp_lock.h redux · 1d03d2bd
      Jean Delvare authored
      Commit 405f5571
      
       ("headers: smp_lock.h
      redux") broke the build of two staging drivers. Fix them.
      
      Signed-off-by: default avatarJean Delvare <khali@linux-fr.org>
      Cc: Alexey Dobriyan <adobriyan@gmail.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      1d03d2bd
  3. Jul 13, 2009
    • Theodore Ts'o's avatar
      ext4: Fix ext4_mb_initialize_context() to initialize all fields · 833576b3
      Theodore Ts'o authored
      
      
      Pavel Roskin pointed out that kmemcheck indicated that
      ext4_mb_store_history() was accessing uninitialized values of
      ac->ac_tail and ac->ac_buddy leading to garbage in the mballoc
      history.  Fix this by initializing the entire structure to all zeros
      first.
      
      Also, two fields were getting doubly initialized by the caller of
      ext4_mb_initialize_context, so remove them for efficiency's sake.
      
      Signed-off-by: default avatar"Theodore Ts'o" <tytso@mit.edu>
      833576b3
    • Peng Tao's avatar
      ext4: fix null handler of ioctls in no journal mode · ac046f1d
      Peng Tao authored
      
      
      The EXT4_IOC_GROUP_ADD and EXT4_IOC_GROUP_EXTEND ioctls should not
      flush the journal in no_journal mode.  Otherwise, running resize2fs on
      a mounted no_journal partition triggers the following error messages:
      
      BUG: unable to handle kernel NULL pointer dereference at 00000014
      IP: [<c039d282>] _spin_lock+0x8/0x19
      *pde = 00000000 
      Oops: 0002 [#1] SMP
      
      Signed-off-by: default avatarPeng Tao <bergwolf@gmail.com>
      Signed-off-by: default avatar"Theodore Ts'o" <tytso@mit.edu>
      ac046f1d
    • Curt Wohlgemuth's avatar
      ext4: Fix buffer head reference leak in no-journal mode · e6b5d301
      Curt Wohlgemuth authored
      
      
      We found a problem with buffer head reference leaks when using an ext4
      partition without a journal.  In particular, calls to ext4_forget() would
      not to a brelse() on the input buffer head, which will cause pages they
      belong to to not be reclaimable.
      
      Further investigation showed that all places where ext4_journal_forget() and
      ext4_journal_revoke() are called are subject to the same problem.  The patch
      below changes __ext4_journal_forget/__ext4_journal_revoke to do an explicit
      release of the buffer head when the journal handle isn't valid.
      
      Signed-off-by: default avatarCurt Wohlgemuth <curtw@google.com>
      Signed-off-by: default avatar"Theodore Ts'o" <tytso@mit.edu>
      e6b5d301
    • Ajay Kumar Gupta's avatar
      USB: otg: fix module reinsert issue · dc7520c1
      Ajay Kumar Gupta authored
      
      
      Platform_device instance (pd) is not set to NULL in
      usb_nop_xceiv_unregister() causing usb_nop_xceiv_register()
      to fail during module reinsert.
      
      From: Ajay Kumar Gupta <ajay.gupta@ti.com>
      Signed-off-by: default avatarBabu Ravi <ravibabu@ti.com>
      Acked-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      dc7520c1
    • Alan Stern's avatar
      USB: handle zero-length usbfs submissions correctly · 9180135b
      Alan Stern authored
      
      
      This patch (as1262) fixes a bug in usbfs: It refuses to accept
      zero-length transfers, and it insists that the buffer pointer be valid
      even if there is no data being transferred.
      
      The patch also consolidates a bunch of repetitive access_ok() checks
      into a single check, which incidentally fixes the lack of such a check
      for Isochronous URBs.
      
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      9180135b
    • Alan Stern's avatar
      USB: EHCI: report actual_length for iso transfers · ec6d67e3
      Alan Stern authored
      
      
      This patch (as1259b) makes ehci-hcd return the total number of bytes
      transferred in urb->actual_length for Isochronous transfers.
      Until now, the actual_length value was unaccountably left at 0.
      
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Acked-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      ec6d67e3
    • Alan Stern's avatar
      USB: option: remove unnecessary and erroneous code · f092c240
      Alan Stern authored
      
      
      This patch (as1264) removes a bunch of unnecessary and erroneous stuff
      from the option USB-serial driver.  Clearly there's no need to verify
      that the device pointer stored in the URBs is right or to store the
      same pointer over again.  After all, the pointer can't change once it
      has been set up.
      
      There's also no need to call usb_clear_halt for the IN endpoint
      multiple times -- in fact, doing so is an error since every time after
      the first there will be active URBs queued for that endpoint.  Since
      the Clear-Halts don't appear to be needed at all, the patch simply
      removes them.
      
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      f092c240
    • Alan Stern's avatar
      USB: cypress_m8: remove invalid Clear-Halt · 4d2fae8b
      Alan Stern authored
      
      
      This patch (as1265) removes an erroneous call to usb_clear_halt from
      the cypress_m8 driver.  The call isn't valid because it is made from
      interrupt context whereas usb_clear_halt is a blocking routine.
      
      Presumably the code has never been executed; if it did it would cause
      an oops.  So instead treat -EPIPE like any other sort of unexplained
      error.
      
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      4d2fae8b
    • Sergei Shtylyov's avatar
      USB: musb_host: undo incorrect change in musb_advance_schedule() · 1fe975f9
      Sergei Shtylyov authored
      Commit c9cd06b3
      
       (musb_host: refactor
      URB giveback) included due to my overlook the change incorrect in the
      context of the current kernel -- undo it.
      
      Signed-off-by: default avatarSergei Shtylyov <sshtylyov@ru.mvista.com>
      Acked-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      1fe975f9
    • Daniel Mack's avatar
      USB: fix LANGID=0 regression · 0cce2eda
      Daniel Mack authored
      commit b7af0bb2 ("USB: allow malformed LANGID descriptors") broke support
      for devices without string descriptor support.
      
      Reporting string descriptors is optional to USB devices, and a device
      lets us know it can't deal with strings by responding to the LANGID
      request with a STALL token.
      
      The kernel handled that correctly before b7af0bb2
      
       came in, but failed
      hard if the LANGID was reported but broken. More than that, if a device
      was not able to provide string descriptors, the LANGID was retrieved
      over and over again at each string read request.
      
      This patch changes the behaviour so that
      
       a) the LANGID is only queried once
       b) devices which can't handle string requests are not asked again
       c) devices with malformed LANGID values have a sane fallback to 0x0409
      
      Signed-off-by: default avatarDaniel Mack <daniel@caiaq.de>
      Acked-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      0cce2eda
    • Elina Pasheva's avatar
      USB: serial: sierra driver id_table additions · c5f3d87d
      Elina Pasheva authored
      
      
      - Updated the id_table with all devices that Sierra Wireless currently
         support
       - Re-ordered the contents of the id_table for better readability
      
      Signed-off-by: default avatarElina Pasheva <epasheva@sierrawireless.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      c5f3d87d
    • Krzysztof Halasa's avatar
      USB serial: Add ID for Turtelizer, an FT2232L-based JTAG/RS-232 adapter. · 14511412
      Krzysztof Halasa authored
      
      
      Adds USB ID for Turtelizer, an FT2232L-based JTAG/RS-232 adapter.
      
      Signed-off-by: default avatarKrzysztof Ha³asa <khc@pm.waw.pl>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      14511412
    • Oliver Neukum's avatar
      USB: fix race leading to a write after kfree in usbfs · 516a1a07
      Oliver Neukum authored
      
      
      this fixes a race between async_completed() and proc_reapurbnonblock().
      
      CPU A                   CPU B
      
      spin_lock(&ps->lock);
      list_move_tail(&as->asynclist, &ps->async_completed);
      spin_unlock(&ps->lock);
      
                                      if (!(as = async_getcompleted(ps)))
                                              return -EAGAIN;
                                      return processcompl(as, (void __user * __user *)arg);
      
      processcompl() calls free_async() which calls kfree(as)
      
      as->status = urb->status;
      if (as->signr) {
              sinfo.si_signo = as->signr;
              sinfo.si_errno = as->status;
              sinfo.si_code = SI_ASYNCIO;
              sinfo.si_addr = as->userurb;
              kill_pid_info_as_uid(as->signr, &sinfo, as->pid, as->uid,
                                    as->euid, as->secid);
      }
      snoop(&urb->dev->dev, "urb complete\n");
      snoop_urb(urb, as->userurb);
      
      write after kfree
      
      Signed-off-by: default avatarOliver Neukum <oliver@neukum.org>
      516a1a07
    • Alan Stern's avatar
      USB: Sierra: fix oops upon device close · 7bae0a07
      Alan Stern authored
      
      
      This patch (as1263) fixes a mixup that occurred when conflicting
      patches for the sierra driver were merged incorrectly.  The former
      sierra_shutdown routine should have been become sierra_release, not
      sierra_disconnect.
      
      The symptom this fixes is an oops when the device file is closed after
      a Sierra device has been unplugged (Bugzilla #13675).
      
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Tested-by: default avatarPeter Naulls <peter@mushroomnetworks.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      7bae0a07
    • Anssi Hannula's avatar
      USB: option.c: add A-Link 3GU device id · c3325eb1
      Anssi Hannula authored
      
      
      Add A-Link 3GU device id 1e0e:9200 into option driver. The device
      has 4 interfaces, of which 1 is handled by storage and the other 3
      by option driver.
      
      The device appears first as CD-only 1e0e:f000 device and must be
      switched to 1e0e:9200 mode either by using "eject CD" or
      usb_modeswitch.
      
      For the record, the device does not work with generic usbserial
      driver (usb disconnect when sending the ATDT command).
      
      Signed-off-by: default avatarAnssi Hannula <anssi.hannula@gmail.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      
      c3325eb1
    • Amit Kucheria's avatar
      USB: Serial: Add support for Arkham Technology adapters · 0601e116
      Amit Kucheria authored
      
      
      As reported by David Potts from Arkham Technology, the current driver
      works with their hardware on addition of the device ids.
      
      Signed-off-by: default avatarAmit Kucheria <amit.kucheria@canonical.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      0601e116
    • Jonathan McDowell's avatar
      USB: Fix option_ms regression in 2.6.31-rc2 · 2ab2178c
      Jonathan McDowell authored
      Commit 32ebbe7b
      
       which filters the
      SCSI REZERO command in option_ms based on a SCSI INQUIRY with a vendor
      of Option breaks my Option Icon 225 (0af0:6971). This device returns a
      vendor of ZCOPTION for the ZeroCD device. The following trivial patch
      fixes things for me.
      
      Signed-Off-By: default avatarJonathan McDowell <noodles@earth.li>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      2ab2178c
    • Randy Dunlap's avatar
      USB: gadget audio: select SND_PCM · 04950737
      Randy Dunlap authored
      
      
      Fix USB gadget audio: select SND_PCM, like many other sound
      drivers do, to fix build errors:
      
      drivers/built-in.o: In function `f_audio_playback_work':
      audio.c:(.text+0x15a3e7): undefined reference to `snd_pcm_kernel_ioctl'
      audio.c:(.text+0x15a471): undefined reference to `snd_pcm_lib_write'
      drivers/built-in.o: In function `_snd_pcm_hw_param_set':
      audio.c:(.text+0x15aca7): undefined reference to `snd_interval_refine'
      drivers/built-in.o: In function `gaudio_setup':
      (.init.text+0x12adf): undefined reference to `_snd_pcm_hw_params_any'
      drivers/built-in.o: In function `gaudio_setup':
      (.init.text+0x12b43): undefined reference to `snd_pcm_kernel_ioctl'
      
      Signed-off-by: default avatarRandy Dunlap <randy.dunlap@oracle.com>
      Acked-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      04950737
    • Martin Geleynse's avatar
      USB: ftdi: support NDI devices · b760dac2
      Martin Geleynse authored
      
      
      It enhances the driver for FTDI-based USB serial adapters to recognize and
      support Northern Digital Inc (NDI) measurement equipment. NDI has been
      providing this patch for various kernel flavors for several years and we would
      like to see these changes built in to the driver so that our equipement works
      without the need for customers to patch the kernel themselves.
      
      The patch makes small modifications to 2 files: ./drivers/usb/serial/ftdi_sio.c
      and ./drivers/usb/serial/ftdi_sio.h. It accomplishes 3 things:
      
      1. Define the VID and PIDs to allow the driver to recognize the NDI devices.
      2. Map the 19200 baud rate setting to our higher baud rate of 1.2Mb
         We would have chosen to map 38400 to the higher rate, similar to what
         several other vendors have done, but some of our legacy customers actually
         use 38400, therefore we remap 19200 to the higher rate.
      3. We set the default transmit latency in the FTDI chip to 1ms for our devices.
         Our devices are typically polled at 60Hz and the default ftdi latency
         seriously affects turn-around time and results in missed data frames. We
         have created a modprobe option that allows this setting to be increased.
         This has proven necessary particularly in some virtualized environments.
      
      Signed-off-by: default avatarMartin P. Geleynse <mgeleyns@ndigital.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      
      b760dac2
    • Greg Kroah-Hartman's avatar
      Revert USB: usbfs: deprecate and hide option for !embedded · e12df02a
      Greg Kroah-Hartman authored
      This reverts commit cc71329b
      
      , so that
      Red Hat machines can boot properly.  It seems that the Red Hat initrd
      code tries to watch the /proc/bus/usb/devices file to monitor usb
      devices showing up.  While this task is prone to lots of races and does
      not show the true state of the system, they seem to like it.
      
      So for now, don't move this option under the EMBEDDED config option.
      
      
      Cc: Scott James Remnant <scott@canonical.com>
      Cc: Kay Sievers <kay.sievers@vrfy.org>
      Cc: Dave Airlie <airlied@gmail.com>
      Cc: Peter Jones <pjones@redhat.com>
      Cc: Jeff Chua <jeff.chua.linux@gmail.com>
      Cc: Dave Jones <davej@redhat.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      e12df02a
    • Randy Dunlap's avatar
      USB: usb.h: fix kernel-doc notation · e376bbbb
      Randy Dunlap authored
      
      
      Fix usb.h kernel-doc warnings:
      
      Warning(include/linux/usb.h:918): Excess struct/union/enum/typedef member 'nodename' description in 'usb_device_driver'
      Warning(include/linux/usb.h:939): No description found for parameter 'nodename'
      Warning(include/linux/usb.h:1219): No description found for parameter 'sg'
      Warning(include/linux/usb.h:1219): No description found for parameter 'num_sgs'
      
      Signed-off-by: default avatarRandy Dunlap <randy.dunlap@oracle.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      e376bbbb
    • David Brownell's avatar
      USB: RNDIS gadget, fix issues talking from PXA · 4e19f220
      David Brownell authored
      
      
      The reworked Ethernet gadget has an RNDIS interop problem when used
      with the CDC subset driver ... e.g. on PXA 2xx and 3xx hardware,
      which currently has a hard time talking to MS-Windows hosts.
      
      The issue is that Microsoft requires USB_CLASS_COMM.  Fix by tweaking
      the CDC subset driver to not switch to USB_CLASS_VENDOR_SPEC if RNDIS
      is used in some other device configuration.
      
      [ UPDATED:  some "statements" were comma-terminated; fix that. ]
      
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Cc: Aric Blumer <aric@sdgsystems.net>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      4e19f220
    • Folkert van Heusden's avatar
      USB: serial: FTDI with product code FB80 and vendor id 0403 · b34efeea
      Folkert van Heusden authored
      
      
      It seems an USB device with vendor id 0403 and product code FB80 has an
      FTDI serial io chip as well: http://ftdichip.com/Drivers/D2XX.htm
      This device in fact is a true random generantor by comsci:
      http://comscire.com/Products/R2000KU/
      So the following patch should add support for this device if I am
      correct. Not tested as I do not own this device (I would like support in
      the kernel so that my entropybroker application (which distributes
      entrop data (random values) between servers and clients)).
      
      
      From: Folkert van Heusden <folkert@vanheusden.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      b34efeea
    • Jason Wessel's avatar
      USB: console: Fix regression in usb console on kernel boot · 6e406121
      Jason Wessel authored
      The commit 335f8514
      
       introduced a
      regression which stopped usb consoles from working correctly as a
      kernel boot console as well as interactive login device.
      
      The addition of the serial_close() which in turn calls
      tty_port_close_start() will change the reference count of port.count
      and warn about it.  The usb console code had previously incremented
      the port.count to indicate it was making use of the device as a
      console and the forced change causes a double open on the usb device
      which leads to a non obvious kernel oops later on when the tty is
      freed.
      
      To fix the problem instead make use of port->console to track if the
      port is in fact an active console port to avoid double initialization
      of the usb serial device.  The port.count is incremented and
      decremented only with in the scope of usb_console_setup() for the
      purpose of the low level driver initialization.
      
      Signed-off-by: default avatarJason Wessel <jason.wessel@windriver.com>
      Acked-by: default avatarAlan Cox <alan@linux.intel.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      6e406121
    • Frans Pop's avatar
      USB: add missing class descriptions used in usb/devices file · bf7fbb02
      Frans Pop authored
      
      
      Added descriptions (for WIRELESS_CONTROLLER and MISC) were taken from
      the usb-devices script now included in usbutils.
      
      Also sort the classes in the same order as in include/linux/usb/ch9.h
      for easier comparison for future updates.
      
      Signed-off-by: default avatarFrans Pop <elendil@planet.nl>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      bf7fbb02
    • Oliver Neukum's avatar
      USB: fix memleak in usbfs · d794a021
      Oliver Neukum authored
      
      
      This patch fixes a memory leak in devio.c::processcompl
      
      If writing to user space fails the packet must be discarded, as it
      already has been removed from the queue of completed packets.
      
      Signed-off-by: default avatarOliver Neukum <oliver@neukum.org>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      d794a021
    • Alan Stern's avatar
      USB: EHCI: check for STALL before other errors · ba516de3
      Alan Stern authored
      
      
      This patch (as1257) revises the way ehci-hcd detects STALLs.  The
      logic is a little peculiar because there's no hardware status bit
      specifically meant to indicate a STALL.  You just have to guess that a
      STALL was received if the BABBLE bit (which is fatal) isn't set and
      the transfer stopped before all its retries were used up.
      
      The existing code doesn't do this properly, because it tests for MMF
      (Missed MicroFrame) and DBE (Data Buffer Error) before testing the
      retry counter.  Thus, if a transaction gets either MMF or DBE the
      corresponding flag is set and the transaction is retried.  If the
      second attempt receives a STALL then -EPIPE is the correct return
      value.  But the existing code would see the MMF or DBE flag instead
      and return -EPROTO, -ENOSR, or -ECOMM.
      
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Acked-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      ba516de3
    • Alan Stern's avatar
      USB: EHCI: use the new clear_tt_buffer interface · 914b7012
      Alan Stern authored
      
      
      This patch (as1256) changes ehci-hcd and all the other drivers in the
      EHCI family to make use of the new clear_tt_buffer callbacks.  When a
      Clear-TT-Buffer request is in progress for a QH, the QH is not allowed
      to be linked into the async schedule until the request is finished.
      At that time, if there are any URBs queued for the QH, it is linked
      into the async schedule.
      
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      914b7012
    • Alan Stern's avatar
      USB: fix the clear_tt_buffer interface · cb88a1b8
      Alan Stern authored
      
      
      This patch (as1255) updates the interface for calling
      usb_hub_clear_tt_buffer().  Even the name of the function is changed!
      
      When an async URB (i.e., Control or Bulk) going through a high-speed
      hub to a non-high-speed device is cancelled or fails, the hub's
      Transaction Translator buffer may be left busy still trying to
      complete the transaction.  The buffer has to be cleared; that's what
      usb_hub_clear_tt_buffer() does.
      
      It isn't safe to send any more URBs to the same endpoint until the TT
      buffer is fully clear.  Therefore the HCD needs to be told when the
      Clear-TT-Buffer request has finished.  This patch adds a callback
      method to struct hc_driver for that purpose, and makes the hub driver
      invoke the callback at the proper time.
      
      The patch also changes a couple of names; "hub_tt_kevent" and
      "tt.kevent" now look rather antiquated.
      
      Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Cc: stable <stable@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
      cb88a1b8