1. 14 10月, 2007 1 次提交
    • P
      lockdep: annotate dir vs file i_mutex · 14358e6d
      Peter Zijlstra 提交于
      On Mon, 2007-09-24 at 22:13 -0400, Steven Rostedt wrote:
      > The circular lock seems to be this:
      > 
      > #1:
      > 
      >   sys_mmap2:              down_write(&mm->mmap_sem);
      >   nfs_revalidate_mapping: mutex_lock(&inode->i_mutex);
      > 
      > 
      > #0:
      > 
      >   vfs_readdir:     mutex_lock(&inode->i_mutex);
      >    - during the readdir (filldir64), we take a user fault (missing page?)
      >     and call do_page_fault -
      >   do_page_fault:   down_read(&mm->mmap_sem);
      > 
      > 
      > So it does indeed look like a circular locking. Now the question is, "is
      > this a bug?".  Looking like the inode of #1 must be a file or something
      > else that you can mmap and the inode of #0 seems it must be a directory.
      > I would say "no".
      > 
      > Now if you can readdir on a file or mmap a directory, then this could be
      > an issue.
      > 
      > Otherwise, I'd love to see someone teach lockdep about this issue! ;-)
      
      Make a distinction between file and dir usage of i_mutex.
      The inode should be complete and unused at unlock_new_inode(), re-init
      i_mutex depending on its type.
      Signed-off-by: NPeter Zijlstra <a.p.zijlstra@chello.nl>
      14358e6d
  2. 15 10月, 2007 1 次提交
  3. 12 10月, 2007 4 次提交
  4. 15 10月, 2007 5 次提交
  5. 14 10月, 2007 13 次提交
    • 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
    • K
      Input: add KEY_LOGOFF · e2bca074
      Khelben Blackstaff 提交于
      HUT 1.12 defines Logoff usage 0x19c in Consumer page. There are
      keyboards out there emitting this usage code (for example Microsoft
      Wireless Laser Keyboard 6000). Add this key so that HID code could
      map usages to it.
      Signed-off-by: NKhelben Blackstaff <eye.of.the.8eholder@gmail.com>
      Signed-off-by: NDmitry Torokhov <dtor@mail.ru>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      e2bca074
    • T
      USBHID: report descriptor fix for MacBook JIS keyboard · 08f06177
      Tomoya Adachi 提交于
      This patch fixes the problem, that Japanese MacBook doesn't recognize some keys
      like '\'(yen, or backslash), '|'(pipe), and '_'(underscore).
      
      It is due to that MacBook JIS keyboard (jp106) sends wrong report descriptor.
      It saids "logical maximum = 0x65", so Keyboard.0089 is mapped to Key.Unknown,
      while it should be accepted as Key.Yen.
      Signed-off-by: NTomoya Adachi <adachi@il.is.s.u-tokyo.ac.jp>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      08f06177
    • S
      HID: enable hiddev for the SantaRosa MacBookPro IR receiver · 0ce91cf9
      Stelian Pop 提交于
      The infrared remote receiver found in the SantaRosa MacBookPro
      laptops (MacBookPro3,1) need to be forced to expose a HIDDEV
      interface (instead of HIDINPUT) so that lirc can access it using
      the 'macmini' driver.
      
      The patch below adds the required quirk for forcing the HIDDEV
      interface to be activated (HID_QUIRK_HIDDEV) and introduces a new
      quirk which forces the HIDINPUT interface to be ignored
      (HID_QUIRK_IGNORE_HIDINPUT).
      
      Note that Apple calls this receiver 'IRController4' (info taken
      from Apple's driver Info.plist). Older Mac{Book,Mini,Pro}s seem
      to all use the 'IRController1' device (USB id 05ac:8240) which
      doesn't need those quirks.
      Signed-off-by: NStelian Pop <stelian@popies.net>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      0ce91cf9
    • J
      Input: add KEY_SPELLCHECK · 4dc21a80
      Jiri Kosina 提交于
      HUT 1.12 defines Spell Check usage 0x1ab in Consumer page. There are
      keyboards out there emitting this usage code (for example Microsoft
      Natural Ergonomic Keyboard 4000). Add this key so that HID code could
      map usages to it.
      Acked-by: NDmitry Torokhov <dtor@mail.ru>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      4dc21a80
    • D
      i2c: Rename the PEC functionality bit · 6662cbb9
      David Brownell 提交于
      Rename I2C_FUNC_SMBUS_HWPEC_CALC as I2C_FUNC_SMBUS_PEC, and list that
      functionality as always available through the software implementation.
      Update documentation accordingly (and list similar requirements).
      
      The way it's currently packaged doesn't present the capability in a
      useful way.
      Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      6662cbb9
    • D
      i2c: Move i2c-dev interfaces to i2c-dev.h · 08fb68bb
      David Brownell 提交于
      Move the i2c-dev support into <linux/i2c-dev.h> where it should always
      have lived.  Now <linux/i2c.h> no longer holds stuff related to the
      optional userspace /dev/i2c-X interface.  Improve the descriptions
      for these ioctl requests.
      Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      08fb68bb
    • D
      i2c: Remove i2c_algorithm.algo_control() · 53be7959
      David Brownell 提交于
      This removes:
      
       - An effectively unused hook:  i2c_algorithm.algo_control.
      
       - The i2c_control() call, used only by i2c-dev to call that
         unused hook or set two barely supported adapter params.
      
         (That param setting moves into i2c-dev.c ... still iffy
         due to lack of locking, but no other changes.)
      
      As shown by diffstat, this is a net code shrink.  It also reduces the
      complexity of the I2C adapter and /dev interfaces.
      Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      53be7959
    • D
      i2c: Document struct i2c_msg · a64ec07d
      David Brownell 提交于
      Clarify use of the I2C_M_* flags by highlighting the fact that
      most of them depend on I2C_FUNC_PROTOCOL_MANGLING.
      
      Also provide kerneldoc for i2c_smbus_read_block_data() and also
      for "struct i2c_msg".
      Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      a64ec07d
    • A
      i2c-core: Make some code static · 83eaaed0
      Adrian Bunk 提交于
      After the i2c-isa removal some code can become static.
      Signed-off-by: NAdrian Bunk <bunk@stusta.de>
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      83eaaed0
    • D
      i2c: New-style devices can support driver model wakeup flags · 3bbb835d
      David Brownell 提交于
      We need to be able to flag I2C devices, such as RTCs, which can issue wake
      events (usually through IRQ lines).  This adds an i2c_board_info.flags bit,
      and uses it to initialize the i2c device node.  (And shrinks a few lines
      that were overly long.)
      Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      3bbb835d
    • J
      i2c: Kill struct i2c_device_id · cee37ae4
      Jean Delvare 提交于
      I2C devices do not have any form of ID as PCI or USB devices have.
      No driver uses "MODULE_DEVICE_TABLE(i2c, ...)" because it doesn't
      make sense. So we can get rid of struct i2c_device_id and the
      associated support code.
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      Cc: Greg KH <greg@kroah.com>
      cee37ae4
    • R
      net core: fix kernel-doc for new function parameters · c4ea43c5
      Randy Dunlap 提交于
      Fix networking code kernel-doc for newly added parameters.
      
      Warning(linux-2.6.23-git2//net/core/sock.c:879): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//net/core/dev.c:570): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//net/core/dev.c:594): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//net/core/dev.c:617): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//net/core/dev.c:641): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//net/core/dev.c:667): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//net/core/dev.c:722): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//net/core/dev.c:959): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//net/core/dev.c:1195): No description found for parameter 'dev'
      Warning(linux-2.6.23-git2//net/core/dev.c:2105): No description found for parameter 'n'
      Warning(linux-2.6.23-git2//net/core/dev.c:3272): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//net/core/dev.c:3445): No description found for parameter 'net'
      Warning(linux-2.6.23-git2//include/linux/netdevice.h:1301): No description found for parameter 'cpu'
      Signed-off-by: NRandy Dunlap <randy.dunlap@oracle.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      c4ea43c5
  6. 13 10月, 2007 16 次提交