1. 20 7月, 2007 1 次提交
  2. 18 7月, 2007 2 次提交
  3. 13 7月, 2007 3 次提交
    • J
      USB: Support Blackberry Pearl with berry_charge · 49bb607f
      Jeremy Katz 提交于
      The Blackberry Pearl (8100) needs similar tweaks as older Blackberry models
      to be able to charge when connected via USB.  The Pearl also adds an
      additional need to go into a separate mode for fully accessing the device;
      do that by default as well.
      
      Changes based on the changes from bcharge in the barry project
      (http://barry.sf.net)
      Signed-off-by: NJeremy Katz <katzj@redhat.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      49bb607f
    • O
      USB: autosuspend for usblcd · 7bbe990c
      Oliver Neukum 提交于
      this patch implements autosuspend for the usblcd driver. It uses
      the new usb_anchor infrastructure. Many thanks to Georges for testing.
      Signed-off-by: NOliver Neukum <oneukum@suse.de>
      Cc: Georges Toth <g.toth@e-biz.lu>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      7bbe990c
    • A
      USB: prevent char device open/deregister race · d4ead16f
      Alan Stern 提交于
      This patch (as908) adds central protection in usbcore for the
      prototypical race between opening and unregistering a char device.
      The spinlock used to protect the minor-numbers array is replaced with
      an rwsem, which can remain locked across a call to a driver's open()
      method.  This guarantees that open() and deregister() will be mutually
      exclusive.
      
      The private locks currently used in several individual drivers for
      this purpose are no longer necessary, and the patch removes them.  The
      following USB drivers are affected: usblcd, idmouse, auerswald,
      legousbtower, sisusbvga/sisusb, ldusb, adutux, iowarrior, and
      usb-skeleton.
      
      As a side effect of this change, usb_deregister_dev() must not be
      called while holding a lock that is acquired by open().  Unfortunately
      a number of drivers do this, but luckily the solution is simple: call
      usb_deregister_dev() before acquiring the lock.
      
      In addition to these changes (and their consequent code
      simplifications), the patch fixes a use-after-free bug in adutux and a
      race between open() and release() in iowarrior.
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      d4ead16f
  4. 07 7月, 2007 1 次提交
    • Y
      potential compiler error, irqfunc caller sites update · 0da2f0f1
      Yoann Padioleau 提交于
      In 7d12e780 David Howells performed
      this evolution:
       "IRQ: Maintain regs pointer globally rather than passing to IRQ handlers"
      
      He correctly updated many of the function definitions that were using this
      extra regs pointer parameter but forgot to update some caller sites of
      those functions.  The reason the modifications was not properly done on all
      drivers is that some drivers were rarely compiled because they are for
      AMIGA, or that some code sites were inside #ifdefs where the option is not
      set or inside #if 0.
      
      Here is the semantic patch that found the occurences
      and fixed the problem.
      
      @ rule1 @
      identifier fn;
      identifier irq, dev_id;
      typedef irqreturn_t;
      @@
      
      static irqreturn_t fn(int irq, void *dev_id)
      {
         ...
      }
      
      @@
      identifier rule1.fn;
      expression E1, E2, E3;
      @@
      
       fn(E1, E2
      -   ,E3
         )
      Signed-off-by: NYoann Padioleau <padator@wanadoo.fr>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jeff Garzik <jeff@garzik.org>
      Cc: Greg KH <greg@kroah.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      0da2f0f1
  5. 26 6月, 2007 2 次提交
  6. 23 5月, 2007 3 次提交
  7. 09 5月, 2007 3 次提交
  8. 28 4月, 2007 8 次提交
  9. 20 3月, 2007 1 次提交
  10. 10 3月, 2007 1 次提交
  11. 24 2月, 2007 1 次提交
  12. 20 2月, 2007 3 次提交
    • R
      backlight: Separate backlight properties from backlight ops pointers · 599a52d1
      Richard Purdie 提交于
      Per device data such as brightness belongs to the indivdual device
      and should therefore be separate from the the backlight operation
      function pointers. This patch splits the two types of data and
      allows simplifcation of some code.
      Signed-off-by: NRichard Purdie <rpurdie@rpsys.net>
      599a52d1
    • R
      backlight: Fix external uses of backlight internal semaphore · 28ee086d
      Richard Purdie 提交于
      backlight_device->sem has a very specific use as documented in the
      header file. The external users of this are using it for a different
      reason, to serialise access to the update_status() method.
      
      backlight users were supposed to implement their own internal
      serialisation of update_status() if needed but everyone is doing
      things differently and incorrectly. Therefore add a global mutex to
      take care of serialisation for everyone, once and for all.
      
      Locking for get_brightness remains optional since most users don't
      need it.
      
      Also update the lcd class in a similar way.
      Signed-off-by: NRichard Purdie <rpurdie@rpsys.net>
      28ee086d
    • R
      backlight: Remove unneeded owner field · dfcba200
      Richard Purdie 提交于
      Remove uneeded owner field from backlight_properties structure.
      
      Nothing uses it and it is unlikely that it will ever be used. The
      backlight class uses other means to ensure that nothing references
      unloaded code.
      
      Based on a patch from Dmitry Torokhov <dtor@insightbb.com>
      Signed-off-by: NRichard Purdie <rpurdie@rpsys.net>
      dfcba200
  13. 17 2月, 2007 1 次提交
    • G
      USB: Driver to charge USB blackberry devices · df23fa01
      Greg Kroah-Hartman 提交于
      A simple driver to turn on the charging capability of a USB BlackBerry
      device when it is plugged into the machine.  It does not bind to the
      device, so all userspace programs can still sync properly with it.
      
      Note, if CONFIG_USB_SUSPEND is enabled, it can play havoc with this
      device as the power to the port will be shut down.  This device id will
      have to be added to the global blacklist table when it is created.
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      df23fa01
  14. 15 2月, 2007 1 次提交
    • T
      [PATCH] remove many unneeded #includes of sched.h · cd354f1a
      Tim Schmielau 提交于
      After Al Viro (finally) succeeded in removing the sched.h #include in module.h
      recently, it makes sense again to remove other superfluous sched.h includes.
      There are quite a lot of files which include it but don't actually need
      anything defined in there.  Presumably these includes were once needed for
      macros that used to live in sched.h, but moved to other header files in the
      course of cleaning it up.
      
      To ease the pain, this time I did not fiddle with any header files and only
      removed #includes from .c-files, which tend to cause less trouble.
      
      Compile tested against 2.6.20-rc2 and 2.6.20-rc2-mm2 (with offsets) on alpha,
      arm, i386, ia64, mips, powerpc, and x86_64 with allnoconfig, defconfig,
      allmodconfig, and allyesconfig as well as a few randconfigs on x86_64 and all
      configs in arch/arm/configs on arm.  I also checked that no new warnings were
      introduced by the patch (actually, some warnings are removed that were emitted
      by unnecessarily included header files).
      Signed-off-by: NTim Schmielau <tim@physik3.uni-rostock.de>
      Acked-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      cd354f1a
  15. 13 2月, 2007 2 次提交
  16. 10 2月, 2007 1 次提交
  17. 08 2月, 2007 2 次提交
  18. 06 1月, 2007 1 次提交
    • A
      sisusb_con warning fixes · c067dfc6
      Andrew Morton 提交于
      x86_64:
      
      drivers/usb/misc/sisusbvga/sisusb_con.c: In function 'sisusbcon_putc':
      drivers/usb/misc/sisusbvga/sisusb_con.c:405: warning: cast from pointer to integer of different size
      drivers/usb/misc/sisusbvga/sisusb_con.c: In function 'sisusbcon_putcs':
      drivers/usb/misc/sisusbvga/sisusb_con.c:440: warning: cast from pointer to integer of different size
      drivers/usb/misc/sisusbvga/sisusb_con.c: In function 'sisusbcon_clear':
      drivers/usb/misc/sisusbvga/sisusb_con.c:494: warning: cast from pointer to integer of different size
      drivers/usb/misc/sisusbvga/sisusb_con.c: In function 'sisusbcon_bmove':
      drivers/usb/misc/sisusbvga/sisusb_con.c:566: warning: cast from pointer to integer of different size
      drivers/usb/misc/sisusbvga/sisusb_con.c: In function 'sisusbcon_switch':
      drivers/usb/misc/sisusbvga/sisusb_con.c:614: warning: cast from pointer to integer of different size
      drivers/usb/misc/sisusbvga/sisusb_con.c: In function 'sisusbcon_scroll_area':
      drivers/usb/misc/sisusbvga/sisusb_con.c:941: warning: cast from pointer to integer of different size
      
      Cc: Thomas Winischhofer <thomas@winischhofer.net>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      c067dfc6
  19. 21 12月, 2006 3 次提交
    • T
      USB: u132-hcd/ftdi-elan: add support for Option GT 3G Quad card · 4b87361d
      Tony Olech 提交于
      ELAN's U132 is a USB to CardBus OHCI controller adapter,
          designed specifically for CardBus 3G data cards to
          function in machines without a CardBus slot.
      The "ftdi-elan" module is a USB client driver, that detects
          a supported CardBus OHCI controller plugged into the
          U132 adapter and thereafter provides the conduit for
          for access by the "u132-hcd" module.
      The "u132-hcd" module is a (cut-down OHCI) host controller
          that supports a single OHCI function of the CardBus 
          card inserted into the U132 adapter.
      
      The problem with the initial implementation is that when
      the CardBus card inserted into the U132 adapter has multiple
      functions (and a CardBus card can support up to 4 functions),
      it was the first function that was arbitrarily choosen.
      
      The first batch of 3G cards tested, like the Merlin Qualcomm
      V620, have two functions each supporting a seperate USB OHCI
      host controller, of which it was that first function that is
      wired up to the 3G modem.
      
      Then along comes the Vodafone Mobile Connect 3G/GPRS data card,
      aka "Option GT 3G Quad" as printed on it's rear or "Option N.V.
      GlobeTrotter Fusion Quad Lite" as read with "lspci -v". And it
      has the meaningful functionality in the second CardBus function.
      
      That presents a problem because it was the "ftdi-elan" module
      alone that knows how to communicate to the embedded CardBus slot
      and the "u132-hcd" module alone that knows how to access the
      pcmcia configuration and CardBus accessible memory space. And
      of course, the information about attached (internally hardwired)
      devices is contained within USB configuration embedded somewhere
      within the CardBus card.
      
      If only the "u132-hcd" module probe() interface could return a
      result code that propagated back to the instigating function
      platform_device_register() then the "ftdi-elan" module could
      try an alternative CardBus function.     However in spite of
      the recent changes to the drivers/base/ routines that moved 
      device_attach() from bus_add_device() to bus_attach_device()
      both of those routines lose the "failed to attach" 0 result
      code and thus the calling routine, namely device_add() is
      incapable of propaging the "failed to attach" condition back
      to platform_device_add() and consequently back to the caller
      of platform_device_register()
      
      Experiments show that patching bus_attach_device() to return
      ENODEV fails with the kernel locking up very early during
      boot. But, however, if the patch is restricted to calls from
      platform_device_add() then it does seem to work.
      
      Unfortunately, until the kernel's drivers/base is properly
      modified to propagate -ENODEV back to the caller of
      platform_device_register(), it is necessary to "fix" the
      "ftdi-elan" module by importing knowledge from the 
      "u132-hcd" module. This is the reason for the duplicated
      functionality introduced in this patch.
      Signed-off-by: NTony Olech <tony.olech@elandigitalsystems.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      4b87361d
    • B
      USB AUERSWALD: replace kmalloc+memset with kzalloc · 66eb2e93
      Burman Yan 提交于
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      66eb2e93
    • O
      USB: fix transvibrator disconnect race · 96ca014d
      Oliver Neukum 提交于
      in disconnect you set the interface's private data to NULL. In your IO
      methods you unconditionally follow the pointer into never never land.
      Signed-off-by: NOliver Neukum <oliver@neukum.name>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      96ca014d