Age | Commit message (Collapse) | Author |
|
Enable RNDIS for Android Platform. Also provide the runtime configuration
binding as Microsoft driver doesn't support the RNDIS in composite mode
Also make the Class, SubClass and Protocol of IAD same as that of first
interface as mentioned in the specification.
ST-Ericsson ID: CR 272413
Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com>
Signed-off-by: Ajay Jawade <ajay.jawade@stericsson.com>
|
|
Removing AB8500 1.0 and 1.1 support and the VUSB regulator is
a requirement to complete the ER stated below.
ST-Ericsson Linux next: -
ST-Ericsson ID: ER 327257
ST-Ericsson FOSS-OUT ID: Trivial
Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com>
Signed-off-by: Bengt Jonsson <bengt.g.jonsson@stericsson.com>
|
|
When ceiling and changing the page code values the performance of mass storage is affected.
To achieve faster write operation removing ceiling and changing of page code values
ST-Ericsson ID : 283277
Change-Id: I16792c07011c46d3775278d1836d78af9830b2dc
Signed-off-by: rajaram <rajaram.ragupathy@stericsson.com>
Conflicts:
drivers/usb/gadget/f_mass_storage.c
Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com>
|
|
Changing the resume_noirq call to resume call so that suspend/resume is paired
and we will have a stable USB power save.
ST-Ericsson ID: ER 280150
Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com>
|
|
According to USB compliance, USB device can be self or bus powered
based on the power it consumes from the Host. This patch adds the
check before setting the device to self-powered.
ST-Ericsson ID: 268507
Signed-off-by: Praveena Nadahally <praveen.nadahally@stericsson.com>
Change-Id: I1241ba724ef00e782c527f95981b8011cf3479f8
Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/11983
Reviewed-by: QATOOLS
Reviewed-by: Srinidhi KASAGAR <srinidhi.kasagar@stericsson.com>
Conflicts:
drivers/usb/gadget/android.c
|
|
Merging patch from gerrit id 6301
The patches enables hardware double buffering support for endpoint to
enable Massstorage improve performance.
Signed-off-by: sidhartk <sidhartha.kalra@stericsson.com>
Change-Id: Ic5d1a4e5a17898b0eb90947a1bc3bb8f2d26f79c
Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/8759
Reviewed-by: Srinidhi KASAGAR <srinidhi.kasagar@stericsson.com>
|
|
Wake Lock implemented in Host handler, in enable/disable physical layer
Signed-off-by: Philippe Langlais <philippe.langlais@stericsson.com>
|
|
..linux-linaro-3.0-2011.07-1_glk3.0
Conflicts:
arch/arm/common/Makefile
drivers/misc/Kconfig
drivers/misc/Makefile
kernel/printk.c
Change-Id: I126f34edb1879981909072beefb2738cad26f951
|
|
GPIO alternate configuration is set when the USB is
connected and reset at USB disconnect.
Change-Id: I07d9c2ed5028879ecff309aa9e4ac25deac148f5
Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com>
Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/27203
Reviewed-by: QATOOLS
Reviewed-by: Praveena NADAHALLY <praveen.nadahally@stericsson.com>
Reviewed-by: Philippe LANGLAIS <philippe.langlais@stericsson.com>
|
|
AB V2 has eye diagram issues when drawing more than 100mA
from VBUS.So setting charging current to 100mA in case of standard host
Change-Id: Iaa5eb5751a4b0665fbe6f6148b712ffa9f96a06b
Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com>
Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/25958
Reviewed-by: Praveena NADAHALLY <praveen.nadahally@stericsson.com>
Reviewed-by: Philippe LANGLAIS <philippe.langlais@stericsson.com>
|
|
During dedicated charger disconnect, (USB PHY enable - delay -
disable) sequence is no longer done for platforms using ABv3.
This sequence was done for ABv2 to have multiple dedicated charger
detection working.
Change-Id: Id27e8f0da9ad65c9ae692048c162402453e18592
Signed-off-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com>
Signed-off-by: dushyanth.sr <dushyanth.sr@stericsson.com>
Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/25191
Reviewed-by: Philippe LANGLAIS <philippe.langlais@stericsson.com>
|
|
Signed-off-by: Lee Jones <lee.jones@linaro.org>
|
|
Signed-off-by: Robert Marklund <robert.marklund@stericsson.com>
|
|
This patch updates the PRCMU driver API to be the same
(as far as possible) in U8500 and U4500.
- <mach/prcmu-fw-api.h> has been renamed <mach/prcmu.h>.
- The platform specific APIs have moved to <mach/prcmu-db5500.h>
and <mach/prcmu-db8500.h> (but these should not be directly
included).
- The PRCMU QoS API has been put in <mach/prcmu-qos.h>.
ST Ericsson ID: 334772
ST Ericsson FOSS-OUT ID: trivial
ST Ericsson Linux next: 318371
Change-Id: I6ce117ec35ebf2e987178ccacce09afb554d2736
Signed-off-by: Mattias Nilsson <mattias.i.nilsson@stericsson.com>
Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/23863
Reviewed-by: Jonas ABERG <jonas.aberg@stericsson.com>
|
|
missed TXPKTRDY check.
FIFOFLUSH is broken when a real packet is in the FIFO. This
hardware feature only works when the FIFO is empty.
The workaround described requires limiting the maximum
number of USB devices to 126, 128 - 2.
Signed-off-by: Hans Petter Selasky <hans.petter.selasky@stericsson.com>
Signed-off-by: Praveena Nadahally <praveen.nadahally@stericsson.com>
Acked-by: Linus Walleij <linus.walleij@stericsson.com>
|
|
Signed-off-by: Mian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com>
|
|
Changes to the state made here conflicts with the changes made within the usb
controller driver
usb: otg: ab8500-usb: split phy_control into separate enable and disable functions
Preparing to add clocks, regulators and qos control
usb: otg: ab8500-usb: update interrupt registrations and handlers
Ab8500 v1 and v2 both do not update link status unless phy is disabled. This
patch adds host disconnect and peripheral disconnect interrupts for v2 as well.
Interrupts handlers are thus renamed to reflect this change. Interrupts setup
functions are combined into one as now there are common interrupts for v1 and
v2.
usb: otg: ab8500-usb: only disable previously enabled phy
Keep track of the transceiver mode only disable the mode which was previously
enabled.
usb: otg: ab8500-usb: add transceiver clock control
usb: otg: ab8500-usb: add power supply control
usb: otg: ab8500-usb: add platform quality of service hooks
usb: otg: ab8500-usb: update log message and add chip revision
usb: otg: ab8500-usb: workaround for multiple connection detection
This patch implements fix for ab8500 chip v2 bug # 31952
usb: otg: ab8500-usb: return correct error status in irq setup
Rreturn correct error status if platform_get_irq_byname() fails
Reported-by: Philippe Langlais <philippe.langlais@stericsson.com>
usb: otg: ab8500-usb: fix unbalanced clock and regulator disable warnings
To prevent clock and regulator frameworks from complaining, only disable the
host or peripheral phy if they were enabled.
Reported-by: Sakethram Bommisetti <sakethram.bommisetti@stericsson.com>
Signed-off-by: Mian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com>
|
|
Signed-off-by: Mian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com>
|
|
Mass-storage and file-storage gadgets align the length to maximum-packet-size
when preparing the request to receive CBW. This is unnecessary and prevents the
controller driver from knowing that a short-packet is expected.
It is incorrect to set short_not_ok when preparing the request to receive CBW.
CBW will be a short-packet so short_not_ok must not be set.
This patch makes bh->bulk_out_intended_length unnecessary so it is also removed.
Signed-off-by: Mian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com>
|
|
Although U8500 and U5500 platforms use paltform dma, Inventra dma specific code
can work for them for the most part. Only difference is for the Rx path where
this patch is making use of request->short_not_ok to select dma mode.
usb: musb: ux500: add dma name for ux500
usb: musb: ux500: add dma glue layer for ux500
DMA is mainly intended for mass storage class. Unaligned sizes and buffers
are not supported.
usb: musb: ux500: add configuration and build options for ux500 dma
usb: musb: clear AUTOSET while clearing DMAENAB
On the completion of tx dma, dma is disabled by clearing MUSB_TXCSR_DMAENAB in
TXCSR. If MUSB_TXCSR_AUTOSET was set in txstate() it will remain set although
it is not needed in PIO mode. Clear it as soon as it is not needed.
usb: musb: ux500: copy dma mask from platform device to musb device
musb code checks dma mask before calling dma hooks.
usb: musb: do not release dma channel on channel_program failure
Musb hcd releases dma channel (hw_ep->tx_channel / hw_ep->rx_channel ) if
->channel_program() fails. A null hw_ep->tx_channel is then used to continue
the transfer in pio mode. Next call to musb_ep_program() will try to allocate
the dma channel again.
This patch allows the transfer to continue in pio mode if ->channel_program()
fails without releasing the dma channel.
usb: musb: restore rxcsr on channel_program failure
Rxcsr is configured for dma transfer before calling ->channel_program().
Restore rxcsr if ->channel_program() fails.
usb: musb: ux500: enable host side dma support
Host side dma support for ux500 is enabled by piggybacking on Inventra dma
support.
Signed-off-by: Mian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com>
|
|
I've recently run across an "Unhandled fault: imprecise external abort"
oops that is caused when a driver called usb_gadget_connect() when there
was no cable plugged into the musb gadget port.
You can see the oops message here:
https://launchpadlibrarian.net/75635123/minicom.txt
Doing some digging, it seemed the problem was triggered when reading
from the musb registers in musb_pullup() when the device controller is
powered down.
Looking at other examples of where the registers were accessed, I
noticed they were always enclosed by pm_runtime_get/put calls. So I
added such calls to the musb_gadget_pullup() function and it seemed to
resolve the problem.
Now, full disclosure: this was triggered with the out-of-tree Android
adb gadget driver. However, I suspect the same behavior could be
triggered using the composite gadget driver as well, so I think this is
a generic issue. However, if I'm wrong, let me know and I'll try to make
sure the fix is done in the right place.
If this is the right fix, it probably should be queued for 3.1 and
3.0-stable.
Comments and feedback would be greatly appreciated!
Reported-by: Zach Pfeffer <zach.pfeffer@linaro.org>
Signed-off-by: John Stultz <john.stultz@linaro.org>
|
|
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
The composite driver no longer sends setup requests to functions if the
destination is USB_RECIP_DEVICE, so we need to handle the requests
here instead of the function's setup callback.
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
MTP_SEND_FILE_WITH_HEADER ioctl allows sending a file with the 12 byte header
prepended at the beginning.
This is to allow MTP to use a single packet for the data phase instead of two.
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
Add a otg_id notifier to allow multiple drivers to cooperate to
determine the type of cable connected to a USB connector without
requiring direct calls between the drivers.
Change-Id: Ic5675f1a89daf85b17336765de24e4bdb6df6348
Signed-off-by: Colin Cross <ccross@android.com>
|
|
|
|
Commit e534c5b831c8b8e9f5edee5c8a37753c808b80dc (USB: fix regression
occurring during device removal) didn't go far enough. It failed to
take into account that when a driver claims multiple interfaces, it may
release them all at the same time. As a result, some interfaces can
get released before they are unregistered, and we deadlock trying to
acquire the bandwidth_mutex that we already own.
This patch (asl478) handles this case by setting the "unregistering"
flag on all the interfaces before removing any of them.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Cc: stable <stable@kernel.org>
Tested-by: Éric Piel <eric.piel@tremplin-utc.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
Enabled by default, can disable with:
echo N > /sys/module/otg_wakelock/parameters/enabled
Change-Id: I34974624c52ae23490852b44c270d2f326cf6116
Signed-off-by: Todd Poynor <toddpoynor@google.com>
|
|
This patch (as1476) fixes a regression introduced by
fccf4e86200b8f5edd9a65da26f150e32ba79808 (USB: Free bandwidth when
usb_disable_device is called). usb_disconnect() grabs the
bandwidth_mutex before calling usb_disable_device(), which calls down
indirectly to usb_set_interface(), which tries to acquire the
bandwidth_mutex.
The fix causes usb_set_interface() to return early when it is called
for an interface that has already been unregistered, which is what
happens in usb_disable_device().
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Tested-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
Commit 09ba0def (USB: fsl_udc_core: prepare for SoCs with
BE registers and descriptors) introduced build breakage
on ARM arch. Fix it by setting accessors using a static
inline function which is a nop when compiling the driver
for ARM arch.
Commit 2ea6698 (USB: fsl_udc_core: support device mode of
MPC5121E DR USB Controller) caused another breakage on ARM
by using flush_dcache_range(). Don't use it, convert to the
DMA API usage instead. USB2.0CV Halt Endpoint Test succeeds
on PPC. Tested both on ARM i.MX31 and mpc5121 PPC, also with
CONFIG_DMA_API_DEBUG enabled.
Signed-off-by: Anatolij Gustschin <agust@denx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
|
|
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6
* 'usb-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6:
MAINTAINERS: add myself as maintainer of USB/IP
usb: r8a66597-hcd: fix cannot detect low/full speed device
USB: ehci-ath79: fix a NULL pointer dereference
USB: Add new FT232H chip to drivers/usb/serial/ftdi_sio.c
usb/isp1760: Fix bug preventing the unlinking of control urbs
USB: Fix up URB error codes to reflect implementation.
xhci: Always set urb->status to zero for isoc endpoints.
xhci: Add reset on resume quirk for asrock p67 host
xHCI 1.0: Incompatible Device Error
USB: don't let errors prevent system sleep
USB: don't let the hub driver prevent system sleep
USB: change maintainership of ohci-hcd and ehci-hcd
xHCI 1.0: Force Stopped Event(FSE)
xhci: Don't warn about zeroed bMaxBurst descriptor field.
USB: Free bandwidth when usb_disable_device is called.
xhci: Reject double add of active endpoints.
USB: TI 3410/5052 USB Serial Driver: Fix mem leak when firmware is too big.
usb: musb: gadget: clear TXPKTRDY flag when set FLUSHFIFO
usb: musb: host: compare status for negative error values
|
|
This controller can control "Transaction Translators", but
the hcd->has_tt is not set.
Since the commit d199c96d41d80a567493e12b8e96ea056a1350c1
("USB: prevent buggy from crashing the USB stack") has checked it,
the driver could not work the low/full speed device.
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
Loading the ehci-hcd module on the ath79 platform causes
a NULL pointer dereference:
CPU 0 Unable to handle kernel paging request at virtual address 00000000, epc == c0252928, ra == c00de968
Oops[#1]:
Cpu 0
$ 0 : 00000000 00000070 00000001 00000000
$ 4 : 802cf870 0000117e ffffffff 8019c7bc
$ 8 : 0000000a 00000002 00000001 fffffffb
$12 : 8026ef20 0000000f ffffff80 802dad3c
$16 : 8077a2d4 8077a200 c00f3484 8019ed84
$20 : c00f0000 00000003 000000a0 80262c2c
$24 : 00000002 80079da0
$28 : 80788000 80789c80 80262b14 c00de968
Hi : 00000000
Lo : b61f0000
epc : c0252928 __mod_vermagic5+0xc260/0xc7e8 [ehci_hcd]
Not tainted
ra : c00de968 usb_add_hcd+0x2a4/0x858 [usbcore]
Status: 1000c003 KERNEL EXL IE
Cause : 00800008
BadVA : 00000000
PrId : 00019374 (MIPS 24Kc)
Modules linked in: ehci_hcd(+) pppoe pppox ipt_REJECT xt_TCPMSS ipt_LOG
xt_comment xt_multiport xt_mac xt_limit iptable_mangle iptable_filte
r ip_tables xt_tcpudp x_tables ppp_async ppp_generic slhc ath mac80211
usbcore nls_base input_polldev crc_ccitt cfg80211 compat input_core a
rc4 aes_generic crypto_algapi
Process insmod (pid: 379, threadinfo=80788000, task=80ca2180,
tls=77fe52d0)
Stack : c0253184 80c57d80 80789cac 8077a200 00000001 8019edc0 807fa800 8077a200
8077a290 c00f3484 8019ed84 c00f0000 00000003 000000a0 80262c2c c00de968
802d0000 800878cc c0253228 c02528e4 c0253184 80c57d80 80bf6800 80ca2180
8007b75c 00000000 8077a200 802cf830 802d0000 00000003 fffffff4 00000015
00000348 00000124 800b189c c024bb4c c0255000 801a27e8 c0253228 c02528e4
...
Call Trace:
[<c0252928>] __mod_vermagic5+0xc260/0xc7e8 [ehci_hcd]
It is caused by:
commit c430131a02d677aa708f56342c1565edfdacb3c0
Author: Jan Andersson <jan@gaisler.com>
Date: Tue May 3 20:11:57 2011 +0200
USB: EHCI: Support controllers with big endian capability regs
The two first HC capability registers (CAPLENGTH and HCIVERSION)
are defined as one 8-bit and one 16-bit register. Most HC
implementations have selected to treat these registers as part
of a 32-bit register, giving the same layout for both big and
small endian systems.
This patch adds a new quirk, big_endian_capbase, to support
controllers with big endian register interfaces that treat
HCIVERSION and CAPLENGTH as individual registers.
Signed-off-by: Jan Andersson <jan@gaisler.com>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
The reading of the HC capability register has been moved by that
commit to a place where the ehci->caps field is not initialized
yet. This patch moves the reading of the register back to the
original place.
Acked-by: Jan Andersson <jan@gaisler.com>
Cc: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
appended patch adds support for the new FTDI FT232H chip. This chip is a
single channel version of the dual FT2232H/quad FT4232H, coming with it's
own default PID 0x6014 (FT2232H uses the same PID 0x6010 like FT2232C,
FT4232H has also it's own PID).
The patch was checked on an UM232H module and a terminal program with TX/RX
shorted to that typing in the terminal reproduced the characters.
Signed-off-by: Uwe Bonnes <bon@elektron.ikp.physik.tu-darmstadt.de>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
Both control and bulk transfers use isp1760 slots of type ATL, but the
driver unlink code for ATL slots only acts on urbs describing a bulk
transfer, letting the code for INT slots take care of the unlink instead,
which often ended up removing the interrupt transfer for root hub events
instead. That's not good, and gets fixed by this patch.
Signed-off-by: Arvid Brodin <arvid.brodin@enea.com>
Cc: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
git+ssh://master.kernel.org/pub/scm/linux/kernel/git/sarah/xhci into usb-linus
* 'for-usb-linus' of git+ssh://master.kernel.org/pub/scm/linux/kernel/git/sarah/xhci:
USB: Fix up URB error codes to reflect implementation.
xhci: Always set urb->status to zero for isoc endpoints.
xhci: Add reset on resume quirk for asrock p67 host
xHCI 1.0: Incompatible Device Error
xHCI 1.0: Force Stopped Event(FSE)
xhci: Don't warn about zeroed bMaxBurst descriptor field.
USB: Free bandwidth when usb_disable_device is called.
xhci: Reject double add of active endpoints.
|
|
This patch (as1473) renames the "in_suspend" field in struct
dev_pm_info to "is_prepared", in preparation for an upcoming change.
The new name is more descriptive of what the field really means.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Cc: stable@kernel.org
|
|
This is the same as MTP but with PTP interface descriptor.
Also removed obsolete ioctl for switching between MTP and PTP mode
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
Fixes problem sending "store added" events when there are multiple stores
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
* Functions and the device descriptor are configured from user space:
echo 0 > /sys/class/android_usb/android0/enable
echo adb,acm > /sys/class/android_usb/android0/functions
echo 2 > /sys/class/android_usb/android0/f_acm/instances
echo 1 > /sys/class/android_usb/android0/enable
* Driver does not require platform data anymore
* Moved function initialization to android.c instead of each
function file
* Replaced switches by uevents
Signed-off-by: Benoit Goby <benoit@android.com>
Signed-off-by: Mike Lockwood <lockwood@android.com>
Change-Id: If5ad9267c111ad0a442f0d87a0d31082dc5381b6
|
|
This allows composite drivers to dynamically change their configuration.
For example, a driver might remove a configuration and register a new
one with a different set of functions.
User should prevent the host from enumerating the device while changing
the configuration:
usb_gadget_disconnect(cdev->gadget);
usb_remove_config(cdev, old_config);
usb_add_config(cdev, new_config, new_conf_bind);
usb_gadget_connect(cdev->gadget);
Change-Id: Icbfb4ce41685fde9bf63d5d58fca1ad242aa69f9
Signed-off-by: Benoit Goby <benoit@android.com>
|
|
Change-Id: Idfde1aee6cfd7c648d4100060e111798c405e32c
Signed-off-by: Benoit Goby <benoit@android.com>
|
|
Signed-off-by: Mike Lockwood <lockwood@android.com>
USB: gadget: f_accessory: Misc improvements and cleanup:
- Add URI string
- Replace type string with a description string
- Add a control call to retrieve accessory protocol version (currently 1)
- Driver read() and write() calls now fail after USB disconnect until
driver file is closed and reopened.
- Misc cleanup work
Signed-off-by: Mike Lockwood <lockwood@android.com>
USB: gadget: f_accessory: Clear accessory strings when USB is disconnected
Signed-off-by: Mike Lockwood <lockwood@android.com>
USB: gadget: f_accessory: Clear previous strings on ACCESSORY_GET_PROTOCOL
Clearing strings on disconnect does not work since we may receive
a disconnect on some devices when transitioning into accessory mode.
We require an accessory to send ACCESSORY_GET_PROTOCOL before
sending any strings, so any strings from a previous session will be cleared.
Signed-off-by: Mike Lockwood <lockwood@android.com>
USB: gadget: f_accessory: Clear disconnected flag when driver file is opened
Fixes a race condition that can occur when entering accessory mode.
Signed-off-by: Mike Lockwood <lockwood@android.com>
USB: gadget: f_accessory: Add string for accessory's unique serial number
Signed-off-by: Mike Lockwood <lockwood@android.com>
USB: gadget: f_accessory: Set bNumEndpoints to correct value of 2
Change-Id: I24f4e36f196d45436e0573301500c3b93215953d
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
When the xHCI driver encounters a Missed Service Interval event for an
isochronous endpoint ring, it means the host controller skipped over
one or more isochronous TDs. For TD that is skipped, skip_isoc_td() is
called. This sets the frame descriptor status to -EXDEV, and also sets
the value stored in the int pointed to by status to -EXDEV.
If the isochronous TD happens to be the last TD in an URB,
handle_tx_event() will use the status variable to give back the URB to
the USB core. That means drivers will see urb->status as -EXDEV.
It turns out that EHCI, UHCI, and OHCI always set urb->status to zero for
an isochronous urb, regardless of what the frame status is. See
itd_complete() in ehci-sched.c:
} else {
/* URB was too late */
desc->status = -EXDEV;
}
}
/* handle completion now? */
if (likely ((urb_index + 1) != urb->number_of_packets))
goto done;
/* ASSERT: it's really the last itd for this urb
list_for_each_entry (itd, &stream->td_list, itd_list)
BUG_ON (itd->urb == urb);
*/
/* give urb back to the driver; completion often (re)submits */
dev = urb->dev;
ehci_urb_done(ehci, urb, 0);
ehci_urb_done() completes the URB with the status of the third argument, which
is always zero in this case.
It turns out that many USB webcam drivers, such as uvcvideo, cannot
handle urb->status set to a non-zero value. They will not resubmit
their isochronous URBs in that case, and userspace will see a frozen
video.
Change the xHCI driver to be consistent with the EHCI and UHCI driver,
and always set urb->status to 0 for isochronous URBs.
This patch should be backported to kernels as old as 2.6.36
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Cc: "Xu, Andiry" <Andiry.Xu@amd.com>
Cc: stable@kernel.org
|
|
The asrock p67 xhci controller completely dies on resume, add a
quirk for this, to bring the host back online after a suspend.
This should be backported to stable kernels as old as 2.6.37.
Signed-off-by: Maarten Lankhorst <m.b.lankhorst@gmail.com>
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Cc: stable@kernel.org
|
|
It is one new TRB Completion Code for the xHCI spec v1.0.
Asserted if the xHC detects a problem with a device that does not allow it to
be successfully accessed, e.g. due to a device compliance or compatibility
problem. This error may be returned by any command or transfer, and is fatal
as far as the Slot is concerned. Return -EPROTO by urb->status or frame->status
of ISOC for transfer case. And return -ENODEV for configure endpoint command,
evaluate context command and address device command if there is an incompatible
Device Error. The error codes will be sent back to the USB core to decide how
to do. It's unnecessary for other commands because after the three commands run
successfully means that the device has been accepted.
Signed-off-by: Alex He <alex.he@amd.com>
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
|
|
This patch (as1464) implements the recommended policy that most errors
during suspend or hibernation should not prevent the system from going
to sleep. In particular, failure to suspend a USB driver or a USB
device should not prevent the sleep from succeeding:
Failure to suspend a device won't matter, because the device will
automatically go into suspend mode when the USB bus stops carrying
packets. (This might be less true for USB-3.0 devices, but let's not
worry about them now.)
Failure of a driver to suspend might lead to trouble later on when the
system wakes up, but it isn't sufficient reason to prevent the system
from going to sleep.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
CC: <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
This patch (as1465) continues implementation of the policy that errors
during suspend or hibernation should not prevent the system from going
to sleep.
In this case, failure to turn on the Suspend feature for a hub port
shouldn't be reported as an error. There are situations where this
does actually occur (such as when the device plugged into that port
was disconnected in the recent past), and it turns out to be harmless.
There's no reason for it to prevent a system sleep.
Also, don't allow the hub driver to fail a system suspend if the
downstream ports aren't all suspended. This is also harmless (and
should never happen, given the change mentioned above); printing a
warning message in the kernel log is all we really need to do.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
CC: <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|