From 438d9ab30b42572bba341311d927fe06d4bbeeb8 Mon Sep 17 00:00:00 2001 From: Hernan Gatta Date: Thu, 26 Mar 2020 11:26:14 -0700 Subject: [PATCH] core: fix flag formatting checkpatch suggests using the BIT macro instead of a left shift. Signed-off-by: Hernan Gatta Reviewed-by: Jerome Forissier --- core/arch/arm/include/sm/optee_smc.h | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/core/arch/arm/include/sm/optee_smc.h b/core/arch/arm/include/sm/optee_smc.h index a934c038d05..8a8df34388e 100644 --- a/core/arch/arm/include/sm/optee_smc.h +++ b/core/arch/arm/include/sm/optee_smc.h @@ -5,6 +5,8 @@ #ifndef OPTEE_SMC_H #define OPTEE_SMC_H +#include + /* * This file is exported by OP-TEE and is in kept in sync between secure * world and normal world kernel driver. We're following ARM SMC Calling @@ -264,20 +266,20 @@ * a2-7 Preserved */ /* Normal world works as a uniprocessor system */ -#define OPTEE_SMC_NSEC_CAP_UNIPROCESSOR (1 << 0) +#define OPTEE_SMC_NSEC_CAP_UNIPROCESSOR BIT(0) /* Secure world has reserved shared memory for normal world to use */ -#define OPTEE_SMC_SEC_CAP_HAVE_RESERVED_SHM (1 << 0) +#define OPTEE_SMC_SEC_CAP_HAVE_RESERVED_SHM BIT(0) /* Secure world can communicate via previously unregistered shared memory */ -#define OPTEE_SMC_SEC_CAP_UNREGISTERED_SHM (1 << 1) +#define OPTEE_SMC_SEC_CAP_UNREGISTERED_SHM BIT(1) /* * Secure world supports commands "register/unregister shared memory", * secure world accepts command buffers located in any parts of non-secure RAM */ -#define OPTEE_SMC_SEC_CAP_DYNAMIC_SHM (1 << 2) +#define OPTEE_SMC_SEC_CAP_DYNAMIC_SHM BIT(2) /* Secure world is built with virtualization support */ -#define OPTEE_SMC_SEC_CAP_VIRTUALIZATION (1 << 3) +#define OPTEE_SMC_SEC_CAP_VIRTUALIZATION BIT(3) /* Secure world supports Shared Memory with a NULL reference */ -#define OPTEE_SMC_SEC_CAP_MEMREF_NULL (1 << 4) +#define OPTEE_SMC_SEC_CAP_MEMREF_NULL BIT(4) #define OPTEE_SMC_FUNCID_EXCHANGE_CAPABILITIES 9 #define OPTEE_SMC_EXCHANGE_CAPABILITIES \