blob: 7537bd79065700fd26925eac82d80c1a2a5f2948 [file] [log] [blame]
David Brazdil0f672f62019-12-10 10:32:29 +00001/* SPDX-License-Identifier: GPL-2.0-only */
Andrew Scullb4b6d4a2019-01-02 15:54:55 +00002/*
3 * arch/arm/include/asm/arm-cci.h
4 *
5 * Copyright (C) 2015 ARM Ltd.
Andrew Scullb4b6d4a2019-01-02 15:54:55 +00006 */
7
8#ifndef __ASM_ARM_CCI_H
9#define __ASM_ARM_CCI_H
10
11#ifdef CONFIG_MCPM
12#include <asm/mcpm.h>
13
14/*
15 * We don't have a reliable way of detecting whether,
16 * if we have access to secure-only registers, unless
17 * mcpm is registered.
18 */
19static inline bool platform_has_secure_cci_access(void)
20{
21 return mcpm_is_available();
22}
23
24#else
25static inline bool platform_has_secure_cci_access(void)
26{
27 return false;
28}
29#endif
30
31#endif