1 /* 2 * Copyright (c) 2018, ARM Limited and Contributors. All rights reserved. 3 * 4 * SPDX-License-Identifier: BSD-3-Clause 5 */ 6 7 #include <stdint.h> 8 9 #include <lib/mmio.h> 10 11 #include <imx_caam.h> 12 imx_caam_init(void)13void imx_caam_init(void) 14 { 15 struct caam_ctrl *caam = (struct caam_ctrl *)CAAM_AIPS_BASE; 16 uint32_t reg; 17 int i; 18 19 for (i = 0; i < CAAM_NUM_JOB_RINGS; i++) { 20 reg = mmio_read_32((uintptr_t)&caam->jr[i].jrmidr_ms); 21 reg |= JROWN_NS | JROWN_MID; 22 mmio_write_32((uintptr_t)&caam->jr[i].jrmidr_ms, reg); 23 } 24 } 25