diff options
author | Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> | 2016-06-12 16:56:50 -0400 |
---|---|---|
committer | Simon Horman <horms+renesas@verge.net.au> | 2016-06-15 21:53:57 -0400 |
commit | 7e49c845983e9aae86c70464786aa2ee191929a6 (patch) | |
tree | 83a77bc5ba5daa72300dba3ba6e3e40dc427e026 | |
parent | e0c98b9171eecf1745eda08de86081db8ec41d51 (diff) |
soc: renesas: rcar-sysc: add R8A7792 support
Add support for R-Car V2H (R8A7792) SoC power areas to the SYSC driver.
Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
-rw-r--r-- | drivers/soc/renesas/Makefile | 1 | ||||
-rw-r--r-- | drivers/soc/renesas/r8a7792-sysc.c | 34 | ||||
-rw-r--r-- | drivers/soc/renesas/rcar-sysc.c | 3 | ||||
-rw-r--r-- | drivers/soc/renesas/rcar-sysc.h | 1 |
4 files changed, 39 insertions, 0 deletions
diff --git a/drivers/soc/renesas/Makefile b/drivers/soc/renesas/Makefile index cd85cd5e6a01..623039c3514c 100644 --- a/drivers/soc/renesas/Makefile +++ b/drivers/soc/renesas/Makefile | |||
@@ -1,6 +1,7 @@ | |||
1 | obj-$(CONFIG_ARCH_R8A7779) += rcar-sysc.o r8a7779-sysc.o | 1 | obj-$(CONFIG_ARCH_R8A7779) += rcar-sysc.o r8a7779-sysc.o |
2 | obj-$(CONFIG_ARCH_R8A7790) += rcar-sysc.o r8a7790-sysc.o | 2 | obj-$(CONFIG_ARCH_R8A7790) += rcar-sysc.o r8a7790-sysc.o |
3 | obj-$(CONFIG_ARCH_R8A7791) += rcar-sysc.o r8a7791-sysc.o | 3 | obj-$(CONFIG_ARCH_R8A7791) += rcar-sysc.o r8a7791-sysc.o |
4 | obj-$(CONFIG_ARCH_R8A7792) += rcar-sysc.o r8a7792-sysc.o | ||
4 | # R-Car M2-N is identical to R-Car M2-W w.r.t. power domains. | 5 | # R-Car M2-N is identical to R-Car M2-W w.r.t. power domains. |
5 | obj-$(CONFIG_ARCH_R8A7793) += rcar-sysc.o r8a7791-sysc.o | 6 | obj-$(CONFIG_ARCH_R8A7793) += rcar-sysc.o r8a7791-sysc.o |
6 | obj-$(CONFIG_ARCH_R8A7794) += rcar-sysc.o r8a7794-sysc.o | 7 | obj-$(CONFIG_ARCH_R8A7794) += rcar-sysc.o r8a7794-sysc.o |
diff --git a/drivers/soc/renesas/r8a7792-sysc.c b/drivers/soc/renesas/r8a7792-sysc.c new file mode 100644 index 000000000000..ca7467d7b7ec --- /dev/null +++ b/drivers/soc/renesas/r8a7792-sysc.c | |||
@@ -0,0 +1,34 @@ | |||
1 | /* | ||
2 | * Renesas R-Car V2H (R8A7792) System Controller | ||
3 | * | ||
4 | * Copyright (C) 2016 Cogent Embedded Inc. | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License as published by | ||
8 | * the Free Software Foundation; version 2 of the License. | ||
9 | */ | ||
10 | |||
11 | #include <linux/bug.h> | ||
12 | #include <linux/init.h> | ||
13 | #include <linux/kernel.h> | ||
14 | |||
15 | #include <dt-bindings/power/r8a7792-sysc.h> | ||
16 | |||
17 | #include "rcar-sysc.h" | ||
18 | |||
19 | static const struct rcar_sysc_area r8a7792_areas[] __initconst = { | ||
20 | { "always-on", 0, 0, R8A7792_PD_ALWAYS_ON, -1, PD_ALWAYS_ON }, | ||
21 | { "ca15-scu", 0x180, 0, R8A7792_PD_CA15_SCU, R8A7792_PD_ALWAYS_ON, | ||
22 | PD_SCU }, | ||
23 | { "ca15-cpu0", 0x40, 0, R8A7792_PD_CA15_CPU0, R8A7792_PD_CA15_SCU, | ||
24 | PD_CPU_NOCR }, | ||
25 | { "ca15-cpu1", 0x40, 1, R8A7792_PD_CA15_CPU1, R8A7792_PD_CA15_SCU, | ||
26 | PD_CPU_NOCR }, | ||
27 | { "sgx", 0xc0, 0, R8A7792_PD_SGX, R8A7792_PD_ALWAYS_ON }, | ||
28 | { "imp", 0x140, 0, R8A7792_PD_IMP, R8A7792_PD_ALWAYS_ON }, | ||
29 | }; | ||
30 | |||
31 | const struct rcar_sysc_info r8a7792_sysc_info __initconst = { | ||
32 | .areas = r8a7792_areas, | ||
33 | .num_areas = ARRAY_SIZE(r8a7792_areas), | ||
34 | }; | ||
diff --git a/drivers/soc/renesas/rcar-sysc.c b/drivers/soc/renesas/rcar-sysc.c index fc997d4d2a4a..a43ca24699be 100644 --- a/drivers/soc/renesas/rcar-sysc.c +++ b/drivers/soc/renesas/rcar-sysc.c | |||
@@ -293,6 +293,9 @@ static const struct of_device_id rcar_sysc_matches[] = { | |||
293 | #ifdef CONFIG_ARCH_R8A7791 | 293 | #ifdef CONFIG_ARCH_R8A7791 |
294 | { .compatible = "renesas,r8a7791-sysc", .data = &r8a7791_sysc_info }, | 294 | { .compatible = "renesas,r8a7791-sysc", .data = &r8a7791_sysc_info }, |
295 | #endif | 295 | #endif |
296 | #ifdef CONFIG_ARCH_R8A7792 | ||
297 | { .compatible = "renesas,r8a7792-sysc", .data = &r8a7792_sysc_info }, | ||
298 | #endif | ||
296 | #ifdef CONFIG_ARCH_R8A7793 | 299 | #ifdef CONFIG_ARCH_R8A7793 |
297 | /* R-Car M2-N is identical to R-Car M2-W w.r.t. power domains. */ | 300 | /* R-Car M2-N is identical to R-Car M2-W w.r.t. power domains. */ |
298 | { .compatible = "renesas,r8a7793-sysc", .data = &r8a7791_sysc_info }, | 301 | { .compatible = "renesas,r8a7793-sysc", .data = &r8a7791_sysc_info }, |
diff --git a/drivers/soc/renesas/rcar-sysc.h b/drivers/soc/renesas/rcar-sysc.h index 4ac3d7bf7f38..77dbe861473f 100644 --- a/drivers/soc/renesas/rcar-sysc.h +++ b/drivers/soc/renesas/rcar-sysc.h | |||
@@ -53,6 +53,7 @@ struct rcar_sysc_info { | |||
53 | extern const struct rcar_sysc_info r8a7779_sysc_info; | 53 | extern const struct rcar_sysc_info r8a7779_sysc_info; |
54 | extern const struct rcar_sysc_info r8a7790_sysc_info; | 54 | extern const struct rcar_sysc_info r8a7790_sysc_info; |
55 | extern const struct rcar_sysc_info r8a7791_sysc_info; | 55 | extern const struct rcar_sysc_info r8a7791_sysc_info; |
56 | extern const struct rcar_sysc_info r8a7792_sysc_info; | ||
56 | extern const struct rcar_sysc_info r8a7794_sysc_info; | 57 | extern const struct rcar_sysc_info r8a7794_sysc_info; |
57 | extern const struct rcar_sysc_info r8a7795_sysc_info; | 58 | extern const struct rcar_sysc_info r8a7795_sysc_info; |
58 | extern const struct rcar_sysc_info r8a7796_sysc_info; | 59 | extern const struct rcar_sysc_info r8a7796_sysc_info; |