aboutsummaryrefslogtreecommitdiffstats
diff options
-rw-r--r--series48
-rw-r--r--usb-isp1362-move-debug-files-from-proc-to-debugfs.patch127
-rw-r--r--usb-remove-unneeded-idr.h-include.patch47
-rw-r--r--usb-sl811-move-debug-files-from-proc-to-debugfs.patch120
4 files changed, 298 insertions, 44 deletions
diff --git a/series b/series
index 73558083c2418e..64986066db4b23 100644
--- a/series
+++ b/series
@@ -25,6 +25,10 @@ usb-isp1362-remove-config_usb_debug-dependency.patch
usb-isp116x-remove-dependency-on-config_usb_debug.patch
usb-sl811-remove-config_usb_debug-dependency.patch
+usb-remove-unneeded-idr.h-include.patch
+usb-sl811-move-debug-files-from-proc-to-debugfs.patch
+usb-isp1362-move-debug-files-from-proc-to-debugfs.patch
+
cdc-acm.patch
usb-serial-ports-add-minor-and-port-number.patch
usb-serial-idr.patch
@@ -34,47 +38,3 @@ usb-serial-increase-the-number-of-devices-we-support.patch
#gregkh/gkh-version.patch
-#####################################################################
-# Stuff to be merged for 2.6.37
-#####################################################################
-
-#################################
-# Driver core patches for 2.6.37
-#################################
-
-
-#################################
-# TTY patches for 2.6.37
-#################################
-
-
-#################################
-# USB patches for 2.6.37
-#################################
-
-
-#################################
-# Staging patches for 2.6.37
-#################################
-
-
-#####################################################################
-# Stuff to be merged after 2.6.37 is out
-#####################################################################
-
-#############################################
-# Driver core patches for after 2.6.37 is out
-#############################################
-
-#####################################
-# TTY patches for after 2.6.37 is out
-#####################################
-
-###################################
-# USB stuff for after 2.6.37 is out
-###################################
-
-
-# staging stuff for next is now in the staging-next tree on git.kernel.org
-
-
diff --git a/usb-isp1362-move-debug-files-from-proc-to-debugfs.patch b/usb-isp1362-move-debug-files-from-proc-to-debugfs.patch
new file mode 100644
index 00000000000000..ed2cece0f0e113
--- /dev/null
+++ b/usb-isp1362-move-debug-files-from-proc-to-debugfs.patch
@@ -0,0 +1,127 @@
+From foo@baz Tue Jul 2 12:17:06 PDT 2013
+Date: Tue, 02 Jul 2013 12:17:06 -0700
+To: Greg KH <gregkh@linuxfoundation.org>
+From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+Subject: USB: isp1362: move debug files from proc to debugfs
+
+Drivers should not be putting debug files in /proc/ that is what debugfs
+is for, so move the isp1362 driver's debug file to debugfs.
+
+Cc: Felipe Balbi <balbi@ti.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/usb/host/isp1362-hcd.c | 45 ++++++++++-------------------------------
+ drivers/usb/host/isp1362.h | 2 -
+ 2 files changed, 12 insertions(+), 35 deletions(-)
+
+--- a/drivers/usb/host/isp1362-hcd.c
++++ b/drivers/usb/host/isp1362-hcd.c
+@@ -78,6 +78,8 @@
+ #include <linux/io.h>
+ #include <linux/bitmap.h>
+ #include <linux/prefetch.h>
++#include <linux/debugfs.h>
++#include <linux/seq_file.h>
+
+ #include <asm/irq.h>
+ #include <asm/byteorder.h>
+@@ -88,7 +90,6 @@ static int dbg_level;
+ module_param(dbg_level, int, 0644);
+ #else
+ module_param(dbg_level, int, 0);
+-#define STUB_DEBUG_FILE
+ #endif
+
+ #include "../core/usb.h"
+@@ -1907,20 +1908,6 @@ static int isp1362_bus_resume(struct usb
+
+ /*-------------------------------------------------------------------------*/
+
+-#ifdef STUB_DEBUG_FILE
+-
+-static inline void create_debug_file(struct isp1362_hcd *isp1362_hcd)
+-{
+-}
+-static inline void remove_debug_file(struct isp1362_hcd *isp1362_hcd)
+-{
+-}
+-
+-#else
+-
+-#include <linux/proc_fs.h>
+-#include <linux/seq_file.h>
+-
+ static void dump_irq(struct seq_file *s, char *label, u16 mask)
+ {
+ seq_printf(s, "%-15s %04x%s%s%s%s%s%s\n", label, mask,
+@@ -2063,7 +2050,7 @@ static void dump_regs(struct seq_file *s
+ isp1362_read_reg16(isp1362_hcd, HCATLDTCTO));
+ }
+
+-static int proc_isp1362_show(struct seq_file *s, void *unused)
++static int isp1362_show(struct seq_file *s, void *unused)
+ {
+ struct isp1362_hcd *isp1362_hcd = s->private;
+ struct isp1362_ep *ep;
+@@ -2167,41 +2154,31 @@ static int proc_isp1362_show(struct seq_
+ return 0;
+ }
+
+-static int proc_isp1362_open(struct inode *inode, struct file *file)
++static int isp1362_open(struct inode *inode, struct file *file)
+ {
+- return single_open(file, proc_isp1362_show, PDE_DATA(inode));
++ return single_open(file, isp1362_show, PDE_DATA(inode));
+ }
+
+-static const struct file_operations proc_ops = {
+- .open = proc_isp1362_open,
++static const struct file_operations debug_ops = {
++ .open = isp1362_open,
+ .read = seq_read,
+ .llseek = seq_lseek,
+ .release = single_release,
+ };
+
+ /* expect just one isp1362_hcd per system */
+-static const char proc_filename[] = "driver/isp1362";
+-
+ static void create_debug_file(struct isp1362_hcd *isp1362_hcd)
+ {
+- struct proc_dir_entry *pde;
+-
+- pde = proc_create_data(proc_filename, 0, NULL, &proc_ops, isp1362_hcd);
+- if (pde == NULL) {
+- pr_warning("%s: Failed to create debug file '%s'\n", __func__, proc_filename);
+- return;
+- }
+- isp1362_hcd->pde = pde;
++ isp1362_hcd->debug_file = debugfs_create_file("isp1362", S_IRUGO,
++ usb_debug_root,
++ isp1362_hcd, &debug_ops);
+ }
+
+ static void remove_debug_file(struct isp1362_hcd *isp1362_hcd)
+ {
+- if (isp1362_hcd->pde)
+- remove_proc_entry(proc_filename, NULL);
++ debugfs_remove(isp1362_hcd->debug_file);
+ }
+
+-#endif
+-
+ /*-------------------------------------------------------------------------*/
+
+ static void __isp1362_sw_reset(struct isp1362_hcd *isp1362_hcd)
+--- a/drivers/usb/host/isp1362.h
++++ b/drivers/usb/host/isp1362.h
+@@ -480,7 +480,7 @@ struct isp1362_hcd {
+
+ struct isp1362_platform_data *board;
+
+- struct proc_dir_entry *pde;
++ struct dentry *debug_file;
+ unsigned long stat1, stat2, stat4, stat8, stat16;
+
+ /* HC registers */
diff --git a/usb-remove-unneeded-idr.h-include.patch b/usb-remove-unneeded-idr.h-include.patch
new file mode 100644
index 00000000000000..52888436737f16
--- /dev/null
+++ b/usb-remove-unneeded-idr.h-include.patch
@@ -0,0 +1,47 @@
+From foo@baz Tue Jul 2 12:19:50 PDT 2013
+Date: Tue, 02 Jul 2013 12:19:50 -0700
+To: Greg KH <gregkh@linuxfoundation.org>
+From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+Subject: USB: remove unneeded idr.h include
+
+None of these USB files need idr.h, so don't include it.
+
+Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
+Cc: Felipe Balbi <balbi@ti.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/usb/chipidea/core.c | 1 -
+ drivers/usb/core/endpoint.c | 1 -
+ drivers/usb/musb/musb_core.c | 1 -
+ 3 files changed, 3 deletions(-)
+
+--- a/drivers/usb/chipidea/core.c
++++ b/drivers/usb/chipidea/core.c
+@@ -54,7 +54,6 @@
+ #include <linux/dma-mapping.h>
+ #include <linux/platform_device.h>
+ #include <linux/module.h>
+-#include <linux/idr.h>
+ #include <linux/interrupt.h>
+ #include <linux/io.h>
+ #include <linux/kernel.h>
+--- a/drivers/usb/core/endpoint.c
++++ b/drivers/usb/core/endpoint.c
+@@ -12,7 +12,6 @@
+ #include <linux/kernel.h>
+ #include <linux/spinlock.h>
+ #include <linux/slab.h>
+-#include <linux/idr.h>
+ #include <linux/usb.h>
+ #include "usb.h"
+
+--- a/drivers/usb/musb/musb_core.c
++++ b/drivers/usb/musb/musb_core.c
+@@ -99,7 +99,6 @@
+ #include <linux/prefetch.h>
+ #include <linux/platform_device.h>
+ #include <linux/io.h>
+-#include <linux/idr.h>
+ #include <linux/dma-mapping.h>
+
+ #include "musb_core.h"
diff --git a/usb-sl811-move-debug-files-from-proc-to-debugfs.patch b/usb-sl811-move-debug-files-from-proc-to-debugfs.patch
new file mode 100644
index 00000000000000..a18f57fd2a479f
--- /dev/null
+++ b/usb-sl811-move-debug-files-from-proc-to-debugfs.patch
@@ -0,0 +1,120 @@
+From foo@baz Tue Jul 2 12:18:43 PDT 2013
+Date: Tue, 02 Jul 2013 12:18:43 -0700
+To: Greg KH <gregkh@linuxfoundation.org>
+From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+Subject: USB: sl811: move debug files from proc to debugfs
+
+Drivers should not be putting debug files in /proc/ that is what debugfs
+is for, so move the sl811 driver's debug file to debugfs.
+
+Cc: Felipe Balbi <balbi@ti.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/usb/host/sl811-hcd.c | 38 +++++++++++---------------------------
+ drivers/usb/host/sl811.h | 2 +-
+ 2 files changed, 12 insertions(+), 28 deletions(-)
+
+--- a/drivers/usb/host/sl811-hcd.c
++++ b/drivers/usb/host/sl811-hcd.c
+@@ -48,6 +48,8 @@
+ #include <linux/usb/hcd.h>
+ #include <linux/platform_device.h>
+ #include <linux/prefetch.h>
++#include <linux/debugfs.h>
++#include <linux/seq_file.h>
+
+ #include <asm/io.h>
+ #include <asm/irq.h>
+@@ -63,11 +65,6 @@ MODULE_ALIAS("platform:sl811-hcd");
+
+ #define DRIVER_VERSION "19 May 2005"
+
+-
+-#ifndef DEBUG
+-# define STUB_DEBUG_FILE
+-#endif
+-
+ /* for now, use only one transfer register bank */
+ #undef USE_B
+
+@@ -1373,16 +1370,6 @@ sl811h_bus_resume(struct usb_hcd *hcd)
+
+ /*-------------------------------------------------------------------------*/
+
+-#ifdef STUB_DEBUG_FILE
+-
+-static inline void create_debug_file(struct sl811 *sl811) { }
+-static inline void remove_debug_file(struct sl811 *sl811) { }
+-
+-#else
+-
+-#include <linux/proc_fs.h>
+-#include <linux/seq_file.h>
+-
+ static void dump_irq(struct seq_file *s, char *label, u8 mask)
+ {
+ seq_printf(s, "%s %02x%s%s%s%s%s%s\n", label, mask,
+@@ -1394,7 +1381,7 @@ static void dump_irq(struct seq_file *s,
+ (mask & SL11H_INTMASK_DP) ? " dp" : "");
+ }
+
+-static int proc_sl811h_show(struct seq_file *s, void *unused)
++static int sl811h_show(struct seq_file *s, void *unused)
+ {
+ struct sl811 *sl811 = s->private;
+ struct sl811h_ep *ep;
+@@ -1505,34 +1492,31 @@ static int proc_sl811h_show(struct seq_f
+ return 0;
+ }
+
+-static int proc_sl811h_open(struct inode *inode, struct file *file)
++static int sl811h_open(struct inode *inode, struct file *file)
+ {
+- return single_open(file, proc_sl811h_show, PDE_DATA(inode));
++ return single_open(file, sl811h_show, inode->i_private);
+ }
+
+-static const struct file_operations proc_ops = {
+- .open = proc_sl811h_open,
++static const struct file_operations debug_ops = {
++ .open = sl811h_open,
+ .read = seq_read,
+ .llseek = seq_lseek,
+ .release = single_release,
+ };
+
+ /* expect just one sl811 per system */
+-static const char proc_filename[] = "driver/sl811h";
+-
+ static void create_debug_file(struct sl811 *sl811)
+ {
+- sl811->pde = proc_create_data(proc_filename, 0, NULL, &proc_ops, sl811);
++ sl811->debug_file = debugfs_create_file("sl811h", S_IRUGO,
++ usb_debug_root, sl811,
++ &debug_ops);
+ }
+
+ static void remove_debug_file(struct sl811 *sl811)
+ {
+- if (sl811->pde)
+- remove_proc_entry(proc_filename, NULL);
++ debugfs_remove(sl811->debug_file);
+ }
+
+-#endif
+-
+ /*-------------------------------------------------------------------------*/
+
+ static void
+--- a/drivers/usb/host/sl811.h
++++ b/drivers/usb/host/sl811.h
+@@ -122,7 +122,7 @@ struct sl811 {
+ void __iomem *addr_reg;
+ void __iomem *data_reg;
+ struct sl811_platform_data *board;
+- struct proc_dir_entry *pde;
++ struct dentry *debug_file;
+
+ unsigned long stat_insrmv;
+ unsigned long stat_wake;