| From 5c5ed4b6eae9439a0dc51d26269cfcd99261b06d Mon Sep 17 00:00:00 2001 |
| From: Paul Mundt <lethal@linux-sh.org> |
| Date: Fri, 11 Nov 2011 16:11:41 +0900 |
| Subject: sh: clkfwk: Kill off remaining debugfs cruft. |
| |
| Now that all of the named string association with clocks has been |
| migrated to clkdev lookups there's no meaningful named topology that can |
| be constructed for a debugfs tree view. Get rid of the left over bits, |
| and shrink struct clk a bit in the process. |
| |
| Signed-off-by: Paul Mundt <lethal@linux-sh.org> |
| (cherry picked from commit 79e7066415a8b12adbeacc41b3dc44423534b8be) |
| |
| Signed-off-by: Simon Horman <horms@verge.net.au> |
| --- |
| drivers/sh/clk/core.c | 87 ------------------------------------------------ |
| include/linux/sh_clk.h | 1 - |
| 2 files changed, 88 deletions(-) |
| |
| diff --git a/drivers/sh/clk/core.c b/drivers/sh/clk/core.c |
| index 352036b..db257a3 100644 |
| --- a/drivers/sh/clk/core.c |
| +++ b/drivers/sh/clk/core.c |
| @@ -25,7 +25,6 @@ |
| #include <linux/seq_file.h> |
| #include <linux/err.h> |
| #include <linux/io.h> |
| -#include <linux/debugfs.h> |
| #include <linux/cpufreq.h> |
| #include <linux/clk.h> |
| #include <linux/sh_clk.h> |
| @@ -225,9 +224,6 @@ int clk_reparent(struct clk *child, struct clk *parent) |
| list_add(&child->sibling, &parent->children); |
| child->parent = parent; |
| |
| - /* now do the debugfs renaming to reattach the child |
| - to the proper parent */ |
| - |
| return 0; |
| } |
| |
| @@ -685,89 +681,6 @@ static int __init clk_syscore_init(void) |
| subsys_initcall(clk_syscore_init); |
| #endif |
| |
| -/* |
| - * debugfs support to trace clock tree hierarchy and attributes |
| - */ |
| -static struct dentry *clk_debugfs_root; |
| - |
| -static int clk_debugfs_register_one(struct clk *c) |
| -{ |
| - int err; |
| - struct dentry *d; |
| - struct clk *pa = c->parent; |
| - char s[255]; |
| - char *p = s; |
| - |
| - p += sprintf(p, "%p", c); |
| - d = debugfs_create_dir(s, pa ? pa->dentry : clk_debugfs_root); |
| - if (!d) |
| - return -ENOMEM; |
| - c->dentry = d; |
| - |
| - d = debugfs_create_u8("usecount", S_IRUGO, c->dentry, (u8 *)&c->usecount); |
| - if (!d) { |
| - err = -ENOMEM; |
| - goto err_out; |
| - } |
| - d = debugfs_create_u32("rate", S_IRUGO, c->dentry, (u32 *)&c->rate); |
| - if (!d) { |
| - err = -ENOMEM; |
| - goto err_out; |
| - } |
| - d = debugfs_create_x32("flags", S_IRUGO, c->dentry, (u32 *)&c->flags); |
| - if (!d) { |
| - err = -ENOMEM; |
| - goto err_out; |
| - } |
| - return 0; |
| - |
| -err_out: |
| - debugfs_remove_recursive(c->dentry); |
| - return err; |
| -} |
| - |
| -static int clk_debugfs_register(struct clk *c) |
| -{ |
| - int err; |
| - struct clk *pa = c->parent; |
| - |
| - if (pa && !pa->dentry) { |
| - err = clk_debugfs_register(pa); |
| - if (err) |
| - return err; |
| - } |
| - |
| - if (!c->dentry) { |
| - err = clk_debugfs_register_one(c); |
| - if (err) |
| - return err; |
| - } |
| - return 0; |
| -} |
| - |
| -static int __init clk_debugfs_init(void) |
| -{ |
| - struct clk *c; |
| - struct dentry *d; |
| - int err; |
| - |
| - d = debugfs_create_dir("clock", NULL); |
| - if (!d) |
| - return -ENOMEM; |
| - clk_debugfs_root = d; |
| - |
| - list_for_each_entry(c, &clock_list, node) { |
| - err = clk_debugfs_register(c); |
| - if (err) |
| - goto err_out; |
| - } |
| - return 0; |
| -err_out: |
| - debugfs_remove_recursive(clk_debugfs_root); |
| - return err; |
| -} |
| -late_initcall(clk_debugfs_init); |
| - |
| static int __init clk_late_init(void) |
| { |
| unsigned long flags; |
| diff --git a/include/linux/sh_clk.h b/include/linux/sh_clk.h |
| index 9237c29..a20831c 100644 |
| --- a/include/linux/sh_clk.h |
| +++ b/include/linux/sh_clk.h |
| @@ -52,7 +52,6 @@ struct clk { |
| |
| unsigned long arch_flags; |
| void *priv; |
| - struct dentry *dentry; |
| struct clk_mapping *mapping; |
| struct cpufreq_frequency_table *freq_table; |
| unsigned int nr_freqs; |
| -- |
| 1.7.10 |
| |