aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-06-28 14:33:00 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-07-23 19:35:17 -0400
commit374f4bfdf5b6a37a641c13ef22e0bbb42e0b3ac7 (patch)
treea53305cc023155b9e8e0cd0f3e2f7c1d0fef203c /drivers/usb
parent2809508d3b63c9fedf8daf23d08dd61f40a761f4 (diff)
USB: isp1362: remove _DBG() usage
If you want a debug call, just make it, so move to using the already-there DBG() call. No need to make things more complex than they really need to be. Acked-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/host/isp1362-hcd.c30
-rw-r--r--drivers/usb/host/isp1362.h6
2 files changed, 15 insertions, 21 deletions
diff --git a/drivers/usb/host/isp1362-hcd.c b/drivers/usb/host/isp1362-hcd.c
index c747ba35f731..428d184ceb33 100644
--- a/drivers/usb/host/isp1362-hcd.c
+++ b/drivers/usb/host/isp1362-hcd.c
@@ -1573,12 +1573,12 @@ static int isp1362_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue,
1573 DBG(0, "ClearHubFeature: "); 1573 DBG(0, "ClearHubFeature: ");
1574 switch (wValue) { 1574 switch (wValue) {
1575 case C_HUB_OVER_CURRENT: 1575 case C_HUB_OVER_CURRENT:
1576 _DBG(0, "C_HUB_OVER_CURRENT\n"); 1576 DBG(0, "C_HUB_OVER_CURRENT\n");
1577 spin_lock_irqsave(&isp1362_hcd->lock, flags); 1577 spin_lock_irqsave(&isp1362_hcd->lock, flags);
1578 isp1362_write_reg32(isp1362_hcd, HCRHSTATUS, RH_HS_OCIC); 1578 isp1362_write_reg32(isp1362_hcd, HCRHSTATUS, RH_HS_OCIC);
1579 spin_unlock_irqrestore(&isp1362_hcd->lock, flags); 1579 spin_unlock_irqrestore(&isp1362_hcd->lock, flags);
1580 case C_HUB_LOCAL_POWER: 1580 case C_HUB_LOCAL_POWER:
1581 _DBG(0, "C_HUB_LOCAL_POWER\n"); 1581 DBG(0, "C_HUB_LOCAL_POWER\n");
1582 break; 1582 break;
1583 default: 1583 default:
1584 goto error; 1584 goto error;
@@ -1589,7 +1589,7 @@ static int isp1362_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue,
1589 switch (wValue) { 1589 switch (wValue) {
1590 case C_HUB_OVER_CURRENT: 1590 case C_HUB_OVER_CURRENT:
1591 case C_HUB_LOCAL_POWER: 1591 case C_HUB_LOCAL_POWER:
1592 _DBG(0, "C_HUB_OVER_CURRENT or C_HUB_LOCAL_POWER\n"); 1592 DBG(0, "C_HUB_OVER_CURRENT or C_HUB_LOCAL_POWER\n");
1593 break; 1593 break;
1594 default: 1594 default:
1595 goto error; 1595 goto error;
@@ -1620,36 +1620,36 @@ static int isp1362_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue,
1620 1620
1621 switch (wValue) { 1621 switch (wValue) {
1622 case USB_PORT_FEAT_ENABLE: 1622 case USB_PORT_FEAT_ENABLE:
1623 _DBG(0, "USB_PORT_FEAT_ENABLE\n"); 1623 DBG(0, "USB_PORT_FEAT_ENABLE\n");
1624 tmp = RH_PS_CCS; 1624 tmp = RH_PS_CCS;
1625 break; 1625 break;
1626 case USB_PORT_FEAT_C_ENABLE: 1626 case USB_PORT_FEAT_C_ENABLE:
1627 _DBG(0, "USB_PORT_FEAT_C_ENABLE\n"); 1627 DBG(0, "USB_PORT_FEAT_C_ENABLE\n");
1628 tmp = RH_PS_PESC; 1628 tmp = RH_PS_PESC;
1629 break; 1629 break;
1630 case USB_PORT_FEAT_SUSPEND: 1630 case USB_PORT_FEAT_SUSPEND:
1631 _DBG(0, "USB_PORT_FEAT_SUSPEND\n"); 1631 DBG(0, "USB_PORT_FEAT_SUSPEND\n");
1632 tmp = RH_PS_POCI; 1632 tmp = RH_PS_POCI;
1633 break; 1633 break;
1634 case USB_PORT_FEAT_C_SUSPEND: 1634 case USB_PORT_FEAT_C_SUSPEND:
1635 _DBG(0, "USB_PORT_FEAT_C_SUSPEND\n"); 1635 DBG(0, "USB_PORT_FEAT_C_SUSPEND\n");
1636 tmp = RH_PS_PSSC; 1636 tmp = RH_PS_PSSC;
1637 break; 1637 break;
1638 case USB_PORT_FEAT_POWER: 1638 case USB_PORT_FEAT_POWER:
1639 _DBG(0, "USB_PORT_FEAT_POWER\n"); 1639 DBG(0, "USB_PORT_FEAT_POWER\n");
1640 tmp = RH_PS_LSDA; 1640 tmp = RH_PS_LSDA;
1641 1641
1642 break; 1642 break;
1643 case USB_PORT_FEAT_C_CONNECTION: 1643 case USB_PORT_FEAT_C_CONNECTION:
1644 _DBG(0, "USB_PORT_FEAT_C_CONNECTION\n"); 1644 DBG(0, "USB_PORT_FEAT_C_CONNECTION\n");
1645 tmp = RH_PS_CSC; 1645 tmp = RH_PS_CSC;
1646 break; 1646 break;
1647 case USB_PORT_FEAT_C_OVER_CURRENT: 1647 case USB_PORT_FEAT_C_OVER_CURRENT:
1648 _DBG(0, "USB_PORT_FEAT_C_OVER_CURRENT\n"); 1648 DBG(0, "USB_PORT_FEAT_C_OVER_CURRENT\n");
1649 tmp = RH_PS_OCIC; 1649 tmp = RH_PS_OCIC;
1650 break; 1650 break;
1651 case USB_PORT_FEAT_C_RESET: 1651 case USB_PORT_FEAT_C_RESET:
1652 _DBG(0, "USB_PORT_FEAT_C_RESET\n"); 1652 DBG(0, "USB_PORT_FEAT_C_RESET\n");
1653 tmp = RH_PS_PRSC; 1653 tmp = RH_PS_PRSC;
1654 break; 1654 break;
1655 default: 1655 default:
@@ -1669,7 +1669,7 @@ static int isp1362_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue,
1669 wIndex--; 1669 wIndex--;
1670 switch (wValue) { 1670 switch (wValue) {
1671 case USB_PORT_FEAT_SUSPEND: 1671 case USB_PORT_FEAT_SUSPEND:
1672 _DBG(0, "USB_PORT_FEAT_SUSPEND\n"); 1672 DBG(0, "USB_PORT_FEAT_SUSPEND\n");
1673 spin_lock_irqsave(&isp1362_hcd->lock, flags); 1673 spin_lock_irqsave(&isp1362_hcd->lock, flags);
1674 isp1362_write_reg32(isp1362_hcd, HCRHPORT1 + wIndex, RH_PS_PSS); 1674 isp1362_write_reg32(isp1362_hcd, HCRHPORT1 + wIndex, RH_PS_PSS);
1675 isp1362_hcd->rhport[wIndex] = 1675 isp1362_hcd->rhport[wIndex] =
@@ -1677,7 +1677,7 @@ static int isp1362_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue,
1677 spin_unlock_irqrestore(&isp1362_hcd->lock, flags); 1677 spin_unlock_irqrestore(&isp1362_hcd->lock, flags);
1678 break; 1678 break;
1679 case USB_PORT_FEAT_POWER: 1679 case USB_PORT_FEAT_POWER:
1680 _DBG(0, "USB_PORT_FEAT_POWER\n"); 1680 DBG(0, "USB_PORT_FEAT_POWER\n");
1681 spin_lock_irqsave(&isp1362_hcd->lock, flags); 1681 spin_lock_irqsave(&isp1362_hcd->lock, flags);
1682 isp1362_write_reg32(isp1362_hcd, HCRHPORT1 + wIndex, RH_PS_PPS); 1682 isp1362_write_reg32(isp1362_hcd, HCRHPORT1 + wIndex, RH_PS_PPS);
1683 isp1362_hcd->rhport[wIndex] = 1683 isp1362_hcd->rhport[wIndex] =
@@ -1685,7 +1685,7 @@ static int isp1362_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue,
1685 spin_unlock_irqrestore(&isp1362_hcd->lock, flags); 1685 spin_unlock_irqrestore(&isp1362_hcd->lock, flags);
1686 break; 1686 break;
1687 case USB_PORT_FEAT_RESET: 1687 case USB_PORT_FEAT_RESET:
1688 _DBG(0, "USB_PORT_FEAT_RESET\n"); 1688 DBG(0, "USB_PORT_FEAT_RESET\n");
1689 spin_lock_irqsave(&isp1362_hcd->lock, flags); 1689 spin_lock_irqsave(&isp1362_hcd->lock, flags);
1690 1690
1691 t1 = jiffies + msecs_to_jiffies(USB_RESET_WIDTH); 1691 t1 = jiffies + msecs_to_jiffies(USB_RESET_WIDTH);
@@ -1719,7 +1719,7 @@ static int isp1362_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue,
1719 default: 1719 default:
1720 error: 1720 error:
1721 /* "protocol stall" on error */ 1721 /* "protocol stall" on error */
1722 _DBG(0, "PROTOCOL STALL\n"); 1722 DBG(0, "PROTOCOL STALL\n");
1723 retval = -EPIPE; 1723 retval = -EPIPE;
1724 } 1724 }
1725 1725
diff --git a/drivers/usb/host/isp1362.h b/drivers/usb/host/isp1362.h
index e0f6f922052d..d36a90868900 100644
--- a/drivers/usb/host/isp1362.h
+++ b/drivers/usb/host/isp1362.h
@@ -588,14 +588,8 @@ static inline struct usb_hcd *isp1362_hcd_to_hcd(struct isp1362_hcd *isp1362_hcd
588 if (dbg_level > level) \ 588 if (dbg_level > level) \
589 pr_debug(fmt); \ 589 pr_debug(fmt); \
590 } while (0) 590 } while (0)
591#define _DBG(level, fmt...) \
592 do { \
593 if (dbg_level > level) \
594 printk(fmt); \
595 } while (0)
596#else 591#else
597#define DBG(fmt...) do {} while (0) 592#define DBG(fmt...) do {} while (0)
598#define _DBG DBG
599#endif 593#endif
600 594
601#ifdef VERBOSE 595#ifdef VERBOSE