18c2ecf20Sopenharmony_ci// SPDX-License-Identifier: GPL-2.0 28c2ecf20Sopenharmony_ci/* 38c2ecf20Sopenharmony_ci * Renesas R-Car V3H System Controller 48c2ecf20Sopenharmony_ci * 58c2ecf20Sopenharmony_ci * Copyright (C) 2018 Renesas Electronics Corp. 68c2ecf20Sopenharmony_ci * Copyright (C) 2018 Cogent Embedded, Inc. 78c2ecf20Sopenharmony_ci */ 88c2ecf20Sopenharmony_ci 98c2ecf20Sopenharmony_ci#include <linux/bits.h> 108c2ecf20Sopenharmony_ci#include <linux/kernel.h> 118c2ecf20Sopenharmony_ci 128c2ecf20Sopenharmony_ci#include <dt-bindings/power/r8a77980-sysc.h> 138c2ecf20Sopenharmony_ci 148c2ecf20Sopenharmony_ci#include "rcar-sysc.h" 158c2ecf20Sopenharmony_ci 168c2ecf20Sopenharmony_cistatic const struct rcar_sysc_area r8a77980_areas[] __initconst = { 178c2ecf20Sopenharmony_ci { "always-on", 0, 0, R8A77980_PD_ALWAYS_ON, -1, PD_ALWAYS_ON }, 188c2ecf20Sopenharmony_ci { "ca53-scu", 0x140, 0, R8A77980_PD_CA53_SCU, R8A77980_PD_ALWAYS_ON, 198c2ecf20Sopenharmony_ci PD_SCU }, 208c2ecf20Sopenharmony_ci { "ca53-cpu0", 0x200, 0, R8A77980_PD_CA53_CPU0, R8A77980_PD_CA53_SCU, 218c2ecf20Sopenharmony_ci PD_CPU_NOCR }, 228c2ecf20Sopenharmony_ci { "ca53-cpu1", 0x200, 1, R8A77980_PD_CA53_CPU1, R8A77980_PD_CA53_SCU, 238c2ecf20Sopenharmony_ci PD_CPU_NOCR }, 248c2ecf20Sopenharmony_ci { "ca53-cpu2", 0x200, 2, R8A77980_PD_CA53_CPU2, R8A77980_PD_CA53_SCU, 258c2ecf20Sopenharmony_ci PD_CPU_NOCR }, 268c2ecf20Sopenharmony_ci { "ca53-cpu3", 0x200, 3, R8A77980_PD_CA53_CPU3, R8A77980_PD_CA53_SCU, 278c2ecf20Sopenharmony_ci PD_CPU_NOCR }, 288c2ecf20Sopenharmony_ci { "cr7", 0x240, 0, R8A77980_PD_CR7, R8A77980_PD_ALWAYS_ON }, 298c2ecf20Sopenharmony_ci { "a3ir", 0x180, 0, R8A77980_PD_A3IR, R8A77980_PD_ALWAYS_ON }, 308c2ecf20Sopenharmony_ci { "a2ir0", 0x400, 0, R8A77980_PD_A2IR0, R8A77980_PD_A3IR }, 318c2ecf20Sopenharmony_ci { "a2ir1", 0x400, 1, R8A77980_PD_A2IR1, R8A77980_PD_A3IR }, 328c2ecf20Sopenharmony_ci { "a2ir2", 0x400, 2, R8A77980_PD_A2IR2, R8A77980_PD_A3IR }, 338c2ecf20Sopenharmony_ci { "a2ir3", 0x400, 3, R8A77980_PD_A2IR3, R8A77980_PD_A3IR }, 348c2ecf20Sopenharmony_ci { "a2ir4", 0x400, 4, R8A77980_PD_A2IR4, R8A77980_PD_A3IR }, 358c2ecf20Sopenharmony_ci { "a2ir5", 0x400, 5, R8A77980_PD_A2IR5, R8A77980_PD_A3IR }, 368c2ecf20Sopenharmony_ci { "a2sc0", 0x400, 6, R8A77980_PD_A2SC0, R8A77980_PD_A3IR }, 378c2ecf20Sopenharmony_ci { "a2sc1", 0x400, 7, R8A77980_PD_A2SC1, R8A77980_PD_A3IR }, 388c2ecf20Sopenharmony_ci { "a2sc2", 0x400, 8, R8A77980_PD_A2SC2, R8A77980_PD_A3IR }, 398c2ecf20Sopenharmony_ci { "a2sc3", 0x400, 9, R8A77980_PD_A2SC3, R8A77980_PD_A3IR }, 408c2ecf20Sopenharmony_ci { "a2sc4", 0x400, 10, R8A77980_PD_A2SC4, R8A77980_PD_A3IR }, 418c2ecf20Sopenharmony_ci { "a2dp0", 0x400, 11, R8A77980_PD_A2DP0, R8A77980_PD_A3IR }, 428c2ecf20Sopenharmony_ci { "a2dp1", 0x400, 12, R8A77980_PD_A2DP1, R8A77980_PD_A3IR }, 438c2ecf20Sopenharmony_ci { "a2cn", 0x400, 13, R8A77980_PD_A2CN, R8A77980_PD_A3IR }, 448c2ecf20Sopenharmony_ci { "a3vip0", 0x2c0, 0, R8A77980_PD_A3VIP0, R8A77980_PD_ALWAYS_ON }, 458c2ecf20Sopenharmony_ci { "a3vip1", 0x300, 0, R8A77980_PD_A3VIP1, R8A77980_PD_ALWAYS_ON }, 468c2ecf20Sopenharmony_ci { "a3vip2", 0x280, 0, R8A77980_PD_A3VIP2, R8A77980_PD_ALWAYS_ON }, 478c2ecf20Sopenharmony_ci}; 488c2ecf20Sopenharmony_ci 498c2ecf20Sopenharmony_ciconst struct rcar_sysc_info r8a77980_sysc_info __initconst = { 508c2ecf20Sopenharmony_ci .areas = r8a77980_areas, 518c2ecf20Sopenharmony_ci .num_areas = ARRAY_SIZE(r8a77980_areas), 528c2ecf20Sopenharmony_ci .extmask_offs = 0x138, 538c2ecf20Sopenharmony_ci .extmask_val = BIT(0), 548c2ecf20Sopenharmony_ci}; 55