1
0
Fork 0
alistair23-linux/include
Sarah Sharp c563543784 usb: Make core allocate resources per PCI-device.
Introduce the notion of a PCI device that may be associated with more than
one USB host controller driver (struct usb_hcd).  This patch is the start
of the work to separate the xHCI host controller into two roothubs: a USB
3.0 roothub with SuperSpeed-only ports, and a USB 2.0 roothub with
HS/FS/LS ports.

One usb_hcd structure is designated to be the "primary HCD", and a pointer
is added to the usb_hcd structure to keep track of that.  A new function
call, usb_hcd_is_primary_hcd() is added to check whether the USB hcd is
marked as the primary HCD (or if it is not part of a roothub pair).  To
allow the USB core and xHCI driver to access either roothub in a pair, a
"shared_hcd" pointer is added to the usb_hcd structure.

Add a new function, usb_create_shared_hcd(), that does roothub allocation
for paired roothubs.  It will act just like usb_create_hcd() did if the
primary_hcd pointer argument is NULL.  If it is passed a non-NULL
primary_hcd pointer, it sets usb_hcd->shared_hcd and usb_hcd->primary_hcd
fields.  It will also skip the bandwidth_mutex allocation, and set the
secondary hcd's bandwidth_mutex pointer to the primary HCD's mutex.

IRQs are only allocated once for the primary roothub.

Introduce a new usb_hcd driver flag that indicates the host controller
driver wants to create two roothubs.  If the HCD_SHARED flag is set, then
the USB core PCI probe methods will allocate a second roothub, and make
sure that second roothub gets freed during rmmod and in initialization
error paths.

When usb_hc_died() is called with the primary HCD, make sure that any
roothubs that share that host controller are also marked as being dead.

Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
2011-03-13 18:23:06 -07:00
..
acpi Merge branch 'acpica' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6 2011-01-20 16:28:34 -08:00
asm-generic tracing: Replace syscall_meta_data struct array with pointer array 2011-02-03 09:29:06 -05:00
crypto crypto: padlock - Move padlock.h into include/crypto 2011-01-07 14:52:00 +11:00
drm drm/radeon: remove 0x4243 pci id 2011-02-02 12:50:41 +10:00
keys keys: add new key-type encrypted 2010-11-29 08:55:29 +11:00
linux usb: Make core allocate resources per PCI-device. 2011-03-13 18:23:06 -07:00
math-emu
media [media] v4l: Include linux/videodev2.h in media/v4l2-ctrls.h 2011-01-19 11:52:09 -02:00
mtd
net include/net/genetlink.h: Allow genlmsg_cancel to accept a NULL argument 2011-02-03 20:47:08 -08:00
pcmcia
rdma RDMA: Update workqueue usage 2011-01-16 21:16:31 -08:00
rxrpc
scsi [SCSI] fix incorrect value of SCSI_MAX_SG_CHAIN_SEGMENTS due to include file ordering 2011-01-24 11:49:34 -06:00
sound ALSA: constify functions in ac97 2011-01-14 19:14:47 +01:00
target [SCSI] target: Add LIO target core v4.0.0-rc6 2011-01-14 10:12:29 -06:00
trace tracing: Replace trace_event struct array with pointer array 2011-02-02 21:37:13 -05:00
video Merge branch 'fbdev/udlfb' 2011-01-06 18:10:09 +09:00
xen Merge branch 'stable/gntdev' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen 2011-01-13 18:46:48 -08:00
Kbuild