Re: [linux-usb-devel] [BK PATCH] USB changes for 2.6.6
From: David Brownell (david-b_at_pacbell.net)
Date: 05/16/04
- Previous message: aeriksson_at_fastmail.fm: "Re: [2.6.6] Synaptics driver is 'jumpy'"
- In reply to: Linus Torvalds: "Re: [linux-usb-devel] [BK PATCH] USB changes for 2.6.6"
- Next in thread: Linus Torvalds: "Re: [linux-usb-devel] [BK PATCH] USB changes for 2.6.6"
- Reply: Linus Torvalds: "Re: [linux-usb-devel] [BK PATCH] USB changes for 2.6.6"
- Reply: Greg KH: "Re: [linux-usb-devel] [BK PATCH] USB changes for 2.6.6"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 16 May 2004 10:51:07 -0700 To: Linus Torvalds <torvalds@osdl.org>
Linus Torvalds wrote:
> ... would never have
> compiled with debugging on anyway.
Speaking of which, please consider merging this. It
missed Greg's push on Friday, but it's needed to build
OHCI and EHCI with CONFIG_USB_DEBUG when !CONFIG_PM.
By request, this adds (and uses) a new API call to hide
the necessary #ifdef once, rather than repeat it in every
driver. It's an accessor for a field only exists when
#ifdef CONFIG_PM. These particular references prevent
dumping registers when that part of the chip suspended.
- Dave
--- 1.13/include/linux/pm.h Thu Aug 21 11:47:27 2003
+++ edited/include/linux/pm.h Sun May 16 10:49:54 2004
@@ -238,6 +238,16 @@
#endif
};
+static inline u32
+device_pm_state(struct dev_pm_info *info)
+{
+#ifdef CONFIG_PM
+ return info->power_state;
+#else
+ return 0;
+#endif
+}
+
extern void device_pm_set_parent(struct device * dev, struct device * parent);
extern int device_suspend(u32 state);
--- 1.33/drivers/usb/host/ehci-dbg.c Fri May 7 12:48:33 2004
+++ edited/drivers/usb/host/ehci-dbg.c Sun May 16 10:49:54 2004
@@ -639,7 +639,7 @@
spin_lock_irqsave (&ehci->lock, flags);
- if (bus->controller->power.power_state) {
+ if (device_pm_state (&bus->controller->power)) {
size = scnprintf (next, size,
"bus %s, device %s (driver " DRIVER_VERSION ")\n"
"SUSPENDED (no register access)\n",
--- 1.26/drivers/usb/host/ohci-dbg.c Tue May 11 13:17:33 2004
+++ edited/drivers/usb/host/ohci-dbg.c Sun May 16 10:49:54 2004
@@ -623,7 +623,7 @@
hcd->self.controller->bus_id,
hcd_name);
- if (bus->controller->power.power_state) {
+ if (device_pm_state (&bus->controller->power)) {
size -= scnprintf (next, size,
"SUSPENDED (no register access)\n");
goto done;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- Previous message: aeriksson_at_fastmail.fm: "Re: [2.6.6] Synaptics driver is 'jumpy'"
- In reply to: Linus Torvalds: "Re: [linux-usb-devel] [BK PATCH] USB changes for 2.6.6"
- Next in thread: Linus Torvalds: "Re: [linux-usb-devel] [BK PATCH] USB changes for 2.6.6"
- Reply: Linus Torvalds: "Re: [linux-usb-devel] [BK PATCH] USB changes for 2.6.6"
- Reply: Greg KH: "Re: [linux-usb-devel] [BK PATCH] USB changes for 2.6.6"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|