1 /* 2 * Copyright 2020 NXP 3 * 4 * SPDX-License-Identifier: BSD-3-Clause 5 * 6 */ 7 8 #include <arch.h> 9 #include <cci.h> 10 11 #include <plat_arm.h> 12 13 14 /****************************************************************************** 15 * Helper function to place current master into coherency 16 *****************************************************************************/ 17 void plat_ls_interconnect_enter_coherency(unsigned int num_clusters) 18 { 19 cci_enable_snoop_dvm_reqs(MPIDR_AFFLVL1_VAL(read_mpidr_el1())); 20 21 for (uint32_t index = 1U; index < num_clusters; index++) { 22 cci_enable_snoop_dvm_reqs(index); 23 } 24 } 25 26 /****************************************************************************** 27 * Helper function to remove current master from coherency 28 *****************************************************************************/ 29 void plat_ls_interconnect_exit_coherency(void) 30 { 31 cci_disable_snoop_dvm_reqs(MPIDR_AFFLVL1_VAL(read_mpidr_el1())); 32 } 33