summaryrefslogtreecommitdiff
path: root/plat/imx/common/imx_snvs.c
blob: 4a2a7d72500b6788a83d2014ade3399f6881ea54 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
/*
 * Copyright (c) 2018, ARM Limited and Contributors. All rights reserved.
 *
 * SPDX-License-Identifier: BSD-3-Clause
 */

#include <mmio.h>
#include <imx_regs.h>
#include <imx_snvs.h>

void imx_snvs_init(void)
{
	struct snvs *snvs = (struct snvs *)SNVS_BASE;
	uintptr_t addr;
	uint32_t val;

	addr = (uintptr_t)&snvs->hpcomr;
	val = mmio_read_32(addr);
	val |= HPCOMR_NPSWA_EN;
	mmio_write_32(addr, val);
}