summaryrefslogtreecommitdiffstats
path: root/drivers
AgeCommit message (Collapse)Author
2012-05-17USB: gpio_vbus: handle IRQ flags properlyShinya Kuribayashi
Currently, 'res->flags' handlings are wrong in three respects: * the driver _modifies_ the contents of platform data * res->flags is set up, but not used anywhere in the driver * request_irq() always takes VBUS_IRQ_FLAGS, regardless of refs->flags This patch tries to fix this with a policy: If a platform IRQ resource is available, give preference to its IRQ flag(s) over a default one (VBUS_IRQ_FLAGS). Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-17USB: gpio_vbus: remove IRQF_SAMPLE_RANDOM useShinya Kuribayashi
IRQF_SAMPLE_RANDOM has been scheduled for removal for years (it was scheduled by July 2009, but not yet remvoed). I'm not sure when it's going to take place, but would be better to remove it now. Thanks for scripts/checkpatch secretary. Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-17USB: gpio_vbus: use cached IRQ number for consistency with the probed oneShinya Kuribayashi
gpio_vbus is designed to be able to get an IRQ number for VBUS change interrupt either (1) through platform_get_resource(IORESOURCE_IRQ) or (2) by processing gpio_to_irq(pdata->gpio_vbus), in probe() function. On the other hand, gpio_vbus_set_peripheral() and gpio_vbus_remove() are always doing gpio_to_irq(pdata->gpio_vbus) to get an IRQ number. This is not just inconsistent, but also broken. There is no guarantee that an IRQ number obtained by platform_get_resource() is equal to gpio_to_irq(pdata->gpio_vbus). Cache an IRQ number in probe() function, and use it where necessary. Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-17USB: twl6030-usb: pass IRQF_ONESHOT to request_threaded_irqMing Lei
The flag of IRQF_ONESHOT should be passed to request_threaded_irq, otherwise the following failure message will be dumped because hardware handler is defined as NULL: [ 2.271148] genirq: Threaded irq requested with handler=NULL and !ONESHOT for irq 356 [ 2.279541] twl6030_usb twl6030_usb: can't get IRQ 356, err -22 [ 2.285919] twl6030_usb: probe of twl6030_usb failed with error -22 The patch fixes the twl6030-usb probe failure. Signed-off-by: Ming Lei <ming.lei@canonical.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-17USB: storage: fixed keyword related space issues.Jeffrin Jose
Fixed keyword related space issues found by checkpatch.pl tool in drivers/usb/storage/usb.c Signed-off-by: Jeffrin Jose <ahiliation@yahoo.co.in> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-17USB: storage: fixed several trailing white spaces issues.Jeffrin Jose
Fixed several trailing white spaces issues found by checkpatch.pl tool in drivers/usb/storage/usb.c Signed-off-by: Jeffrin Jose <ahiliation@yahoo.co.in> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-17USB: storage: fixed C99 comment issue.Jeffrin Jose
Fixed C99 comment issue in drivers/usb/storage/usb.c found using checkpatch.pl tool. Signed-off-by: Jeffrin Jose <ahiliation@yahoo.co.in> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-17Merge branch 'v3.5-for-usb' of ↵Greg Kroah-Hartman
git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung into usb-next
2012-05-16Revert "USB: serial: sierra: put reset_resume callback back."Greg Kroah-Hartman
This reverts commit 6971113e1000d24f7d4975eaa6f8cf2739a4565b. As Alan pointed out, this really isn't needed as it doesn't handle this properly. Ideally this should be handled by the usb-serial core one day. So revert it. Reported-by: Alan Stern <stern@rowland.harvard.edu> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Johan Hovold <jhovold@gmail.com> Cc: Anton Samokhvalov <pg83@yandex.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-16USB: serial: fix up reset_resume callbackGreg Kroah-Hartman
If the usb-serial driver doesn't have a reset_resume callback, then we need to tell the USB core that it doesn't, and it needs to rebind the device. Thanks to Alan for pointing out my mistake, and providing the fix. Reported-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-16USB: serial: ch341: make the reset_resume callback actually work.Greg Kroah-Hartman
I hooked up the wrong callback in my previous patch, this should fix it. Reported-by: Alan Stern <stern@rowland.harvard.edu> Cc: Johan Hovold <jhovold@gmail.com> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-16staging: usb: gadget: Add FunctionFS support to Configurable Composite ↵Andrzej Pietrasiewicz
Gadget driver Add FunctionFS support. It allows certain USB functions to be provided from userspace, e.g. MTP, PTP, adb. The functions provided by the gadget itself are enumerated in /sys/class/ccg0/functions. The functions which can be supplied from userspace must be enumerated in /sys/class/ccg0/f_fs/user_functions. No other userspace functions can be used than specified in the above mentioned file, but just specifying them there is not enough to activate them. The userspace functions in order to be activated need also be enumerated in /sys/class/ccg0/functions. An example sequence of operations can be as follows: $ echo 0 > /sys/class/ccg_usb/ccg0/enable $ echo -n 0x2d01 > /sys/module/g_ccg/parameters/idProduct $ echo -n MyDevice > /sys/module/g_ccg/parameters/iSerialNumber $ echo -n 0x1d6b > /sys/module/g_ccg/parameters/idVendor $ echo -n Manufacturer > /sys/module/g_ccg/parameters/iManufacturer $ echo -n Product > /sys/module/g_ccg/parameters/iProduct $ echo -n bcdDevice > /sys/module/g_ccg/parameters/bcdDevice $ echo adb,mtp,ptp > /sys/class/ccg_usb/ccg0/f_fs/user_functions $ echo mass_storage,ptp > /sys/class/ccg_usb/ccg0/functions $ echo /file.img > /sys/class/ccg_usb/ccg0/f_mass_storage/lun/file $ mkdir -p /dev/usbgadget/ptp $ mount -t functionfs ptp /dev/usbgadget/ptp $ ./ptp & $ echo 1 > /sys/class/ccg_usb/ccg0/enable The above example declares that adb, mtp and ptp functions can be supplied from userspace through FunctionFS. But of them all only ptp is actually activated, together with mass_storage, the latter being implemented in the gadget itself (in kernel, not in userspace). The list of functions can be modified at runtime while the gadget is not enabled, that is, after $ echo 0 > /sys/class/ccg_usb/ccg0/enable The FunctionFS function is implicitly handled by the gadget, that is, if a userspace function name is provided in /sys/class/ccg_usb/ccg0/functions, then the FunctionFS function is activated. Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Michal Nazarewicz <mina86@mina86.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-16staging: usb: gadget: Add Configurable Composite Gadget driverMike Lockwood
The Configurable Gadget driver is a composite driver that allows userspace to change at runtime the list of functions enabled in its configuration and to configure these functions. It supports multiple functions: acm, rndis, and mass storage. It is usually controlled by a daemon that changes the configuration based on user settings. For example, rndis is enabled when the user enables sharing the phone data connection. As an example on how to use it, the following shell commands will make the gadget disconnect from the host and make it be re-enumerated as a composite with 1 rndis and 2 acm interfaces, and a different product id: echo 0 > /sys/class/ccg_usb/ccg0/enable echo rndis,acm > /sys/class/ccg_usb/ccg0/functions echo 2 > /sys/class/ccg_usb/ccg0/f_acm/instances echo -n 0x2d01 > /sys/module/g_ccg/parameters/idProduct echo 1 > /sys/class/ccg_usb/ccg0/enable The driver requires a gadget controller that supports software control of the D+ pullup and the controller driver must support disabling the pullup during composite_bind. Signed-off-by: Mike Lockwood <lockwood@android.com> Signed-off-by: Benoit Goby <benoit@android.com> [import from android.c, implement review comments, remove adb,mtp,ptp,accessory] Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-16USB: serial: generic driver is only for testingBjørn Mork
Make some noise during probe to make sure the users are aware of the intended purpose of this driver. Signed-off-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-16usb: gadget: at91_udc: fix endpoint descriptor dereferenceNicolas Ferre
The patch 5a6506f (Update at91_udc to use usb_endpoint_descriptor inside the struct usb_ep) removes the desc field of struct at91_ep. This convertion had not been completed which leads to a compilation error. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-16usb: fix breakage on systems without ACPISasha Levin
Commit da0af6e ("usb: Bind devices to ACPI devices when possible") really tries to force-bind devices even when impossible, unlike what it says in the subject. CONFIG_ACPI is not an indication that ACPI tables are actually present, nor is an indication that any USB relevant information is present in them. There is no reason to fail the creation of a USB bus if it can't bind it to ACPI device during initialization. On systems with CONFIG_ACPI set but without ACPI tables it would cause a boot panic. Signed-off-by: Sasha Levin <levinsasha928@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: symbolserial.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the symbolserial.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: Rusty Russell <rusty@rustcorp.com.au> CC: Johan Hovold <jhovold@gmail.com> CC: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> CC: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: spcp8x5.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the spcp8x5.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: Rusty Russell <rusty@rustcorp.com.au> CC: Alan Stern <stern@rowland.harvard.edu> CC: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: qcserial.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the qcserial.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: Thomas Tuttle <ttuttle@chromium.org> CC: Alan Stern <stern@rowland.harvard.edu> CC: Paul Gortmaker <paul.gortmaker@windriver.com> CC: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: navman.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the navman.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: Rusty Russell <rusty@rustcorp.com.au> CC: Alan Stern <stern@rowland.harvard.edu> CC: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: ir-usb.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the ir-usb.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: Rusty Russell <rusty@rustcorp.com.au> CC: Johan Hovold <jhovold@gmail.com> CC: Alan Stern <stern@rowland.harvard.edu> CC: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: ipaq.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the ipaq.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: Rusty Russell <rusty@rustcorp.com.au> CC: Johan Hovold <jhovold@gmail.com> CC: Alan Stern <stern@rowland.harvard.edu> CC: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: generic.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the generic.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: f81232.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the f81232.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: belkin_sa.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the belkin_sa.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: William Greathouse <wgreathouse@smva.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: ark3116.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the ark3116.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: Rusty Russell <rusty@rustcorp.com.au> CC: Alan Stern <stern@rowland.harvard.edu> CC: Mauro Carvalho Chehab <mchehab@redhat.com> CC: Bart Hartgers <bart.hartgers@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: aircable.c: remove dbg() usageGreg Kroah-Hartman
dbg() is a usb-serial specific macro. This patch converts the aircable.c driver to use dev_dbg() instead to tie into the dynamic debug infrastructure. CC: Paul Gortmaker <paul.gortmaker@windriver.com> CC: Rusty Russell <rusty@rustcorp.com.au> CC: Alan Stern <stern@rowland.harvard.edu> CC: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: serial: sierra: put reset_resume callback back.Greg Kroah-Hartman
A few patches ago, I removed the reset_resume callback in this driver. Now that the usb-serial core supports reset_resume, put this driver callback back as well, so it should work identically to how it was originally. Now if this function really is doing what it should be doing, well, that's a different story, but we are at least doing the identical thing that we were before... Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Johan Hovold <jhovold@gmail.com> Cc: Anton Samokhvalov <pg83@yandex.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: serial: ch341: put reset_resume callback back.Greg Kroah-Hartman
A few patches ago, I removed the reset_resume callback, changing it to resume instead. Now that the usb-serial core supports reset_resume, put this driver callback back as well, so it should work identically to how it was originally. Now if this function really is doing what it should be doing, well, that's a different story, but we are at least doing the identical thing that we were before... Cc: Johan Hovold <jhovold@gmail.com> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: serial: hook up reset_resume callbackGreg Kroah-Hartman
The callback is now hooked up for any USB to serial driver that wants it. We only register the callback if any of the usb-serial structures want it, this keeps the USB core happy. Thanks to Alan Stern for the ideas on how to do this. Cc: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15usb: chipidea: remove zero check of hw_ep_maxRichard Zhao
It's 0 for host only device. Signed-off-by: Richard Zhao <richard.zhao@freescale.com> Cc: Marek Vasut <marex@denx.de> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: CI13xxx: Use usb_put_hcd() on failure to drop HCDMarek Vasut
Use usb_put_hcd() call instead of usb_remove_hcd() as that's the appropriate call to drop hcd which failed registration. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-15USB: CI13xxx: Allow use of CONFIG_USB_EHCI_ROOT_HUB_TTMarek Vasut
The CI13xxx usb host needs the root TT support to work properly. Allow selecting this for the CI13xxx too. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: EHCI: work around bug in the Philips ISP1562 controllerAlan Stern
This patch (as1556) works around a bug in the Philips ISP1562 EHCI controller. Although the controller claims to support frame-list lengths smaller than the default of 1024 for its periodic schedule, in fact smaller values don't work. A new quirk flag is added to indicate when the bug is present, and if it is then the schedule size is left at the default value. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: EHCI: improve full-speed isochronous scheduling routineAlan Stern
This patch (as1555) improves the code ehci-hcd uses while checking the periodic schedule for isochronous transfers to full-speed devices. In addition to making sure that a new transfer does not violate the restrictions on the high-speed schedule, it also has to check the restrictions on the full-speed part of the bus, i.e., the part beyond the Transaction Translator (TT). It does this by calling tt_available() (or tt_no_collision() if CONFIG_USB_EHCI_TT_NEWSCHED isn't enabled). However it calls that routine on each pass through a loop over the frames being modified, which is an unnecessary expense because tt_available() (or tt_no_collision) already does its own loop over frames. It is sufficient to do the check just once, before starting the loop. In addition, the function calls incorrectly converted the transfer's period from microframes to frames by doing a left shift instead of a right shift. The patch fixes this while moving the calls. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14usb: musb: cppi: add missing include to fix compilationReinhard Tartler
This fixes compilation as module. Signed-off-by: Reinhard Tartler <tartler@cs.fau.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: add read support to usb-serial/../new_idBjørn Mork
Keep the usb-serial support for dynamic IDs in sync with the usb support. This enables readout of dynamic device IDs for usb-serial drivers. Common code is exported from the usb core system and reused by the usb-serial bus driver. Signed-off-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: let both new_id and remove_id show dynamic id listBjørn Mork
This enables the current list of dynamic IDs to be read out through either new_id or remove_id. Signed-off-by: Bjørn Mork <bjorn@mork.no> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14FunctionFS: enable multiple functionsAndrzej Pietrasiewicz
Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Michal Nazarewicz <mina86@mina86.com> Cc: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14Revert "usb: add struct usb_hub_port to store port related members."Greg Kroah-Hartman
This reverts commit f397d7c4c5e8a1eb93f2ed15808a509318ccf1dd. This series isn't quite ready for 3.5 just yet, so revert it and give the author more time to get it correct. Cc: Lan Tianyu <tianyu.lan@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14Revert "usb: move struct usb_device->children to struct usb_hub_port->child"Greg Kroah-Hartman
This reverts commit bebc56d58dc780539777d2b1ca80df5566e2ad87. The call here is fragile and not well thought out, so revert it, it's not fully baked yet and I don't want this to go into 3.5. Cc: Lan Tianyu <tianyu.lan@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: gpio_vbus: avoid consecutive vbus_session calls with the same "is_active"Shinya Kuribayashi
Basically, ->vbus_session() calls should be served when VBUS session starts and ends (it's not whenever transciever drivers detect VBUS _changes_). Otherwise, if UDC gadget drivers don't want for some reason ->vbus_session() calls with the same "is_active" value, either OTG or UDC drivers need to have some protection handlings. Also, on platforms using this 'gpio_vbus' driver, the driver is only allowed to check whether VBUS is applied. There is no kernel-standard way prepared for UDC gadget drivers to do that. With this in mind, gpio_vbus should try to prevent unnecessary consecutive vbus_session calls being served with the same "in_active" value. Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: gpio_vbus: put a missing regulator_put() on errorShinya Kuribayashi
Note that regulator_put() doesn't care about whether ->vbus_draw is valid or not. Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: gpio_vbus: provide an appropriate debounce intervalShinya Kuribayashi
In commit c2344f13b59e007d782a3e591ebc551bc583a8b7 (USB: gpio_vbus: add delayed vbus_session calls, 2009-01-24), usb_gadget_vbus_connect() and ...disconnect() were extracted from the interrupt handler, so to allow vbus_session handlers to deal with msleep() calls. This patch takes the approach one step further. USB2.0 specification (7.1.7.3 Connect and Disconnect Signaling) says that the USB system software (shall) provide a debounce interval with a minimum duration of 100 ms, which ensures that the electrical and mechanical connection is stable before software attempts to reset the attached device. Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: gpio_vbus: fix inconsistent 'dev_id' parameters at free_irq()Shinya Kuribayashi
'dev_id' has to be the same with the one passed to request_irq(). Signed-off-by: Shinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14usb: Kconfig: remove unneeded default valueDavid Herrmann
If no default value is specified, then 'n' is used so the default value used here is not needed. Furthermore, we should never change default values depending on EXPERT mode. EXPERT mode should only make options visible, not change them. Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: David Herrmann <dh.herrmann@googlemail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: ohci-omap: Use usb_put_transceiver instead of put_deviceJarkko Nikula
Currently usb_put_transceiver calls put_device so this is a no-op but it is better to keep API usage consistent as ohci->transceiver is allocated with usb_get_transceiver. While at there remove one extra ohci->transceiver test as the code block has already tested it. Signed-off-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Acked-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14USB: ehci-fsl: Use usb_put_transceiver instead of put_deviceJarkko Nikula
Currently usb_put_transceiver calls put_device so this is a no-op but it is better to keep API usage consistent as ehci->transceiver is allocated with usb_get_transceiver. While at there remove one extra ehci->transceiver test as the code block has already tested it. Signed-off-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-12Merge tag 'gpio-for-linus' of git://git.secretlab.ca/git/linux-2.6Linus Torvalds
Pull a few more GPIO bug fixes from Grant Likely: "Oops, missed a couple. Here's an updated pull req for GPIO" A set of PCH bug fixes, and one patch to fix up compile warnings * tag 'gpio-for-linus' of git://git.secretlab.ca/git/linux-2.6: gpio/exynos: Fix compiler warnings when non-exynos machines are selected gpio: pch9: Use proper flow type handlers
2012-05-12Merge tag 'scsi-fixes' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi Pull SCSI fixes from James Bottomley: "This is a set of minor qla and virto fixes plus one major regression fix (oops in all legacy host drivers)." * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: [SCSI] virtio_scsi: fix TMF use-after-free [SCSI] fix oops in all legacy host adapters caused by 6f381fa [SCSI] qla2xxx: Update version number to 8.04.00.03-k. [SCSI] qla2xxx: Properly check for current state after the fabric-login request. [SCSI] qla2xxx: Proper completion to scsi-ml for scsi status task_set_full and busy. [SCSI] qla2xxx: Block flash access from application when device is initialized for ISP82xx. [SCSI] qla2xxx: Fix reset time out as qla2xxx not ack to reset request.