Files
kernel-tenderloin-3.0/drivers/usb
Stephen Boyd 431771e568 USB: OTG: msm: Fix inconsistent lockdep state warning
=================================
[ INFO: inconsistent lock state ]
3.0.21-g51ce160-00021-g8b33780-dirty #2904
---------------------------------
inconsistent {IN-HARDIRQ-W} -> {HARDIRQ-ON-W}

kworker/0:1/32 [HC0[0]:SC0[0]:HE1:SE1] takes:
 (&irq_desc_lock_class){?.....}, at: [<c01cfd10>] irq_read_line+0x3c/0x80
{IN-HARDIRQ-W} state was registered at:
  [<c01b8768>] __lock_acquire+0x704/0x9f8
  [<c01b9034>] lock_acquire+0x10c/0x130
  [<c0833ac8>] _raw_spin_lock+0x44/0x54
  [<c01d1c30>] handle_fasteoi_irq+0x14/0x108
  [<c01ce8ac>] generic_handle_irq+0x28/0x3c
  [<c0106f6c>] handle_IRQ+0x7c/0xc0
  [<c0100458>] gic_handle_irq+0xac/0x104
  [<c0834798>] __irq_svc+0x58/0x8c
  [<c01070b4>] default_idle+0x28/0x2c
  [<c010742c>] cpu_idle+0x8c/0xf4
  [<c0808ddc>] rest_init+0xd8/0x100
  [<c0008a90>] start_kernel+0x464/0x4d8
  [<8020803c>] 0x8020803c

other info that might help us debug this:
 Possible unsafe locking scenario:

       CPU0
       ----
  lock(&irq_desc_lock_class);
  <Interrupt>
    lock(&irq_desc_lock_class);

 *** DEADLOCK ***

2 locks held by kworker/0:1/32:
 #0:  (events_nrt){.+.+..}, at: [<c019c49c>] process_one_work+0x1f8/0x518
 #1:  ((&motg->sm_work)){+.+...}, at: [<c019c49c>] process_one_work+0x1f8/0x518

stack backtrace:
[<c010c798>] (unwind_backtrace+0x0/0x12c) from [<c01b53bc>]
[<c01b53bc>] (print_usage_bug+0x248/0x2ac) from [<c01b5804>]
[<c01b5804>] (mark_lock+0x3e4/0x6ec) from [<c01b87f4>]
[<c01b87f4>] (__lock_acquire+0x790/0x9f8) from [<c01b9034>]
[<c01b9034>] (lock_acquire+0x10c/0x130) from [<c0833ac8>]
[<c0833ac8>] (_raw_spin_lock+0x44/0x54) from [<c01cfd10>]
[<c01cfd10>] (irq_read_line+0x3c/0x80) from [<c04e79b8>]
[<c04e79b8>] (msm_otg_sm_work+0x1a0/0x1510) from [<c019c57c>]
[<c019c57c>] (process_one_work+0x2d8/0x518) from [<c019cb94>]
[<c019cb94>] (worker_thread+0x220/0x3a0) from [<c01a2a80>]
[<c01a2a80>] (kthread+0x88/0x94) from [<c0107008>]

Change-Id: I7966d183cad54758508cb9635ebe3f31fba408b9
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
2012-04-23 15:52:03 -07:00
..
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00

To understand all the Linux-USB framework, you'll use these resources:

    * This source code.  This is necessarily an evolving work, and
      includes kerneldoc that should help you get a current overview.
      ("make pdfdocs", and then look at "usb.pdf" for host side and
      "gadget.pdf" for peripheral side.)  Also, Documentation/usb has
      more information.

    * The USB 2.0 specification (from www.usb.org), with supplements
      such as those for USB OTG and the various device classes.
      The USB specification has a good overview chapter, and USB
      peripherals conform to the widely known "Chapter 9".

    * Chip specifications for USB controllers.  Examples include
      host controllers (on PCs, servers, and more); peripheral
      controllers (in devices with Linux firmware, like printers or
      cell phones); and hard-wired peripherals like Ethernet adapters.

    * Specifications for other protocols implemented by USB peripheral
      functions.  Some are vendor-specific; others are vendor-neutral
      but just standardized outside of the www.usb.org team.

Here is a list of what each subdirectory here is, and what is contained in
them.

core/		- This is for the core USB host code, including the
		  usbfs files and the hub class driver ("khubd").

host/		- This is for USB host controller drivers.  This
		  includes UHCI, OHCI, EHCI, and others that might
		  be used with more specialized "embedded" systems.

gadget/		- This is for USB peripheral controller drivers and
		  the various gadget drivers which talk to them.


Individual USB driver directories.  A new driver should be added to the
first subdirectory in the list below that it fits into.

image/		- This is for still image drivers, like scanners or
		  digital cameras.
../input/	- This is for any driver that uses the input subsystem,
		  like keyboard, mice, touchscreens, tablets, etc.
../media/	- This is for multimedia drivers, like video cameras,
		  radios, and any other drivers that talk to the v4l
		  subsystem.
../net/		- This is for network drivers.
serial/		- This is for USB to serial drivers.
storage/	- This is for USB mass-storage drivers.
class/		- This is for all USB device drivers that do not fit
		  into any of the above categories, and work for a range
		  of USB Class specified devices. 
misc/		- This is for all USB device drivers that do not fit
		  into any of the above categories.