]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
usb: chipidea: support debugfs without CONFIG_USB_CHIPIDEA_DEBUG
authorPeter Chen <peter.chen@freescale.com>
Fri, 23 Oct 2015 02:33:58 +0000 (10:33 +0800)
committerPeter Chen <peter.chen@freescale.com>
Wed, 28 Oct 2015 05:56:50 +0000 (13:56 +0800)
Since we need to mount debugfs to show/store the things we
want to debug, it is duplicated to add another configuration
to enable it. Meanwhile, with CONFIG_USB_CHIPIDEA_DEBUG,
we can't support chipidea debugfs at runtime.

Signed-off-by: Peter Chen <peter.chen@freescale.com>
Cc: Jun Li <jun.li@freescale.com>
drivers/usb/chipidea/Makefile
drivers/usb/chipidea/ci.h
drivers/usb/chipidea/core.c
drivers/usb/chipidea/debug.c
drivers/usb/chipidea/debug.h [deleted file]
drivers/usb/chipidea/udc.c

index 4decb12f25786221690c5adca6bb4448512039b1..c437d5f1a0d5242d394a7344123b21a21aba9634 100644 (file)
@@ -2,10 +2,9 @@ ccflags-$(CONFIG_USB_CHIPIDEA_DEBUG) := -DDEBUG
 
 obj-$(CONFIG_USB_CHIPIDEA)             += ci_hdrc.o
 
-ci_hdrc-y                              := core.o otg.o
+ci_hdrc-y                              := core.o otg.o debug.o
 ci_hdrc-$(CONFIG_USB_CHIPIDEA_UDC)     += udc.o
 ci_hdrc-$(CONFIG_USB_CHIPIDEA_HOST)    += host.o
-ci_hdrc-$(CONFIG_USB_CHIPIDEA_DEBUG)   += debug.o
 ci_hdrc-$(CONFIG_USB_OTG_FSM)          += otg_fsm.o
 
 # Glue/Bridge layers go here
index 41d7cf6d63ba32a240add0eaa7c01f63fa8b1f28..cd414559040f12224bda60a0dd0a9e12b597241c 100644 (file)
@@ -433,4 +433,7 @@ int hw_wait_reg(struct ci_hdrc *ci, enum ci_hw_regs reg, u32 mask,
 
 void ci_platform_configure(struct ci_hdrc *ci);
 
+int dbg_create_files(struct ci_hdrc *ci);
+
+void dbg_remove_files(struct ci_hdrc *ci);
 #endif /* __DRIVERS_USB_CHIPIDEA_CI_H */
index 965d0e240dcb27674151e2073b984c89c90eb7ed..18e77e02842b951efada16492a909e17c7c8bfcf 100644 (file)
@@ -71,7 +71,6 @@
 #include "udc.h"
 #include "bits.h"
 #include "host.h"
-#include "debug.h"
 #include "otg.h"
 #include "otg_fsm.h"
 
index 080b7be3daf034939bd12c509353c041b6027f49..244e8cb1b90491b2da0bdb45b4e379690da70bdd 100644 (file)
@@ -15,7 +15,6 @@
 #include "ci.h"
 #include "udc.h"
 #include "bits.h"
-#include "debug.h"
 #include "otg.h"
 
 /**
diff --git a/drivers/usb/chipidea/debug.h b/drivers/usb/chipidea/debug.h
deleted file mode 100644 (file)
index e16478c..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * debug.h - ChipIdea USB driver debug interfaces
- *
- * Copyright (C) 2008 Chipidea - MIPS Technologies, Inc. All rights reserved.
- *
- * Author: David Lopo
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2 as
- * published by the Free Software Foundation.
- */
-
-#ifndef __DRIVERS_USB_CHIPIDEA_DEBUG_H
-#define __DRIVERS_USB_CHIPIDEA_DEBUG_H
-
-#ifdef CONFIG_USB_CHIPIDEA_DEBUG
-int dbg_create_files(struct ci_hdrc *ci);
-void dbg_remove_files(struct ci_hdrc *ci);
-#else
-static inline int dbg_create_files(struct ci_hdrc *ci)
-{
-       return 0;
-}
-
-static inline void dbg_remove_files(struct ci_hdrc *ci)
-{
-}
-#endif
-
-#endif /* __DRIVERS_USB_CHIPIDEA_DEBUG_H */
index d4750f258f3df3346ac156fe7401339cd36dface..1473360cb74b2b2c672112372e38470810dcbbdb 100644 (file)
@@ -26,7 +26,6 @@
 #include "ci.h"
 #include "udc.h"
 #include "bits.h"
-#include "debug.h"
 #include "otg.h"
 #include "otg_fsm.h"