aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh
diff options
context:
space:
mode:
authorAdrian Bunk <bunk@kernel.org>2008-06-17 20:36:50 -0400
committerPaul Mundt <lethal@linux-sh.org>2008-07-28 05:10:30 -0400
commit4c1cfab1e0f9a41246cfdcca78f3700fb67f0a5c (patch)
tree502610786625ef7fe15d89e4226cd05b6dcd2d44 /arch/sh
parent62410034e79d9249647d1fe6f6f35a06b3747e68 (diff)
sh/kernel/ cleanups
This patch contains the following cleanups: - make the following needlessly global code static: - cf-enabler.c: cf_init() - cpu/clock.c: __clk_enable() - cpu/clock.c: __clk_disable() - process_32.c: default_idle() - time_32.c: struct clocksource_sh - timers/timer-tmu.c: struct tmu_timer_ops - remove the following unused functions (no CONFIG_BLK_DEV_FD on sh): - process_{32,64}.c: disable_hlt() - process_{32,64}.c: enable_hlt() Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh')
-rw-r--r--arch/sh/kernel/cf-enabler.c2
-rw-r--r--arch/sh/kernel/cpu/clock.c6
-rw-r--r--arch/sh/kernel/process_32.c14
-rw-r--r--arch/sh/kernel/process_64.c10
-rw-r--r--arch/sh/kernel/time_32.c2
-rw-r--r--arch/sh/kernel/timers/timer-tmu.c2
6 files changed, 6 insertions, 30 deletions
diff --git a/arch/sh/kernel/cf-enabler.c b/arch/sh/kernel/cf-enabler.c
index 01ff4d05aab0..d3d9f3204230 100644
--- a/arch/sh/kernel/cf-enabler.c
+++ b/arch/sh/kernel/cf-enabler.c
@@ -157,7 +157,7 @@ static int __init cf_init_se(void)
157} 157}
158#endif 158#endif
159 159
160int __init cf_init(void) 160static int __init cf_init(void)
161{ 161{
162 if (mach_is_se() || mach_is_7722se() || mach_is_7721se()) 162 if (mach_is_se() || mach_is_7722se() || mach_is_7721se())
163 return cf_init_se(); 163 return cf_init_se();
diff --git a/arch/sh/kernel/cpu/clock.c b/arch/sh/kernel/cpu/clock.c
index b5f1e23ed57c..73334c689e9d 100644
--- a/arch/sh/kernel/cpu/clock.c
+++ b/arch/sh/kernel/cpu/clock.c
@@ -88,7 +88,7 @@ static void propagate_rate(struct clk *clk)
88 } 88 }
89} 89}
90 90
91int __clk_enable(struct clk *clk) 91static int __clk_enable(struct clk *clk)
92{ 92{
93 /* 93 /*
94 * See if this is the first time we're enabling the clock, some 94 * See if this is the first time we're enabling the clock, some
@@ -111,7 +111,6 @@ int __clk_enable(struct clk *clk)
111 111
112 return 0; 112 return 0;
113} 113}
114EXPORT_SYMBOL_GPL(__clk_enable);
115 114
116int clk_enable(struct clk *clk) 115int clk_enable(struct clk *clk)
117{ 116{
@@ -131,7 +130,7 @@ static void clk_kref_release(struct kref *kref)
131 /* Nothing to do */ 130 /* Nothing to do */
132} 131}
133 132
134void __clk_disable(struct clk *clk) 133static void __clk_disable(struct clk *clk)
135{ 134{
136 int count = kref_put(&clk->kref, clk_kref_release); 135 int count = kref_put(&clk->kref, clk_kref_release);
137 136
@@ -143,7 +142,6 @@ void __clk_disable(struct clk *clk)
143 clk->ops->disable(clk); 142 clk->ops->disable(clk);
144 } 143 }
145} 144}
146EXPORT_SYMBOL_GPL(__clk_disable);
147 145
148void clk_disable(struct clk *clk) 146void clk_disable(struct clk *clk)
149{ 147{
diff --git a/arch/sh/kernel/process_32.c b/arch/sh/kernel/process_32.c
index 921892c351da..3326a45749d9 100644
--- a/arch/sh/kernel/process_32.c
+++ b/arch/sh/kernel/process_32.c
@@ -34,18 +34,6 @@ void (*pm_idle)(void);
34void (*pm_power_off)(void); 34void (*pm_power_off)(void);
35EXPORT_SYMBOL(pm_power_off); 35EXPORT_SYMBOL(pm_power_off);
36 36
37void disable_hlt(void)
38{
39 hlt_counter++;
40}
41EXPORT_SYMBOL(disable_hlt);
42
43void enable_hlt(void)
44{
45 hlt_counter--;
46}
47EXPORT_SYMBOL(enable_hlt);
48
49static int __init nohlt_setup(char *__unused) 37static int __init nohlt_setup(char *__unused)
50{ 38{
51 hlt_counter = 1; 39 hlt_counter = 1;
@@ -60,7 +48,7 @@ static int __init hlt_setup(char *__unused)
60} 48}
61__setup("hlt", hlt_setup); 49__setup("hlt", hlt_setup);
62 50
63void default_idle(void) 51static void default_idle(void)
64{ 52{
65 if (!hlt_counter) { 53 if (!hlt_counter) {
66 clear_thread_flag(TIF_POLLING_NRFLAG); 54 clear_thread_flag(TIF_POLLING_NRFLAG);
diff --git a/arch/sh/kernel/process_64.c b/arch/sh/kernel/process_64.c
index 0283d8133075..b9dbd2d3b4a5 100644
--- a/arch/sh/kernel/process_64.c
+++ b/arch/sh/kernel/process_64.c
@@ -36,16 +36,6 @@ static int hlt_counter = 1;
36 36
37#define HARD_IDLE_TIMEOUT (HZ / 3) 37#define HARD_IDLE_TIMEOUT (HZ / 3)
38 38
39void disable_hlt(void)
40{
41 hlt_counter++;
42}
43
44void enable_hlt(void)
45{
46 hlt_counter--;
47}
48
49static int __init nohlt_setup(char *__unused) 39static int __init nohlt_setup(char *__unused)
50{ 40{
51 hlt_counter = 1; 41 hlt_counter = 1;
diff --git a/arch/sh/kernel/time_32.c b/arch/sh/kernel/time_32.c
index 7281342c044d..0758b5ee8180 100644
--- a/arch/sh/kernel/time_32.c
+++ b/arch/sh/kernel/time_32.c
@@ -211,7 +211,7 @@ unsigned long sh_hpt_frequency = 0;
211 211
212#define NSEC_PER_CYC_SHIFT 10 212#define NSEC_PER_CYC_SHIFT 10
213 213
214struct clocksource clocksource_sh = { 214static struct clocksource clocksource_sh = {
215 .name = "SuperH", 215 .name = "SuperH",
216 .rating = 200, 216 .rating = 200,
217 .mask = CLOCKSOURCE_MASK(32), 217 .mask = CLOCKSOURCE_MASK(32),
diff --git a/arch/sh/kernel/timers/timer-tmu.c b/arch/sh/kernel/timers/timer-tmu.c
index 8935570008d2..1ca9ad49b541 100644
--- a/arch/sh/kernel/timers/timer-tmu.c
+++ b/arch/sh/kernel/timers/timer-tmu.c
@@ -209,7 +209,7 @@ static int tmu_timer_init(void)
209 return 0; 209 return 0;
210} 210}
211 211
212struct sys_timer_ops tmu_timer_ops = { 212static struct sys_timer_ops tmu_timer_ops = {
213 .init = tmu_timer_init, 213 .init = tmu_timer_init,
214 .start = tmu_timer_start, 214 .start = tmu_timer_start,
215 .stop = tmu_timer_stop, 215 .stop = tmu_timer_stop,