diff options
Diffstat (limited to 'arch/sh/include')
-rw-r--r-- | arch/sh/include/asm/device.h | 10 | ||||
-rw-r--r-- | arch/sh/include/asm/hwblk.h | 70 | ||||
-rw-r--r-- | arch/sh/include/cpu-sh4/cpu/sh7722.h | 13 | ||||
-rw-r--r-- | arch/sh/include/cpu-sh4/cpu/sh7723.h | 3 | ||||
-rw-r--r-- | arch/sh/include/cpu-sh4/cpu/sh7724.h | 4 |
5 files changed, 8 insertions, 92 deletions
diff --git a/arch/sh/include/asm/device.h b/arch/sh/include/asm/device.h index b16debfe8c1e..a1c9c0daec10 100644 --- a/arch/sh/include/asm/device.h +++ b/arch/sh/include/asm/device.h | |||
@@ -14,15 +14,5 @@ int platform_resource_setup_memory(struct platform_device *pdev, | |||
14 | 14 | ||
15 | void plat_early_device_setup(void); | 15 | void plat_early_device_setup(void); |
16 | 16 | ||
17 | #define PDEV_ARCHDATA_FLAG_INIT 0 | ||
18 | #define PDEV_ARCHDATA_FLAG_IDLE 1 | ||
19 | #define PDEV_ARCHDATA_FLAG_SUSP 2 | ||
20 | |||
21 | struct pdev_archdata { | 17 | struct pdev_archdata { |
22 | int hwblk_id; | ||
23 | #ifdef CONFIG_PM_RUNTIME | ||
24 | unsigned long flags; | ||
25 | struct list_head entry; | ||
26 | struct mutex mutex; | ||
27 | #endif | ||
28 | }; | 18 | }; |
diff --git a/arch/sh/include/asm/hwblk.h b/arch/sh/include/asm/hwblk.h deleted file mode 100644 index 855e945c6199..000000000000 --- a/arch/sh/include/asm/hwblk.h +++ /dev/null | |||
@@ -1,70 +0,0 @@ | |||
1 | #ifndef __ASM_SH_HWBLK_H | ||
2 | #define __ASM_SH_HWBLK_H | ||
3 | |||
4 | #include <asm/clock.h> | ||
5 | #include <asm/io.h> | ||
6 | |||
7 | #define HWBLK_CNT_USAGE 0 | ||
8 | #define HWBLK_CNT_IDLE 1 | ||
9 | #define HWBLK_CNT_DEVICES 2 | ||
10 | #define HWBLK_CNT_NR 3 | ||
11 | |||
12 | #define HWBLK_AREA_FLAG_PARENT (1 << 0) /* valid parent */ | ||
13 | |||
14 | #define HWBLK_AREA(_flags, _parent) \ | ||
15 | { \ | ||
16 | .flags = _flags, \ | ||
17 | .parent = _parent, \ | ||
18 | } | ||
19 | |||
20 | struct hwblk_area { | ||
21 | int cnt[HWBLK_CNT_NR]; | ||
22 | unsigned char parent; | ||
23 | unsigned char flags; | ||
24 | }; | ||
25 | |||
26 | #define HWBLK(_mstp, _bit, _area) \ | ||
27 | { \ | ||
28 | .mstp = (void __iomem *)_mstp, \ | ||
29 | .bit = _bit, \ | ||
30 | .area = _area, \ | ||
31 | } | ||
32 | |||
33 | struct hwblk { | ||
34 | void __iomem *mstp; | ||
35 | unsigned char bit; | ||
36 | unsigned char area; | ||
37 | int cnt[HWBLK_CNT_NR]; | ||
38 | }; | ||
39 | |||
40 | struct hwblk_info { | ||
41 | struct hwblk_area *areas; | ||
42 | int nr_areas; | ||
43 | struct hwblk *hwblks; | ||
44 | int nr_hwblks; | ||
45 | }; | ||
46 | |||
47 | /* Should be defined by processor-specific code */ | ||
48 | int arch_hwblk_init(void); | ||
49 | int arch_hwblk_sleep_mode(void); | ||
50 | |||
51 | int hwblk_register(struct hwblk_info *info); | ||
52 | int hwblk_init(void); | ||
53 | |||
54 | void hwblk_enable(struct hwblk_info *info, int hwblk); | ||
55 | void hwblk_disable(struct hwblk_info *info, int hwblk); | ||
56 | |||
57 | void hwblk_cnt_inc(struct hwblk_info *info, int hwblk, int cnt); | ||
58 | void hwblk_cnt_dec(struct hwblk_info *info, int hwblk, int cnt); | ||
59 | |||
60 | /* allow clocks to enable and disable hardware blocks */ | ||
61 | #define SH_HWBLK_CLK(_hwblk, _parent, _flags) \ | ||
62 | [_hwblk] = { \ | ||
63 | .parent = _parent, \ | ||
64 | .arch_flags = _hwblk, \ | ||
65 | .flags = _flags, \ | ||
66 | } | ||
67 | |||
68 | int sh_hwblk_clk_register(struct clk *clks, int nr); | ||
69 | |||
70 | #endif /* __ASM_SH_HWBLK_H */ | ||
diff --git a/arch/sh/include/cpu-sh4/cpu/sh7722.h b/arch/sh/include/cpu-sh4/cpu/sh7722.h index bd0622788d64..3bb74e534d0f 100644 --- a/arch/sh/include/cpu-sh4/cpu/sh7722.h +++ b/arch/sh/include/cpu-sh4/cpu/sh7722.h | |||
@@ -222,14 +222,11 @@ enum { | |||
222 | }; | 222 | }; |
223 | 223 | ||
224 | enum { | 224 | enum { |
225 | HWBLK_UNKNOWN = 0, | 225 | HWBLK_URAM, HWBLK_XYMEM, |
226 | HWBLK_TLB, HWBLK_IC, HWBLK_OC, HWBLK_URAM, HWBLK_XYMEM, | 226 | HWBLK_TMU, HWBLK_CMT, HWBLK_RWDT, HWBLK_FLCTL, |
227 | HWBLK_INTC, HWBLK_DMAC, HWBLK_SHYWAY, HWBLK_HUDI, | 227 | HWBLK_SCIF0, HWBLK_SCIF1, HWBLK_SCIF2, HWBLK_IIC, HWBLK_RTC, |
228 | HWBLK_UBC, HWBLK_TMU, HWBLK_CMT, HWBLK_RWDT, HWBLK_FLCTL, | 228 | HWBLK_SDHI, HWBLK_KEYSC, |
229 | HWBLK_SCIF0, HWBLK_SCIF1, HWBLK_SCIF2, HWBLK_SIO, | 229 | HWBLK_USBF, HWBLK_2DG, HWBLK_SIU, HWBLK_VOU, |
230 | HWBLK_SIOF0, HWBLK_SIOF1, HWBLK_IIC, HWBLK_RTC, | ||
231 | HWBLK_TPU, HWBLK_IRDA, HWBLK_SDHI, HWBLK_SIM, HWBLK_KEYSC, | ||
232 | HWBLK_TSIF, HWBLK_USBF, HWBLK_2DG, HWBLK_SIU, HWBLK_VOU, | ||
233 | HWBLK_JPU, HWBLK_BEU, HWBLK_CEU, HWBLK_VEU, HWBLK_VPU, | 230 | HWBLK_JPU, HWBLK_BEU, HWBLK_CEU, HWBLK_VEU, HWBLK_VPU, |
234 | HWBLK_LCDC, | 231 | HWBLK_LCDC, |
235 | HWBLK_NR, | 232 | HWBLK_NR, |
diff --git a/arch/sh/include/cpu-sh4/cpu/sh7723.h b/arch/sh/include/cpu-sh4/cpu/sh7723.h index 9b36fae72324..6fae50cb1e94 100644 --- a/arch/sh/include/cpu-sh4/cpu/sh7723.h +++ b/arch/sh/include/cpu-sh4/cpu/sh7723.h | |||
@@ -266,10 +266,9 @@ enum { | |||
266 | }; | 266 | }; |
267 | 267 | ||
268 | enum { | 268 | enum { |
269 | HWBLK_UNKNOWN = 0, | ||
270 | HWBLK_TLB, HWBLK_IC, HWBLK_OC, HWBLK_L2C, HWBLK_ILMEM, HWBLK_FPU, | 269 | HWBLK_TLB, HWBLK_IC, HWBLK_OC, HWBLK_L2C, HWBLK_ILMEM, HWBLK_FPU, |
271 | HWBLK_INTC, HWBLK_DMAC0, HWBLK_SHYWAY, | 270 | HWBLK_INTC, HWBLK_DMAC0, HWBLK_SHYWAY, |
272 | HWBLK_HUDI, HWBLK_DBG, HWBLK_UBC, HWBLK_SUBC, | 271 | HWBLK_HUDI, HWBLK_UBC, |
273 | HWBLK_TMU0, HWBLK_CMT, HWBLK_RWDT, HWBLK_DMAC1, HWBLK_TMU1, | 272 | HWBLK_TMU0, HWBLK_CMT, HWBLK_RWDT, HWBLK_DMAC1, HWBLK_TMU1, |
274 | HWBLK_FLCTL, | 273 | HWBLK_FLCTL, |
275 | HWBLK_SCIF0, HWBLK_SCIF1, HWBLK_SCIF2, | 274 | HWBLK_SCIF0, HWBLK_SCIF1, HWBLK_SCIF2, |
diff --git a/arch/sh/include/cpu-sh4/cpu/sh7724.h b/arch/sh/include/cpu-sh4/cpu/sh7724.h index cbc47e6bcab5..38859f96d4e5 100644 --- a/arch/sh/include/cpu-sh4/cpu/sh7724.h +++ b/arch/sh/include/cpu-sh4/cpu/sh7724.h | |||
@@ -268,10 +268,9 @@ enum { | |||
268 | }; | 268 | }; |
269 | 269 | ||
270 | enum { | 270 | enum { |
271 | HWBLK_UNKNOWN = 0, | ||
272 | HWBLK_TLB, HWBLK_IC, HWBLK_OC, HWBLK_RSMEM, HWBLK_ILMEM, HWBLK_L2C, | 271 | HWBLK_TLB, HWBLK_IC, HWBLK_OC, HWBLK_RSMEM, HWBLK_ILMEM, HWBLK_L2C, |
273 | HWBLK_FPU, HWBLK_INTC, HWBLK_DMAC0, HWBLK_SHYWAY, | 272 | HWBLK_FPU, HWBLK_INTC, HWBLK_DMAC0, HWBLK_SHYWAY, |
274 | HWBLK_HUDI, HWBLK_DBG, HWBLK_UBC, | 273 | HWBLK_HUDI, HWBLK_UBC, |
275 | HWBLK_TMU0, HWBLK_CMT, HWBLK_RWDT, HWBLK_DMAC1, HWBLK_TMU1, | 274 | HWBLK_TMU0, HWBLK_CMT, HWBLK_RWDT, HWBLK_DMAC1, HWBLK_TMU1, |
276 | HWBLK_SCIF0, HWBLK_SCIF1, HWBLK_SCIF2, HWBLK_SCIF3, | 275 | HWBLK_SCIF0, HWBLK_SCIF1, HWBLK_SCIF2, HWBLK_SCIF3, |
277 | HWBLK_SCIF4, HWBLK_SCIF5, HWBLK_MSIOF0, HWBLK_MSIOF1, | 276 | HWBLK_SCIF4, HWBLK_SCIF5, HWBLK_MSIOF0, HWBLK_MSIOF1, |
@@ -314,5 +313,6 @@ enum { | |||
314 | 313 | ||
315 | extern struct clk sh7724_fsimcka_clk; | 314 | extern struct clk sh7724_fsimcka_clk; |
316 | extern struct clk sh7724_fsimckb_clk; | 315 | extern struct clk sh7724_fsimckb_clk; |
316 | extern struct clk sh7724_dv_clki; | ||
317 | 317 | ||
318 | #endif /* __ASM_SH7724_H__ */ | 318 | #endif /* __ASM_SH7724_H__ */ |