From 7e8996167416c9082c0760a2b849f7c5e93883ef Mon Sep 17 00:00:00 2001 From: Maximilian Attems Date: Tue, 18 May 2010 22:01:33 +0000 Subject: [PATCH] revert usb autosuspend stuff 19:27 Yes, upstream wants to do it differently svn path=/dists/trunk/linux-2.6/; revision=15751 --- debian/changelog | 2 - ...inux-2.6-driver-level-usb-autosuspend.diff | 69 ------------------- .../all/linux-2.6-usb-uvc-autosuspend.diff | 19 ----- debian/patches/series/base | 2 - 4 files changed, 92 deletions(-) delete mode 100644 debian/patches/bugfix/all/linux-2.6-driver-level-usb-autosuspend.diff delete mode 100644 debian/patches/bugfix/all/linux-2.6-usb-uvc-autosuspend.diff diff --git a/debian/changelog b/debian/changelog index c8327bd46..6c6430f90 100644 --- a/debian/changelog +++ b/debian/changelog @@ -18,8 +18,6 @@ linux-2.6 (2.6.34-1~experimental.1) UNRELEASED; urgency=low USB_SERIAL_VIVOPAY_SERIAL, MMC_RICOH_MMC, LEDS_DELL_NETBOOKS, LOGFS. * [x86] Enable EEEPC_WMI. * Fix backlight support on some recent Thinkpads. - * usb: Allow drivers to enable USB autosuspend on a per-device basis. - * Enable autosuspend on UVC by default. * acpi: Fall back to manually changing SCI_EN. * Explicitly pass in whether sb is pinned or not. diff --git a/debian/patches/bugfix/all/linux-2.6-driver-level-usb-autosuspend.diff b/debian/patches/bugfix/all/linux-2.6-driver-level-usb-autosuspend.diff deleted file mode 100644 index 00384ccf5..000000000 --- a/debian/patches/bugfix/all/linux-2.6-driver-level-usb-autosuspend.diff +++ /dev/null @@ -1,69 +0,0 @@ -commit 7d0d20a25c6f477fb198b85510c78156d7d7c5af -Author: Matthew Garrett -Date: Tue Jun 9 20:11:47 2009 +0100 - - usb: Allow drivers to enable USB autosuspend on a per-device basis - - USB autosuspend is currently only enabled by default for hubs. On other - hardware the decision is made by userspace. This is unnecessary in cases - where we know that the hardware supports autosuspend, so this patch adds - a function to allow drivers to enable it at probe time. - - Signed-off-by: Matthew Garrett - ---- - drivers/usb/core/driver.c | 16 ++++++++++++++++ - include/linux/usb.h | 4 ++++ - 2 files changed, 20 insertions(+), 0 deletions(-) - -diff --git a/drivers/usb/core/driver.c b/drivers/usb/core/driver.c -index 60a45f1..03e0228 100644 ---- a/drivers/usb/core/driver.c -+++ b/drivers/usb/core/driver.c -@@ -1648,6 +1648,21 @@ void usb_autopm_put_interface_async(struct usb_interface *intf) - EXPORT_SYMBOL_GPL(usb_autopm_put_interface_async); - - /** -+ * usb_device_autosuspend_enable - enable autosuspend on a device -+ * @udev: the usb_device to be autosuspended -+ * -+ * This routine should be called by an interface driver when it knows that -+ * the device in question supports USB autosuspend. -+ * -+ */ -+void usb_device_autosuspend_enable(struct usb_device *udev) -+{ -+ udev->autosuspend_disabled = 0; -+ usb_external_suspend_device(udev, PMSG_USER_SUSPEND); -+} -+EXPORT_SYMBOL_GPL(usb_device_autosuspend_enable); -+ -+/** - * usb_autopm_get_interface - increment a USB interface's PM-usage counter - * @intf: the usb_interface whose counter should be incremented - * -diff --git a/include/linux/usb.h b/include/linux/usb.h -index e101a2d..dd47590 100644 ---- a/include/linux/usb.h -+++ b/include/linux/usb.h -@@ -540,6 +540,7 @@ extern struct usb_device *usb_find_device(u16 vendor_id, u16 product_id); - - /* USB autosuspend and autoresume */ - #ifdef CONFIG_USB_SUSPEND -+extern void usb_device_autosuspend_enable(struct usb_device *udev); - extern int usb_autopm_get_interface(struct usb_interface *intf); - extern void usb_autopm_put_interface(struct usb_interface *intf); - extern int usb_autopm_get_interface_async(struct usb_interface *intf); -@@ -563,6 +564,9 @@ static inline void usb_mark_last_busy(struct usb_device *udev) - - #else - -+static inline void usb_device_autosuspend_enable(struct usb_device *udev) -+{ } -+ - static inline int usb_autopm_get_interface(struct usb_interface *intf) - { return 0; } - static inline int usb_autopm_get_interface_async(struct usb_interface *intf) --- -1.6.5.2 - diff --git a/debian/patches/bugfix/all/linux-2.6-usb-uvc-autosuspend.diff b/debian/patches/bugfix/all/linux-2.6-usb-uvc-autosuspend.diff deleted file mode 100644 index b7c7f6e0f..000000000 --- a/debian/patches/bugfix/all/linux-2.6-usb-uvc-autosuspend.diff +++ /dev/null @@ -1,19 +0,0 @@ -commit 9d4c919bcfa794c054cc33155c7e3c53ac2c5684 -Author: Matthew Garrett -Date: Sun Jul 19 02:24:49 2009 +0100 - - Enable autosuspend on UVC by default - -diff --git a/drivers/media/video/uvc/uvc_driver.c b/drivers/media/video/uvc/uvc_driver.c -index 89927b7..8de516b 100644 ---- a/drivers/media/video/uvc/uvc_driver.c -+++ b/drivers/media/video/uvc/uvc_driver.c -@@ -1647,6 +1647,8 @@ static int uvc_probe(struct usb_interface *intf, - "supported.\n", ret); - } - -+ usb_device_autosuspend_enable(udev); -+ - uvc_trace(UVC_TRACE_PROBE, "UVC device initialized.\n"); - return 0; - diff --git a/debian/patches/series/base b/debian/patches/series/base index fe1a33c6e..01c6e49c8 100644 --- a/debian/patches/series/base +++ b/debian/patches/series/base @@ -68,7 +68,5 @@ + bugfix/x86/sis-agp-Remove-SIS-760-handled-by-amd64-agp.patch + bugfix/x86/amd64-agp-Probe-unknown-AGP-devices-the-right-way.patch + bugfix/all/thinkpad-acpi-fix-backlight.patch -+ bugfix/all/linux-2.6-driver-level-usb-autosuspend.diff -+ bugfix/all/linux-2.6-usb-uvc-autosuspend.diff + bugfix/all/linux-2.6-acpi-sleep-live-sci-live.patch + bugfix/all/fs-explicitly-pass-in-whether-sb-is-pinned-or-not.patch