Commit d4067395 authored by Jinchao Wang's avatar Jinchao Wang Committed by Vineet Gupta

arc: Prefer unsigned int to bare use of unsigned

Fix checkpatch warnings:
    WARNING: Prefer 'unsigned int' to bare use of 'unsigned'
Signed-off-by: default avatarJinchao Wang <wjc@cdjrlc.com>
Signed-off-by: default avatarVineet Gupta <vgupta@synopsys.com>
parent c500bee1
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
*/ */
static inline __sum16 csum_fold(__wsum s) static inline __sum16 csum_fold(__wsum s)
{ {
unsigned r = s << 16 | s >> 16; /* ror */ unsigned int r = s << 16 | s >> 16; /* ror */
s = ~s; s = ~s;
s -= r; s -= r;
return s >> 16; return s >> 16;
......
...@@ -123,7 +123,7 @@ static const char * const arc_pmu_ev_hw_map[] = { ...@@ -123,7 +123,7 @@ static const char * const arc_pmu_ev_hw_map[] = {
#define C(_x) PERF_COUNT_HW_CACHE_##_x #define C(_x) PERF_COUNT_HW_CACHE_##_x
#define CACHE_OP_UNSUPPORTED 0xffff #define CACHE_OP_UNSUPPORTED 0xffff
static const unsigned arc_pmu_cache_map[C(MAX)][C(OP_MAX)][C(RESULT_MAX)] = { static const unsigned int arc_pmu_cache_map[C(MAX)][C(OP_MAX)][C(RESULT_MAX)] = {
[C(L1D)] = { [C(L1D)] = {
[C(OP_READ)] = { [C(OP_READ)] = {
[C(RESULT_ACCESS)] = PERF_COUNT_ARC_LDC, [C(RESULT_ACCESS)] = PERF_COUNT_ARC_LDC,
......
...@@ -260,7 +260,7 @@ static void init_unwind_hdr(struct unwind_table *table, ...@@ -260,7 +260,7 @@ static void init_unwind_hdr(struct unwind_table *table,
{ {
const u8 *ptr; const u8 *ptr;
unsigned long tableSize = table->size, hdrSize; unsigned long tableSize = table->size, hdrSize;
unsigned n; unsigned int n;
const u32 *fde; const u32 *fde;
struct { struct {
u8 version; u8 version;
...@@ -462,7 +462,7 @@ static uleb128_t get_uleb128(const u8 **pcur, const u8 *end) ...@@ -462,7 +462,7 @@ static uleb128_t get_uleb128(const u8 **pcur, const u8 *end)
{ {
const u8 *cur = *pcur; const u8 *cur = *pcur;
uleb128_t value; uleb128_t value;
unsigned shift; unsigned int shift;
for (shift = 0, value = 0; cur < end; shift += 7) { for (shift = 0, value = 0; cur < end; shift += 7) {
if (shift + 7 > 8 * sizeof(value) if (shift + 7 > 8 * sizeof(value)
...@@ -483,7 +483,7 @@ static sleb128_t get_sleb128(const u8 **pcur, const u8 *end) ...@@ -483,7 +483,7 @@ static sleb128_t get_sleb128(const u8 **pcur, const u8 *end)
{ {
const u8 *cur = *pcur; const u8 *cur = *pcur;
sleb128_t value; sleb128_t value;
unsigned shift; unsigned int shift;
for (shift = 0, value = 0; cur < end; shift += 7) { for (shift = 0, value = 0; cur < end; shift += 7) {
if (shift + 7 > 8 * sizeof(value) if (shift + 7 > 8 * sizeof(value)
...@@ -609,7 +609,7 @@ static unsigned long read_pointer(const u8 **pLoc, const void *end, ...@@ -609,7 +609,7 @@ static unsigned long read_pointer(const u8 **pLoc, const void *end,
static signed fde_pointer_type(const u32 *cie) static signed fde_pointer_type(const u32 *cie)
{ {
const u8 *ptr = (const u8 *)(cie + 2); const u8 *ptr = (const u8 *)(cie + 2);
unsigned version = *ptr; unsigned int version = *ptr;
if (*++ptr) { if (*++ptr) {
const char *aug; const char *aug;
...@@ -904,7 +904,7 @@ int arc_unwind(struct unwind_frame_info *frame) ...@@ -904,7 +904,7 @@ int arc_unwind(struct unwind_frame_info *frame)
const u8 *ptr = NULL, *end = NULL; const u8 *ptr = NULL, *end = NULL;
unsigned long pc = UNW_PC(frame) - frame->call_frame; unsigned long pc = UNW_PC(frame) - frame->call_frame;
unsigned long startLoc = 0, endLoc = 0, cfa; unsigned long startLoc = 0, endLoc = 0, cfa;
unsigned i; unsigned int i;
signed ptrType = -1; signed ptrType = -1;
uleb128_t retAddrReg = 0; uleb128_t retAddrReg = 0;
const struct unwind_table *table; const struct unwind_table *table;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment