aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-06-28 14:32:55 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-07-23 19:33:23 -0400
commit523e531ea694eadf2957ee207bb4e0681e837057 (patch)
treec68bc19a610801896fdd928cf9e1ed15570fba0d
parent2c21c985f1bc9f9b19ce258f38bb400ced3c7309 (diff)
USB: phy: remove custom DBG macro
Use the in-kernel pr_debug() calls instead of trying to roll your own DBG macro. This means the dynamic debugging calls now work here, and there is no dependency on CONFIG_USB_DEBUG for the phy code anymore. Acked-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/usb/phy/phy-fsl-usb.c6
-rw-r--r--drivers/usb/phy/phy-fsm-usb.h11
-rw-r--r--drivers/usb/phy/phy-isp1301-omap.c6
3 files changed, 6 insertions, 17 deletions
diff --git a/drivers/usb/phy/phy-fsl-usb.c b/drivers/usb/phy/phy-fsl-usb.c
index e771bafb9f1d..181bfb10a57a 100644
--- a/drivers/usb/phy/phy-fsl-usb.c
+++ b/drivers/usb/phy/phy-fsl-usb.c
@@ -611,7 +611,7 @@ static int fsl_otg_set_peripheral(struct usb_otg *otg,
611 otg_dev->fsm.b_bus_req = 1; 611 otg_dev->fsm.b_bus_req = 1;
612 612
613 /* start the gadget right away if the ID pin says Mini-B */ 613 /* start the gadget right away if the ID pin says Mini-B */
614 DBG("ID pin=%d\n", otg_dev->fsm.id); 614 pr_debug("ID pin=%d\n", otg_dev->fsm.id);
615 if (otg_dev->fsm.id == 1) { 615 if (otg_dev->fsm.id == 1) {
616 fsl_otg_start_host(&otg_dev->fsm, 0); 616 fsl_otg_start_host(&otg_dev->fsm, 0);
617 otg_drv_vbus(&otg_dev->fsm, 0); 617 otg_drv_vbus(&otg_dev->fsm, 0);
@@ -684,7 +684,7 @@ static int fsl_otg_start_hnp(struct usb_otg *otg)
684 if (otg_dev != fsl_otg_dev) 684 if (otg_dev != fsl_otg_dev)
685 return -ENODEV; 685 return -ENODEV;
686 686
687 DBG("start_hnp...n"); 687 pr_debug("start_hnp...\n");
688 688
689 /* clear a_bus_req to enter a_suspend state */ 689 /* clear a_bus_req to enter a_suspend state */
690 otg_dev->fsm.a_bus_req = 0; 690 otg_dev->fsm.a_bus_req = 0;
@@ -941,7 +941,7 @@ int usb_otg_start(struct platform_device *pdev)
941 p_otg->fsm.id = 0; 941 p_otg->fsm.id = 0;
942 } 942 }
943 943
944 DBG("initial ID pin=%d\n", p_otg->fsm.id); 944 pr_debug("initial ID pin=%d\n", p_otg->fsm.id);
945 945
946 /* enable OTG ID pin interrupt */ 946 /* enable OTG ID pin interrupt */
947 temp = fsl_readl(&p_otg->dr_mem_map->otgsc); 947 temp = fsl_readl(&p_otg->dr_mem_map->otgsc);
diff --git a/drivers/usb/phy/phy-fsm-usb.h b/drivers/usb/phy/phy-fsm-usb.h
index c30a2e1d9e46..fbe586206f33 100644
--- a/drivers/usb/phy/phy-fsm-usb.h
+++ b/drivers/usb/phy/phy-fsm-usb.h
@@ -15,18 +15,11 @@
15 * 675 Mass Ave, Cambridge, MA 02139, USA. 15 * 675 Mass Ave, Cambridge, MA 02139, USA.
16 */ 16 */
17 17
18#undef DEBUG
19#undef VERBOSE 18#undef VERBOSE
20 19
21#ifdef DEBUG
22#define DBG(fmt, args...) printk(KERN_DEBUG "[%s] " fmt , \
23 __func__, ## args)
24#else
25#define DBG(fmt, args...) do {} while (0)
26#endif
27
28#ifdef VERBOSE 20#ifdef VERBOSE
29#define VDBG DBG 21#define VDBG(fmt, args...) pr_debug("[%s] " fmt , \
22 __func__, ## args)
30#else 23#else
31#define VDBG(stuff...) do {} while (0) 24#define VDBG(stuff...) do {} while (0)
32#endif 25#endif
diff --git a/drivers/usb/phy/phy-isp1301-omap.c b/drivers/usb/phy/phy-isp1301-omap.c
index ae481afcb3ec..d3a5160e4cc7 100644
--- a/drivers/usb/phy/phy-isp1301-omap.c
+++ b/drivers/usb/phy/phy-isp1301-omap.c
@@ -40,9 +40,7 @@
40 40
41#include <mach/usb.h> 41#include <mach/usb.h>
42 42
43#ifndef DEBUG 43#undef VERBOSE
44#undef VERBOSE
45#endif
46 44
47 45
48#define DRIVER_VERSION "24 August 2004" 46#define DRIVER_VERSION "24 August 2004"
@@ -387,7 +385,6 @@ static void b_idle(struct isp1301 *isp, const char *tag)
387static void 385static void
388dump_regs(struct isp1301 *isp, const char *label) 386dump_regs(struct isp1301 *isp, const char *label)
389{ 387{
390#ifdef DEBUG
391 u8 ctrl = isp1301_get_u8(isp, ISP1301_OTG_CONTROL_1); 388 u8 ctrl = isp1301_get_u8(isp, ISP1301_OTG_CONTROL_1);
392 u8 status = isp1301_get_u8(isp, ISP1301_OTG_STATUS); 389 u8 status = isp1301_get_u8(isp, ISP1301_OTG_STATUS);
393 u8 src = isp1301_get_u8(isp, ISP1301_INTERRUPT_SOURCE); 390 u8 src = isp1301_get_u8(isp, ISP1301_INTERRUPT_SOURCE);
@@ -396,7 +393,6 @@ dump_regs(struct isp1301 *isp, const char *label)
396 omap_readl(OTG_CTRL), label, state_name(isp), 393 omap_readl(OTG_CTRL), label, state_name(isp),
397 ctrl, status, src); 394 ctrl, status, src);
398 /* mode control and irq enables don't change much */ 395 /* mode control and irq enables don't change much */
399#endif
400} 396}
401 397
402/*-------------------------------------------------------------------------*/ 398/*-------------------------------------------------------------------------*/