1. 14 10月, 2007 2 次提交
    • J
      HID: add hidraw interface · 86166b7b
      Jiri Kosina 提交于
      hidraw is an interface that is going to obsolete hiddev one
      day.
      
      Many userland applications are using libusb instead of using
      kernel-provided hiddev interface. This is caused by various
      reasons - the HID parser in kernel doesn't handle all the
      HID hardware on the planet properly, some devices might require
      its own specific quirks/drivers, etc.
      
      hiddev interface tries to do its best to parse all the received
      reports properly, and presents only parsed usages into userspace.
      This is however often not enough, and that's the reason why
      many userland applications just don't use hiddev at all, and
      rather use libusb to read raw USB events and process them on
      their own.
      
      Another drawback of hiddev is that it is USB-specific.
      
      hidraw interface provides userspace readers with really raw HID
      reports, no matter what the low-level transport layer is (USB/BT),
      and gives the userland applications all the freedom to process
      the HID reports in a way they wish to.
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      86166b7b
    • J
      USB HID: provide hook for hidraw write() · efc493f9
      Jiri Kosina 提交于
      Add hook in usbhid for write() callback from hidraw. Sends the
      report to the device through control pipe.
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      efc493f9
  2. 02 8月, 2007 3 次提交
  3. 13 7月, 2007 2 次提交
    • A
      USB: add reset_resume method · f07600cf
      Alan Stern 提交于
      This patch (as918) introduces a new USB driver method: reset_resume.
      It is called when a device needs to be reset as part of a resume
      procedure (whether because of a device quirk or because of the
      USB-Persist facility), thereby taking over a role formerly assigned to
      the post_reset method.  As a consequence, post_reset no longer needs
      an argument indicating whether it is being called as part of a
      reset-resume.  This separation of functions makes the code clearer.
      
      In addition, the pre_reset and post_reset method return types are
      changed; they now must return an error code.  The return value is
      unused at present, but at some later time we may unbind drivers and
      re-probe if they encounter an error during reset handling.
      
      The existing pre_reset and post_reset methods in the usbhid,
      usb-storage, and hub drivers are updated to match the new
      requirements.  For usbhid the post_reset routine is also used for
      reset_resume (duplicate method pointers); for the other drivers a new
      reset_resume routine is added.  The change to hub.c looks bigger than
      it really is, because mark_children_for_reset_resume() gets moved down
      next to the new hub_reset_resume() routine.
      
      A minor change to usb-storage makes the usb_stor_report_bus_reset()
      routine acquire the host lock instead of requiring the caller to hold
      it already.
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      CC: Matthew Dharm <mdharm-usb@one-eyed-alien.net>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      
      f07600cf
    • A
      USB: add USB-Persist facility · 0458d5b4
      Alan Stern 提交于
      This patch (as886) adds the controversial USB-persist facility,
      allowing USB devices to persist across a power loss during system
      suspend.
      
      The facility is controlled by a new Kconfig option (with appropriate
      warnings about the potential dangers); when the option is off the
      behavior will remain the same as it is now.  But when the option is
      on, people will be able to use suspend-to-disk and keep their USB
      filesystems intact -- something particularly valuable for small
      machines where the root filesystem is on a USB device!
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      0458d5b4
  4. 09 7月, 2007 4 次提交
    • J
      HID: separate quirks for report descriptor fixup · ea9a4a8b
      Jiri Kosina 提交于
      Lately there have been quite a lot of bug reports against broken devices
      which require us to fix their report descriptor in the runtime, before it
      is passed to the HID parser. Those devices have eaten quite an amount of
      our quirks space, which isn't particularly necessary - the quirks are not
      needed after the report descriptor is parsed, and they just consume bits.
      
      Therefore this patch separates the quirks for report descriptor fixup, and
      moves their handling into separate code. The quirks are then forgotten as
      soon as the report descriptor has been parsed.
      
      Module parameter 'rdesc_quirks' is introduced to be able to modify these
      quirks in runtime in a similar way to 'quirks' parameter for ordinary HID
      quirks.
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      ea9a4a8b
    • J
      HID: support for Petalynx Maxter remote control · 92d9e6e6
      Jiri Kosina 提交于
      Petalynx Maxter remote control [1] 0x18b1/0x0037 emits 0xfa and 0xfc from
      consumer page (reserved in HUT 1.12) for back and more keys. It also emits
      a few usages from LOGIVENDOR page, which need adding.
      
      Also, this device has broken report descriptor - the reported maximum is too
      low - it doesn't contain the range for 'back' and 'more' keys, so we need to
      bump it up before the report descriptor is being parsed.
      
      Besides all this, it also requires NOGET quirk.
      
      This patch does so.
      
      [1] http://www.elmak.pl/index.php?option=com_phpshop&page=shop.browse&category_id=14&ext=opis&lang=enSigned-off-by: NJiri Kosina <jkosina@suse.cz>
      92d9e6e6
    • A
      USB HID: avoid flush_scheduled_work() · 2fa45a4c
      Alan Stern 提交于
      This patch (as914) replaces a call to flush_scheduled_work() with
      cancel_work_sync(), in order to help avoid potential deadlocks.
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      2fa45a4c
    • J
      HID: make debugging output runtime-configurable · 58037eb9
      Jiri Kosina 提交于
      There have been many reports recently about broken HID devices, the
      diagnosis of which required users to recompile their kernels in order
      to be able to provide debugging output needed for coding a quirk for
      a particular device.
      
      This patch makes CONFIG_HID_DEBUG default y if !EMBEDDED and makes it
      possible to control debugging output produced by HID code by supplying
      'debug=1' module parameter.
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      58037eb9
  5. 09 5月, 2007 3 次提交
  6. 19 4月, 2007 2 次提交
  7. 18 4月, 2007 1 次提交
  8. 16 4月, 2007 1 次提交
  9. 11 4月, 2007 9 次提交
  10. 02 3月, 2007 1 次提交
  11. 01 3月, 2007 4 次提交
    • J
      HID: fix Logitech DiNovo Edge touchwheel and Logic3 /SpectraVideo middle button · 25914662
      Jiri Kosina 提交于
      Dongle shipped with Logitech DiNovo Edge (0x046d/0xc714) behaves in a weird
      non-standard way - it contains multiple reports with the same usage, which
      results in remapping of GenericDesktop.X and GenericDesktop.Y usages to
      GenericDesktop.Z and GenericDesktop.RX respectively, thus rendering the
      touchwheel unusable.
      
      The commit 35068976 solved this
      in a way that it didn't remap certain usages. This however breaks
      (at least) middle button of Logic3 / SpectraVideo (0x1267/0x0210),
      which in contrary requires the remapping.
      
      To make both of the harware work, allow remapping of these usages again,
      and introduce a quirk for Logitech DiNovo Edge "touchwheel" instead - we
      disable remapping for key, abs and rel events only for this hardware.
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      25914662
    • J
      HID: fix broken Logitech S510 keyboard report descriptor; make extra keys work · b55fd23c
      Jiri Kosina 提交于
      This patch makes extra keys (F1-F12 in special mode, zooming, rotate, shuffle)
      on Logitech S510 keyboard work.
      
      Logitech S510 keyboard sends in report no. 3 keys which are far above the
      logical maximum described in descriptor for given report.
      
      This patch introduces a HID quirk for this wireless USB receiver/keyboard
      in order to fix the report descriptor before it's being parsed - the logical
      maximum and the number of usages is bumped up to 0x104d). The values are in the
      "Reserved" area of consumer HUT, so HID_MAX_USAGE had to be changed too.
      
      In addition to proper extracting of  the values from report descriptor, proper
      HID-input mapping is introduced for them.
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      b55fd23c
    • J
      USB HID: use CONFIG_HID_DEBUG for outputting report descriptor · fdc9c566
      Jiri Kosina 提交于
      Report descriptor should be output when CONFIG_HID_DEBUG is defined.
      
      This also mitigates the need for DEBUG and DEBUG_DATA defines, so let's
      remove them.
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      fdc9c566
    • J
      USB HID: Fix USB vendor and product IDs endianness for USB HID devices · 9fa2ad5f
      Julien BLACHE 提交于
      The USB vendor and product IDs are not byteswapped appropriately, and
      thus come out in the wrong endianness when fetched through the evdev
      using ioctl() on big endian platforms.
      Signed-off-by: NJulien BLACHE <jb@jblache.org>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      9fa2ad5f
  12. 17 2月, 2007 2 次提交
  13. 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
  14. 08 2月, 2007 1 次提交
  15. 05 2月, 2007 4 次提交