/lib/ |
D | test_ubsan.c | 10 volatile int val = INT_MAX; in test_ubsan_add_overflow() local 12 val += 2; in test_ubsan_add_overflow() 17 volatile int val = INT_MIN; in test_ubsan_sub_overflow() local 20 val -= val2; in test_ubsan_sub_overflow() 25 volatile int val = INT_MAX / 2; in test_ubsan_mul_overflow() local 27 val *= 3; in test_ubsan_mul_overflow() 32 volatile int val = INT_MIN; in test_ubsan_negate_overflow() local 34 val = -val; in test_ubsan_negate_overflow() 39 volatile int val = 16; in test_ubsan_divrem_overflow() local 42 val /= val2; in test_ubsan_divrem_overflow() [all …]
|
D | refcount.c | 66 unsigned int new, val = atomic_read(&r->refs); in refcount_add_not_zero_checked() local 69 if (!val) in refcount_add_not_zero_checked() 72 if (unlikely(val == UINT_MAX)) in refcount_add_not_zero_checked() 75 new = val + i; in refcount_add_not_zero_checked() 76 if (new < val) in refcount_add_not_zero_checked() 79 } while (!atomic_try_cmpxchg_relaxed(&r->refs, &val, new)); in refcount_add_not_zero_checked() 123 unsigned int new, val = atomic_read(&r->refs); in refcount_inc_not_zero_checked() local 126 new = val + 1; in refcount_inc_not_zero_checked() 128 if (!val) in refcount_inc_not_zero_checked() 134 } while (!atomic_try_cmpxchg_relaxed(&r->refs, &val, new)); in refcount_inc_not_zero_checked() [all …]
|
D | clz_ctz.c | 17 int __weak __ctzsi2(int val); 18 int __weak __ctzsi2(int val) in __ctzsi2() argument 20 return __ffs(val); in __ctzsi2() 24 int __weak __clzsi2(int val); 25 int __weak __clzsi2(int val) in __clzsi2() argument 27 return 32 - fls(val); in __clzsi2() 31 int __weak __clzdi2(long val); 32 int __weak __ctzdi2(long val); 35 int __weak __clzdi2(long val) in __clzdi2() argument 37 return 32 - fls((int)val); in __clzdi2() [all …]
|
D | win_minmax.c | 30 const struct minmax_sample *val) in minmax_subwin_update() argument 32 u32 dt = val->t - m->s[0].t; in minmax_subwin_update() 44 m->s[2] = *val; in minmax_subwin_update() 45 if (unlikely(val->t - m->s[0].t > win)) { in minmax_subwin_update() 48 m->s[2] = *val; in minmax_subwin_update() 55 m->s[2] = m->s[1] = *val; in minmax_subwin_update() 61 m->s[2] = *val; in minmax_subwin_update() 69 struct minmax_sample val = { .t = t, .v = meas }; in minmax_running_max() local 71 if (unlikely(val.v >= m->s[0].v) || /* found new max? */ in minmax_running_max() 72 unlikely(val.t - m->s[2].t > win)) /* nothing left in window? */ in minmax_running_max() [all …]
|
D | iomap.c | 179 #define pio_write16be(val,port) outw(swab16(val),port) argument 180 #define pio_write32be(val,port) outl(swab32(val),port) argument 184 #define mmio_write16be(val,port) writew(swab16(val),port) argument 185 #define mmio_write32be(val,port) writel(swab32(val),port) argument 186 #define mmio_write64be(val,port) writeq(swab64(val),port) argument 189 void iowrite8(u8 val, void __iomem *addr) in iowrite8() argument 191 IO_COND(addr, outb(val,port), writeb(val, addr)); in iowrite8() 193 void iowrite16(u16 val, void __iomem *addr) in iowrite16() argument 195 IO_COND(addr, outw(val,port), writew(val, addr)); in iowrite16() 197 void iowrite16be(u16 val, void __iomem *addr) in iowrite16be() argument [all …]
|
D | atomic64.c | 49 s64 val; in atomic64_read() local 52 val = v->counter; in atomic64_read() 54 return val; in atomic64_read() 86 s64 val; \ 89 val = (v->counter c_op a); \ 91 return val; \ 100 s64 val; \ 103 val = v->counter; \ 106 return val; \ 137 s64 val; in atomic64_dec_if_positive() local [all …]
|
D | bcd.c | 5 unsigned _bcd2bin(unsigned char val) in _bcd2bin() argument 7 return (val & 0x0f) + (val >> 4) * 10; in _bcd2bin() 11 unsigned char _bin2bcd(unsigned val) in _bin2bcd() argument 13 return ((val / 10) << 4) + val % 10; in _bin2bcd()
|
D | usercopy.c | 52 unsigned long val; in check_zeroed_user() local 64 unsafe_get_user(val, (unsigned long __user *) from, err_fault); in check_zeroed_user() 66 val &= ~aligned_byte_mask(align); in check_zeroed_user() 69 if (unlikely(val)) in check_zeroed_user() 75 unsafe_get_user(val, (unsigned long __user *) from, err_fault); in check_zeroed_user() 79 val &= aligned_byte_mask(size); in check_zeroed_user() 83 return (val == 0); in check_zeroed_user()
|
D | ubsan.c | 86 static s_max get_signed_val(struct type_descriptor *type, void *val) in get_signed_val() argument 90 unsigned long ulong_val = (unsigned long)val; in get_signed_val() 96 return *(s64 *)val; in get_signed_val() 98 return *(s_max *)val; in get_signed_val() 101 static bool val_is_negative(struct type_descriptor *type, void *val) in val_is_negative() argument 103 return type_is_signed(type) && get_signed_val(type, val) < 0; in val_is_negative() 106 static u_max get_unsigned_val(struct type_descriptor *type, void *val) in get_unsigned_val() argument 109 return (unsigned long)val; in get_unsigned_val() 112 return *(u64 *)val; in get_unsigned_val() 114 return *(u_max *)val; in get_unsigned_val() [all …]
|
D | notifier-error-inject.c | 6 static int debugfs_errno_set(void *data, u64 val) in debugfs_errno_set() argument 8 *(int *)data = clamp_t(int, val, -MAX_ERRNO, 0); in debugfs_errno_set() 12 static int debugfs_errno_get(void *data, u64 *val) in debugfs_errno_get() argument 14 *val = *(int *)data; in debugfs_errno_get() 28 unsigned long val, void *p) in notifier_err_inject_callback() argument 36 if (action->val == val) { in notifier_err_inject_callback()
|
D | atomic64_test.c | 20 #define TEST(bit, op, c_op, val) \ argument 24 atomic##bit##_##op(val, &v); \ 25 r c_op val; \ 44 #define TEST_RETURN(bit, op, c_op, val) \ argument 48 r c_op val; \ 49 BUG_ON(atomic##bit##_##op(val, &v) != r); \ 53 #define TEST_FETCH(bit, op, c_op, val) \ argument 57 r c_op val; \ 58 BUG_ON(atomic##bit##_##op(val, &v) != v0); \ 62 #define RETURN_FAMILY_TEST(bit, op, c_op, val) \ argument [all …]
|
D | parser.c | 131 long val; in match_number() local 138 val = simple_strtol(buf, &endp, base); in match_number() 141 else if (val < (long)INT_MIN || val > (long)INT_MAX) in match_number() 144 *result = (int) val; in match_number() 163 u64 val; in match_u64int() local 169 ret = kstrtoull(buf, base, &val); in match_u64int() 171 *result = val; in match_u64int()
|
D | cmdline.c | 201 char *next_arg(char *args, char **param, char **val) in next_arg() argument 226 *val = NULL; in next_arg() 229 *val = args + equals + 1; in next_arg() 232 if (**val == '"') { in next_arg() 233 (*val)++; in next_arg()
|
D | rbtree_test.c | 23 u32 val; member 80 #define NODE_VAL(node) ((node)->val) 90 u32 val = node->val; in RB_DECLARE_CALLBACKS_MAX() local 96 if (parent->augmented < val) in RB_DECLARE_CALLBACKS_MAX() 97 parent->augmented = val; in RB_DECLARE_CALLBACKS_MAX() 104 node->augmented = val; in RB_DECLARE_CALLBACKS_MAX() 114 u32 val = node->val; in insert_augmented_cached() local 121 if (parent->augmented < val) in insert_augmented_cached() 122 parent->augmented = val; in insert_augmented_cached() 131 node->augmented = val; in insert_augmented_cached() [all …]
|
D | fault-inject.c | 155 static int debugfs_ul_set(void *data, u64 val) in debugfs_ul_set() argument 157 *(unsigned long *)data = val; in debugfs_ul_set() 161 static int debugfs_ul_get(void *data, u64 *val) in debugfs_ul_get() argument 163 *val = *(unsigned long *)data; in debugfs_ul_get() 177 static int debugfs_stacktrace_depth_set(void *data, u64 val) in debugfs_stacktrace_depth_set() argument 180 min_t(unsigned long, val, MAX_STACK_TRACE_DEPTH); in debugfs_stacktrace_depth_set()
|
D | find_bit.c | 134 unsigned long val = BITMAP_LAST_WORD_MASK(size); in find_last_bit() local 138 val &= addr[idx]; in find_last_bit() 139 if (val) in find_last_bit() 140 return idx * BITS_PER_LONG + __fls(val); in find_last_bit() 142 val = ~0ul; in find_last_bit()
|
D | kstrtox.c | 58 unsigned int val; in _parse_integer() local 61 val = c - '0'; in _parse_integer() 63 val = lc - 'a' + 10; in _parse_integer() 67 if (val >= base) in _parse_integer() 74 if (res > div_u64(ULLONG_MAX - val, base)) in _parse_integer() 77 res = res * base + val; in _parse_integer()
|
D | btree.c | 137 unsigned long val; in dec_key() local 141 val = key[i]; in dec_key() 142 key[i] = val - 1; in dec_key() 143 if (val) in dec_key() 165 void *val) in setval() argument 167 node[geo->no_longs + n] = (unsigned long) val; in setval() 272 unsigned long *key, void *val) in btree_update() argument 296 setval(geo, node, i, val); in btree_update() 449 unsigned long *key, void *val, int level, in btree_insert_level() argument 455 BUG_ON(!val); in btree_insert_level() [all …]
|
D | notifier-error-inject.h | 7 unsigned long val; member 13 .name = #action, .val = (action),
|
D | flex_proportions.c | 206 s64 val = percpu_counter_read(&pl->events); in fprop_reflect_period_percpu() local 208 if (val < (nr_cpu_ids * PROP_BATCH)) in fprop_reflect_period_percpu() 209 val = percpu_counter_sum(&pl->events); in fprop_reflect_period_percpu() 212 -val + (val >> (period-pl->period)), PROP_BATCH); in fprop_reflect_period_percpu()
|
D | genalloc.c | 45 unsigned long val, nval; in set_bits_ll() local 49 val = nval; in set_bits_ll() 50 if (val & mask_to_set) in set_bits_ll() 53 } while ((nval = cmpxchg(addr, val, val | mask_to_set)) != val); in set_bits_ll() 60 unsigned long val, nval; in clear_bits_ll() local 64 val = nval; in clear_bits_ll() 65 if ((val & mask_to_clear) != mask_to_clear) in clear_bits_ll() 68 } while ((nval = cmpxchg(addr, val, val & ~mask_to_clear)) != val); in clear_bits_ll()
|
D | dynamic_debug.c | 278 static inline int parse_lineno(const char *str, unsigned int *val) in parse_lineno() argument 282 *val = 0; in parse_lineno() 285 if (kstrtouint(str, 10, val) < 0) { in parse_lineno() 912 static int ddebug_dyndbg_param_cb(char *param, char *val, in ddebug_dyndbg_param_cb() argument 927 ddebug_exec_queries((val ? val : "+p"), modname); in ddebug_dyndbg_param_cb() 933 static int ddebug_dyndbg_boot_param_cb(char *param, char *val, in ddebug_dyndbg_boot_param_cb() argument 936 vpr_info("%s=\"%s\"\n", param, val); in ddebug_dyndbg_boot_param_cb() 937 return ddebug_dyndbg_param_cb(param, val, NULL, 0); in ddebug_dyndbg_boot_param_cb() 945 int ddebug_dyndbg_module_param_cb(char *param, char *val, const char *module) in ddebug_dyndbg_module_param_cb() argument 947 vpr_info("module: %s %s=\"%s\"\n", module, param, val); in ddebug_dyndbg_module_param_cb() [all …]
|
/lib/mpi/ |
D | mpicoder.c | 41 MPI val = NULL; in mpi_read_raw_data() local 57 val = mpi_alloc(nlimbs); in mpi_read_raw_data() 58 if (!val) in mpi_read_raw_data() 60 val->nbits = nbits; in mpi_read_raw_data() 61 val->sign = 0; in mpi_read_raw_data() 62 val->nlimbs = nlimbs; in mpi_read_raw_data() 74 val->d[j - 1] = a; in mpi_read_raw_data() 77 return val; in mpi_read_raw_data() 85 MPI val; in mpi_read_from_buffer() local 103 val = mpi_read_raw_data(buffer + 2, nbytes); in mpi_read_from_buffer() [all …]
|
/lib/zstd/ |
D | mem.h | 77 ZSTD_STATIC void ZSTD_writeLE16(void *memPtr, U16 val) { put_unaligned_le16(val, memPtr); } in ZSTD_writeLE16() argument 81 ZSTD_STATIC void ZSTD_writeLE24(void *memPtr, U32 val) in ZSTD_writeLE24() argument 83 ZSTD_writeLE16(memPtr, (U16)val); in ZSTD_writeLE24() 84 ((BYTE *)memPtr)[2] = (BYTE)(val >> 16); in ZSTD_writeLE24() 103 ZSTD_STATIC void ZSTD_writeLEST(void *memPtr, size_t val) in ZSTD_writeLEST() argument 106 ZSTD_writeLE32(memPtr, (U32)val); in ZSTD_writeLEST() 108 ZSTD_writeLE64(memPtr, (U64)val); in ZSTD_writeLEST() 129 ZSTD_STATIC void ZSTD_writeBEST(void *memPtr, size_t val) in ZSTD_writeBEST() argument 132 ZSTD_writeBE32(memPtr, (U32)val); in ZSTD_writeBEST() 134 ZSTD_writeBE64(memPtr, (U64)val); in ZSTD_writeBEST()
|
/lib/zlib_inflate/ |
D | inftrees.c | 106 this.val = (unsigned short)0; in zlib_inflate_table() 207 this.val = work[sym]; in zlib_inflate_table() 211 this.val = base[work[sym]]; in zlib_inflate_table() 215 this.val = 0; in zlib_inflate_table() 273 (*table)[low].val = (unsigned short)(next - *table); in zlib_inflate_table() 286 this.val = (unsigned short)0; in zlib_inflate_table()
|