HV:CPU: Add 'U/UL' for constant value in CPU module

There are unsinged constant values don't have 'U/UL' suffix
in the HV reported by static analysis tool.

Add 'U/UL' suffix for unsigned constant values as needed.

Tracked-on: ccm0001001-247033
Signed-off-by: Xiangyang Wu <xiangyang.wu@intel.com>
Reviewed-by: Junjie Mao <junjie.mao@intel.com>
This commit is contained in:
Xiangyang Wu 2018-07-09 15:13:14 +08:00 committed by lijinxia
parent 90d8e28560
commit b79f350977
2 changed files with 7 additions and 7 deletions

View File

@ -723,7 +723,7 @@ void start_cpus()
/* Wait until global count is equal to expected CPU up count or
* configured time-out has expired
*/
timeout = CONFIG_CPU_UP_TIMEOUT * 1000;
timeout = CONFIG_CPU_UP_TIMEOUT * 1000U;
while ((up_count != expected_up) && (timeout != 0U)) {
/* Delay 10us */
udelay(10U);
@ -748,7 +748,7 @@ void stop_cpus()
uint16_t pcpu_id, expected_up;
uint32_t timeout;
timeout = CONFIG_CPU_UP_TIMEOUT * 1000;
timeout = CONFIG_CPU_UP_TIMEOUT * 1000U;
for (pcpu_id = 0U; pcpu_id < phys_cpu_num; pcpu_id++) {
if (get_cpu_id() == pcpu_id) /* avoid offline itself */
continue;

View File

@ -84,11 +84,11 @@
#define CPUID_ECX_PCID (1U<<17)
/* CPUID source operands */
#define CPUID_VENDORSTRING 0
#define CPUID_FEATURES 1
#define CPUID_TLB 2
#define CPUID_SERIALNUM 3
#define CPUID_EXTEND_FEATURE 7
#define CPUID_VENDORSTRING 0U
#define CPUID_FEATURES 1U
#define CPUID_TLB 2U
#define CPUID_SERIALNUM 3U
#define CPUID_EXTEND_FEATURE 7U
#define CPUID_MAX_EXTENDED_FUNCTION 0x80000000U
#define CPUID_EXTEND_FUNCTION_1 0x80000001U
#define CPUID_EXTEND_FUNCTION_2 0x80000002U