plat/arm: Fix MISRA defects in SiP SVC handler
No functional changes. Change-Id: I9b9f8d3dfde08d57706ad5450de6ff858a55ac01 Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
This commit is contained in:
parent
40daecc1be
commit
15b94cc18d
|
@ -1,24 +1,26 @@
|
|||
/*
|
||||
* Copyright (c) 2016-2017, ARM Limited and Contributors. All rights reserved.
|
||||
* Copyright (c) 2016-2018, ARM Limited and Contributors. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
||||
#ifndef __ARM_SIP_SVC_H__
|
||||
#define __ARM_SIP_SVC_H__
|
||||
#ifndef ARM_SIP_SVC_H
|
||||
#define ARM_SIP_SVC_H
|
||||
|
||||
#include <utils_def.h>
|
||||
|
||||
/* SMC function IDs for SiP Service queries */
|
||||
|
||||
#define ARM_SIP_SVC_CALL_COUNT 0x8200ff00
|
||||
#define ARM_SIP_SVC_UID 0x8200ff01
|
||||
/* 0x8200ff02 is reserved */
|
||||
#define ARM_SIP_SVC_VERSION 0x8200ff03
|
||||
#define ARM_SIP_SVC_CALL_COUNT U(0x8200ff00)
|
||||
#define ARM_SIP_SVC_UID U(0x8200ff01)
|
||||
/* U(0x8200ff02) is reserved */
|
||||
#define ARM_SIP_SVC_VERSION U(0x8200ff03)
|
||||
|
||||
/* Function ID for requesting state switch of lower EL */
|
||||
#define ARM_SIP_SVC_EXE_STATE_SWITCH 0x82000020
|
||||
#define ARM_SIP_SVC_EXE_STATE_SWITCH U(0x82000020)
|
||||
|
||||
/* ARM SiP Service Calls version numbers */
|
||||
#define ARM_SIP_SVC_VERSION_MAJOR 0x0
|
||||
#define ARM_SIP_SVC_VERSION_MINOR 0x2
|
||||
#define ARM_SIP_SVC_VERSION_MAJOR U(0x0)
|
||||
#define ARM_SIP_SVC_VERSION_MINOR U(0x2)
|
||||
|
||||
#endif /* __ARM_SIP_SVC_H__ */
|
||||
#endif /* ARM_SIP_SVC_H */
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
#ifndef __PLAT_ARM_H__
|
||||
#define __PLAT_ARM_H__
|
||||
#ifndef PLAT_ARM_H
|
||||
#define PLAT_ARM_H
|
||||
|
||||
#include <bakery_lock.h>
|
||||
#include <cassert.h>
|
||||
|
@ -292,4 +292,4 @@ extern plat_psci_ops_t plat_arm_psci_pm_ops;
|
|||
extern const mmap_region_t plat_arm_mmap[];
|
||||
extern const unsigned int arm_pm_idle_states[];
|
||||
|
||||
#endif /* __PLAT_ARM_H__ */
|
||||
#endif /* PLAT_ARM_H */
|
||||
|
|
|
@ -58,7 +58,7 @@ static uintptr_t arm_sip_handler(unsigned int smc_fid,
|
|||
|
||||
/* Validate supplied entry point */
|
||||
pc = (u_register_t) ((x1 << 32) | (uint32_t) x2);
|
||||
if (arm_validate_ns_entrypoint(pc))
|
||||
if (arm_validate_ns_entrypoint(pc) != 0)
|
||||
SMC_RET1(handle, STATE_SW_E_PARAM);
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue