diff options
author | Sarah Sharp <sarah.a.sharp@linux.intel.com> | 2010-10-15 17:59:15 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-10-22 13:22:15 -0400 |
commit | 436a389096e1feda2c382cad83b6a8d6de8615a0 (patch) | |
tree | 6c68d7e5ab037deef677e35a8b1bfc425e63694f /drivers | |
parent | 39eb234874af4322f85e2a29e3aad33ce68cbed5 (diff) |
usb: Fix linker errors with CONFIG_PM=n
Fix these linker errors when CONFIG_PM=n:
ERROR: "xhci_bus_resume" [drivers/usb/host/xhci-hcd.ko] undefined!
ERROR: "xhci_bus_suspend" [drivers/usb/host/xhci-hcd.ko] undefined!
Reported-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Acked-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/usb/host/xhci-hub.c | 7 | ||||
-rw-r--r-- | drivers/usb/host/xhci.c | 6 | ||||
-rw-r--r-- | drivers/usb/host/xhci.h | 14 |
3 files changed, 15 insertions, 12 deletions
diff --git a/drivers/usb/host/xhci-hub.c b/drivers/usb/host/xhci-hub.c index 7f2f63cb6c53..fef5a1f9d483 100644 --- a/drivers/usb/host/xhci-hub.c +++ b/drivers/usb/host/xhci-hub.c | |||
@@ -742,9 +742,4 @@ int xhci_bus_resume(struct usb_hcd *hcd) | |||
742 | return 0; | 742 | return 0; |
743 | } | 743 | } |
744 | 744 | ||
745 | #else | 745 | #endif /* CONFIG_PM */ |
746 | |||
747 | #define xhci_bus_suspend NULL | ||
748 | #define xhci_bus_resume NULL | ||
749 | |||
750 | #endif | ||
diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c index 9dc5be557d92..5d7d4e951ea4 100644 --- a/drivers/usb/host/xhci.c +++ b/drivers/usb/host/xhci.c | |||
@@ -761,12 +761,6 @@ int xhci_resume(struct xhci_hcd *xhci, bool hibernated) | |||
761 | spin_unlock_irq(&xhci->lock); | 761 | spin_unlock_irq(&xhci->lock); |
762 | return 0; | 762 | return 0; |
763 | } | 763 | } |
764 | |||
765 | #else | ||
766 | |||
767 | #define xhci_suspend NULL | ||
768 | #define xhci_resume NULL | ||
769 | |||
770 | #endif /* CONFIG_PM */ | 764 | #endif /* CONFIG_PM */ |
771 | 765 | ||
772 | /*-------------------------------------------------------------------------*/ | 766 | /*-------------------------------------------------------------------------*/ |
diff --git a/drivers/usb/host/xhci.h b/drivers/usb/host/xhci.h index c08928adc524..93d3bf4d213c 100644 --- a/drivers/usb/host/xhci.h +++ b/drivers/usb/host/xhci.h | |||
@@ -1405,8 +1405,15 @@ int xhci_init(struct usb_hcd *hcd); | |||
1405 | int xhci_run(struct usb_hcd *hcd); | 1405 | int xhci_run(struct usb_hcd *hcd); |
1406 | void xhci_stop(struct usb_hcd *hcd); | 1406 | void xhci_stop(struct usb_hcd *hcd); |
1407 | void xhci_shutdown(struct usb_hcd *hcd); | 1407 | void xhci_shutdown(struct usb_hcd *hcd); |
1408 | |||
1409 | #ifdef CONFIG_PM | ||
1408 | int xhci_suspend(struct xhci_hcd *xhci); | 1410 | int xhci_suspend(struct xhci_hcd *xhci); |
1409 | int xhci_resume(struct xhci_hcd *xhci, bool hibernated); | 1411 | int xhci_resume(struct xhci_hcd *xhci, bool hibernated); |
1412 | #else | ||
1413 | #define xhci_suspend NULL | ||
1414 | #define xhci_resume NULL | ||
1415 | #endif | ||
1416 | |||
1410 | int xhci_get_frame(struct usb_hcd *hcd); | 1417 | int xhci_get_frame(struct usb_hcd *hcd); |
1411 | irqreturn_t xhci_irq(struct usb_hcd *hcd); | 1418 | irqreturn_t xhci_irq(struct usb_hcd *hcd); |
1412 | irqreturn_t xhci_msi_irq(int irq, struct usb_hcd *hcd); | 1419 | irqreturn_t xhci_msi_irq(int irq, struct usb_hcd *hcd); |
@@ -1481,8 +1488,15 @@ void xhci_ring_ep_doorbell(struct xhci_hcd *xhci, unsigned int slot_id, | |||
1481 | int xhci_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue, u16 wIndex, | 1488 | int xhci_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue, u16 wIndex, |
1482 | char *buf, u16 wLength); | 1489 | char *buf, u16 wLength); |
1483 | int xhci_hub_status_data(struct usb_hcd *hcd, char *buf); | 1490 | int xhci_hub_status_data(struct usb_hcd *hcd, char *buf); |
1491 | |||
1492 | #ifdef CONFIG_PM | ||
1484 | int xhci_bus_suspend(struct usb_hcd *hcd); | 1493 | int xhci_bus_suspend(struct usb_hcd *hcd); |
1485 | int xhci_bus_resume(struct usb_hcd *hcd); | 1494 | int xhci_bus_resume(struct usb_hcd *hcd); |
1495 | #else | ||
1496 | #define xhci_bus_suspend NULL | ||
1497 | #define xhci_bus_resume NULL | ||
1498 | #endif /* CONFIG_PM */ | ||
1499 | |||
1486 | u32 xhci_port_state_to_neutral(u32 state); | 1500 | u32 xhci_port_state_to_neutral(u32 state); |
1487 | int xhci_find_slot_id_by_port(struct xhci_hcd *xhci, u16 port); | 1501 | int xhci_find_slot_id_by_port(struct xhci_hcd *xhci, u16 port); |
1488 | void xhci_ring_device(struct xhci_hcd *xhci, int slot_id); | 1502 | void xhci_ring_device(struct xhci_hcd *xhci, int slot_id); |