From: Greg KH <gregkh@suse.de>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: torvalds@linux-foundation.org, akpm@linux-foundation.org,
alan@lxorguk.ukuu.org.uk, Stanislaw Gruszka <sgruszka@redhat.com>,
Ivo van Doorn <IvDoorn@gmail.com>,
"John W. Linville" <linville@tuxdriver.com>
Subject: [003/107] rt2x00: do not drop usb dev reference counter on suspend
Date: Wed, 02 Nov 2011 15:13:29 -0700 [thread overview]
Message-ID: <20111102221450.345701064@clark.kroah.org> (raw)
In-Reply-To: <20111102221600.GA26650@kroah.com>
2.6.32-longterm review patch. If anyone has any objections, please let us know.
------------------
From: Stanislaw Gruszka <sgruszka@redhat.com>
commit 543cc38c8fe86deba4169977c61eb88491036837 upstream.
When hibernating ->resume may not be called by usb core, but disconnect
and probe instead, so we do not increase the counter after decreasing
it in ->supend. As a result we free memory early, and get crash when
unplugging usb dongle.
BUG: unable to handle kernel paging request at 6b6b6b9f
IP: [<c06909b0>] driver_sysfs_remove+0x10/0x30
*pdpt = 0000000034f21001 *pde = 0000000000000000
Pid: 20, comm: khubd Not tainted 3.1.0-rc1-wl+ #20 LENOVO 6369CTO/6369CTO
EIP: 0060:[<c06909b0>] EFLAGS: 00010202 CPU: 1
EIP is at driver_sysfs_remove+0x10/0x30
EAX: 6b6b6b6b EBX: f52bba34 ECX: 00000000 EDX: 6b6b6b6b
ESI: 6b6b6b6b EDI: c0a0ea20 EBP: f61c9e68 ESP: f61c9e64
DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068
Process khubd (pid: 20, ti=f61c8000 task=f6138270 task.ti=f61c8000)
Call Trace:
[<c06909ef>] __device_release_driver+0x1f/0xa0
[<c0690b20>] device_release_driver+0x20/0x40
[<c068fd64>] bus_remove_device+0x84/0xe0
[<c068e12a>] ? device_remove_attrs+0x2a/0x80
[<c068e267>] device_del+0xe7/0x170
[<c06d93d4>] usb_disconnect+0xd4/0x180
[<c06d9d61>] hub_thread+0x691/0x1600
[<c0473260>] ? wake_up_bit+0x30/0x30
[<c0442a39>] ? complete+0x49/0x60
[<c06d96d0>] ? hub_disconnect+0xd0/0xd0
[<c06d96d0>] ? hub_disconnect+0xd0/0xd0
[<c0472eb4>] kthread+0x74/0x80
[<c0472e40>] ? kthread_worker_fn+0x150/0x150
[<c0809b3e>] kernel_thread_helper+0x6/0x10
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Acked-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/net/wireless/rt2x00/rt2x00usb.c | 14 +-------------
1 file changed, 1 insertion(+), 13 deletions(-)
--- a/drivers/net/wireless/rt2x00/rt2x00usb.c
+++ b/drivers/net/wireless/rt2x00/rt2x00usb.c
@@ -703,18 +703,8 @@ int rt2x00usb_suspend(struct usb_interfa
{
struct ieee80211_hw *hw = usb_get_intfdata(usb_intf);
struct rt2x00_dev *rt2x00dev = hw->priv;
- int retval;
- retval = rt2x00lib_suspend(rt2x00dev, state);
- if (retval)
- return retval;
-
- /*
- * Decrease usbdev refcount.
- */
- usb_put_dev(interface_to_usbdev(usb_intf));
-
- return 0;
+ return rt2x00lib_suspend(rt2x00dev, state);
}
EXPORT_SYMBOL_GPL(rt2x00usb_suspend);
@@ -723,8 +713,6 @@ int rt2x00usb_resume(struct usb_interfac
struct ieee80211_hw *hw = usb_get_intfdata(usb_intf);
struct rt2x00_dev *rt2x00dev = hw->priv;
- usb_get_dev(interface_to_usbdev(usb_intf));
-
return rt2x00lib_resume(rt2x00dev);
}
EXPORT_SYMBOL_GPL(rt2x00usb_resume);
next prev parent reply other threads:[~2011-11-03 1:33 UTC|newest]
Thread overview: 122+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-02 22:16 [000/107] 2.6.32.47-longterm review Greg KH
2011-11-02 22:13 ` [001/107] USB: ftdi_sio: add Calao reference board support Greg KH
2011-11-02 22:13 ` [002/107] USB: EHCI: Do not rely on PORT_SUSPEND to stop USB resuming in ehci_bus_resume() Greg KH
2011-11-02 22:13 ` Greg KH [this message]
2011-11-02 22:13 ` [004/107] atm: br2684: Fix oops due to skb->dev being NULL Greg KH
2011-11-02 22:13 ` [005/107] sparc: Allow handling signals when stack is corrupted Greg KH
2011-11-04 4:33 ` Ben Hutchings
2011-11-04 6:09 ` David Miller
2011-11-02 22:13 ` [006/107] sparc: fix array bounds error setting up PCIC NMI trap Greg KH
2011-11-02 22:13 ` [007/107] Fix broken backport for IPv6 tunnels Greg KH
2011-11-02 22:13 ` [008/107] net: Fix IPv6 GSO type checks in Intel ethernet drivers Greg KH
2011-11-02 22:13 ` [009/107] ipv6: Add GSO support on forwarding path Greg KH
2011-11-02 22:13 ` [010/107] Revert "x86, hotplug: Use mwait to offline a processor, fix the legacy case" Greg KH
2011-11-02 22:13 ` [011/107] GRO: fix merging a paged skb after non-paged skbs Greg KH
2011-11-02 22:13 ` [012/107] xen-blkfront: fix data size for xenbus_gather in blkfront_connect Greg KH
2011-11-02 22:13 ` [013/107] md/linear: avoid corrupting structure while waiting for rcu_free to complete Greg KH
2011-11-02 22:13 ` [014/107] powerpc/mpic: Fix problem that affinity is not updated Greg KH
2011-11-02 22:13 ` [015/107] powerpc/pci: Check devices status property when scanning OF tree Greg KH
2011-11-02 22:13 ` [016/107] xen: x86_32: do not enable iterrupts when returning from exception in interrupt context Greg KH
2011-11-02 22:13 ` [017/107] xen/smp: Warn user why they keel over - nosmp or noapic and what to use instead Greg KH
2011-11-02 22:13 ` [018/107] ARM: davinci: da850 EVM: read mac address from SPI flash Greg KH
2011-11-02 22:13 ` [019/107] md: Fix handling for devices from 2TB to 4TB in 0.90 metadata Greg KH
2011-11-02 22:13 ` [020/107] net/9p: fix client code to fail more gracefully on protocol error Greg KH
2011-11-02 22:13 ` [021/107] fs/9p: Fid is not valid after a failed clunk Greg KH
2011-11-02 22:13 ` [022/107] net/9p: Fix the msize calculation Greg KH
2011-11-02 22:13 ` [023/107] irda: fix smsc-ircc2 section mismatch warning Greg KH
2011-11-02 22:13 ` [024/107] [SCSI] qla2xxx: Correct inadvertent loop state transitions during port-update handling Greg KH
2011-11-02 22:13 ` [025/107] e1000: Fix driver to be used on PA RISC C8000 workstations Greg KH
2011-11-02 22:13 ` [026/107] ASoC: Fix reporting of partial jack updates Greg KH
2011-11-02 22:13 ` [027/107] ALSA: HDA: Cirrus - fix "Surround Speaker" volume control name Greg KH
2011-11-02 22:13 ` [028/107] drm/radeon/kms: fix typo in r100_blit_copy Greg KH
2011-11-03 13:01 ` Deucher, Alexander
2011-11-03 13:15 ` Greg KH
2011-11-02 22:13 ` [029/107] cifs: fix possible memory corruption in CIFSFindNext Greg KH
2011-11-02 22:13 ` [030/107] b43: Fix beacon problem in ad-hoc mode Greg KH
2011-11-02 22:13 ` [031/107] wireless: Reset beacon_found while updating regulatory Greg KH
2011-11-02 22:13 ` [032/107] USB: PL2303: correctly handle baudrates above 115200 Greg KH
2011-11-02 22:13 ` [033/107] ASIX: Add AX88772B USB ID Greg KH
2011-11-02 22:14 ` [034/107] hvc_console: Improve tty/console put_chars handling Greg KH
2011-11-02 22:14 ` [035/107] TPM: Call tpm_transmit with correct size Greg KH
2011-11-02 22:14 ` [036/107] TPM: Zero buffer after copying to userspace Greg KH
2011-11-02 22:14 ` [037/107] [SCSI] libiscsi_tcp: fix LLD data allocation Greg KH
2011-11-02 22:14 ` [038/107] cnic: Improve NETDEV_UP event handling Greg KH
2011-11-02 22:14 ` [039/107] ALSA: hda/realtek - Avoid bogus HP-pin assignment Greg KH
2011-11-02 22:14 ` [040/107] [SCSI] 3w-9xxx: fix iommu_iova leak Greg KH
2011-11-02 22:14 ` [041/107] [SCSI] aacraid: reset should disable MSI interrupt Greg KH
2011-11-02 22:14 ` [042/107] [SCSI] libsas: fix failure to revalidate domain for anything but the first expander child Greg KH
2011-11-02 22:14 ` [043/107] cfg80211: Fix validation of AKM suites Greg KH
2011-11-02 22:14 ` [044/107] splice: direct_splice_actor() should not use pos in sd Greg KH
2011-11-02 22:14 ` [045/107] [SCSI] libsas: fix panic when single phy is disabled on a wide port Greg KH
2011-11-02 22:14 ` [046/107] ahci: Enable SB600 64bit DMA on Asus M3A Greg KH
2011-11-02 22:14 ` [047/107] HID: usbhid: Add support for SiGma Micro chip Greg KH
2011-11-02 22:14 ` [048/107] hwmon: (w83627ehf) Properly report thermal diode sensors Greg KH
2011-11-02 22:14 ` [049/107] x25: Prevent skb overreads when checking call user data Greg KH
2011-11-02 22:14 ` [050/107] block: check for proper length of iov entries earlier in blk_rq_map_user_iov() Greg KH
2011-11-04 15:24 ` Ben Hutchings
2011-11-04 17:14 ` Greg KH
2011-11-04 19:06 ` Ben Hutchings
2011-11-04 20:28 ` Greg KH
2011-11-04 21:00 ` Dan Carpenter
2011-11-04 21:04 ` Greg KH
2011-11-04 19:36 ` Dan Carpenter
2011-11-02 22:14 ` [051/107] staging: quatech_usb2: Potential lost wakeup scenario in TIOCMIWAIT Greg KH
2011-11-02 22:14 ` [052/107] USB: qcserial: add device ID for "HP un2430 Mobile Broadband Module" Greg KH
2011-11-02 22:14 ` [053/107] xhci-mem.c: Check for ring->first_seg != NULL Greg KH
2011-11-02 22:14 ` [054/107] [SCSI] ipr: Always initiate hard reset in kdump kernel Greg KH
2011-11-02 22:14 ` [055/107] [SCSI] libsas: set sas_address and device type of rphy Greg KH
2011-11-02 22:14 ` [056/107] ALSA: HDA: Add new revision for ALC662 Greg KH
2011-11-02 22:14 ` [057/107] x86: Fix compilation bug in kprobes twobyte_is_boostable Greg KH
2011-11-02 22:14 ` [058/107] epoll: fix spurious lockdep warnings Greg KH
2011-11-02 22:14 ` [059/107] usbmon vs. tcpdump: fix dropped packet count Greg KH
2011-11-02 22:14 ` [060/107] USB: storage: Use normalized sense when emulating autosense Greg KH
2011-11-02 22:14 ` [061/107] USB: pid_ns: ensure pid is not freed during kill_pid_info_as_uid Greg KH
2011-11-02 22:14 ` [062/107] usb: cdc-acm: Owen SI-30 support Greg KH
2011-11-02 22:14 ` [063/107] USB: add RESET_RESUME for webcams shown to be quirky Greg KH
2011-11-02 22:14 ` [064/107] USB: pl2303: add id for SMART device Greg KH
2011-11-02 22:14 ` [065/107] USB: ftdi_sio: add PID for Sony Ericsson Urban Greg KH
2011-11-02 22:14 ` [066/107] USB: ftdi_sio: Support TI/Luminary Micro Stellaris BD-ICDI Board Greg KH
2011-11-02 22:14 ` [067/107] QE/FHCI: fixed the CONTROL bug Greg KH
2011-11-02 22:14 ` [068/107] Update email address for stable patch submission Greg KH
2011-11-03 8:08 ` Christoph Biedl
2011-11-03 8:25 ` Sven Joachim
2011-11-03 12:18 ` Greg KH
2011-11-02 22:14 ` [069/107] kobj_uevent: Ignore if some listeners cannot handle message Greg KH
2011-11-02 22:14 ` [070/107] kmod: prevent kmod_loop_msg overflow in __request_module() Greg KH
2011-11-02 22:14 ` [071/107] time: Change jiffies_to_clock_t() argument type to unsigned long Greg KH
2011-11-02 22:14 ` [072/107] nfsd4: Remove check for a 32-bit cookie in nfsd4_readdir() Greg KH
2011-11-02 22:14 ` [073/107] nfsd4: ignore WANT bits in open downgrade Greg KH
2011-11-02 22:14 ` [074/107] ASoC: wm8940: Properly set codec->dapm.bias_level Greg KH
2011-11-02 22:14 ` [075/107] ASoC: ak4642: fixup cache register table Greg KH
2011-11-02 22:14 ` [076/107] ASoC: ak4535: " Greg KH
2011-11-02 22:14 ` [077/107] KVM: s390: check cpu_id prior to using it Greg KH
2011-11-02 22:14 ` [078/107] [S390] ccwgroup: move attributes to attribute group Greg KH
2011-11-02 22:14 ` [079/107] iommu/amd: Fix wrong shift direction Greg KH
2011-11-02 22:14 ` [080/107] carminefb: Fix module parameters permissions Greg KH
2011-11-02 22:14 ` [081/107] [media] uvcvideo: Set alternate setting 0 on resume if the bus has been reset Greg KH
2011-11-02 22:14 ` [082/107] [media] tuner_xc2028: Allow selection of the frequency adjustment code for XC3028 Greg KH
2011-11-02 22:14 ` [083/107] plat-mxc: iomux-v3.h: implicitly enable pull-up/down when thats desired Greg KH
2011-11-02 22:14 ` [084/107] um: fix ubd cow size Greg KH
2011-11-02 22:14 ` [085/107] cfq: calculate the seek_mean per cfq_queue not per cfq_io_context Greg KH
2011-11-02 22:14 ` [086/107] cfq: merge cooperating cfq_queues Greg KH
2011-11-02 22:14 ` [087/107] cfq: change the meaning of the cfqq_coop flag Greg KH
2011-11-02 22:14 ` [088/107] cfq: break apart merged cfqqs if they stop cooperating Greg KH
2011-11-02 22:14 ` [089/107] cfq-iosched: get rid of the coop_preempt flag Greg KH
2011-11-02 22:14 ` [090/107] cfq: Dont allow queue merges for queues that have no process references Greg KH
2011-11-02 22:14 ` [091/107] xen/timer: Missing IRQF_NO_SUSPEND in timer code broke suspend Greg KH
2011-11-02 22:14 ` [092/107] KVM: x86: Reset tsc_timestamp on TSC writes Greg KH
2011-11-02 22:14 ` [093/107] genirq: Add IRQF_RESUME_EARLY and resume such IRQs earlier Greg KH
2011-11-02 22:15 ` [094/107] Revert "usb: musb: restore INDEX register in resume path" Greg KH
2011-11-02 22:15 ` [095/107] Revert "MIPS: MTX-1: Make au1000_eth probe all PHY Greg KH
2011-11-02 22:15 ` [096/107] watchdog: mtx1-wdt: fix build failure Greg KH
2011-11-02 22:15 ` [097/107] kcore: fix test for end of list Greg KH
2011-11-02 22:15 ` [098/107] thinkpad-acpi: module autoloading for newer Lenovo ThinkPads Greg KH
2011-11-02 22:15 ` [099/107] scm: lower SCM_MAX_FD Greg KH
2011-11-02 22:15 ` [100/107] deal with races in /proc/*/{syscall,stack,personality} Greg KH
2011-11-02 22:15 ` [101/107] NLM: Dont hang forever on NLM unlock requests Greg KH
2011-11-02 22:15 ` [102/107] Bluetooth: l2cap and rfcomm: fix 1 byte infoleak to userspace Greg KH
2011-11-02 22:15 ` [103/107] vm: fix vm_pgoff wrap in stack expansion Greg KH
2011-11-02 22:15 ` [104/107] vm: fix vm_pgoff wrap in upward expansion Greg KH
2011-11-02 22:15 ` [105/107] Bluetooth: Prevent buffer overflow in l2cap config request Greg KH
2011-11-02 22:15 ` [106/107] nl80211: fix overflow in ssid_len Greg KH
2011-11-02 22:15 ` [107/107] net_sched: Fix qdisc_notify() Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20111102221450.345701064@clark.kroah.org \
--to=gregkh@suse.de \
--cc=IvDoorn@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=sgruszka@redhat.com \
--cc=stable@vger.kernel.org \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®