/* * Copyright (c) 2015-2025, Renesas Electronics Corporation. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ #ifndef RCAR_PRIVATE_H #define RCAR_PRIVATE_H #include #include #include #include #include /* * This structure represents the superset of information that is passed to * BL31 e.g. while passing control to it from BL2 which is bl31_params * and bl31_plat_params and its elements */ typedef struct bl2_to_bl31_params_mem { image_info_t bl32_image_info; image_info_t bl33_image_info; entry_point_info_t bl33_ep_info; entry_point_info_t bl32_ep_info; } bl2_to_bl31_params_mem_t; #define RCAR_INSTANTIATE_LOCK DEFINE_BAKERY_LOCK(rcar_lock) /* * Constants to specify how many bakery locks this platform implements. These * are used if the platform chooses not to use coherent memory for bakery lock * data structures. */ #define RCAR_MAX_BAKERIES 2 /* * Definition of structure which holds platform specific per-cpu data. Currently * it holds only the bakery lock information for each cpu. Constants to * specify how many bakeries this platform implements and bakery ids are * specified in rcar_def.h */ typedef struct rcar_cpu_data { bakery_info_t pcpu_bakery_info[RCAR_MAX_BAKERIES]; } rcar_cpu_data_t; /* * Helper macros for bakery lock api when using the above rcar_cpu_data_t for * bakery lock data structures. It assumes that the bakery_info is at the * beginning of the platform specific per-cpu data. */ #define rcar_lock_init() bakery_lock_init(&rcar_lock) #define rcar_lock_get() bakery_lock_get(&rcar_lock) #define rcar_lock_release() bakery_lock_release(&rcar_lock) /* * Function and variable prototypes */ void rcar_configure_mmu_el3(uintptr_t total_base, size_t total_size, uintptr_t ro_start, uintptr_t ro_limit ); void plat_invalidate_icache(void); void rcar_console_boot_init(void); void rcar_console_runtime_init(void); int32_t rcar_cluster_pos_by_mpidr(u_register_t mpidr); #endif /* RCAR_PRIVATE_H */