/lib/ |
D | hweight.c | 21 unsigned int res = w - ((w >> 1) & 0x55555555); in __sw_hweight32() 22 res = (res & 0x33333333) + ((res >> 2) & 0x33333333); in __sw_hweight32() 23 res = (res + (res >> 4)) & 0x0F0F0F0F; in __sw_hweight32() 24 res = res + (res >> 8); in __sw_hweight32() 25 return (res + (res >> 16)) & 0x000000FF; in __sw_hweight32() 32 unsigned int res = w - ((w >> 1) & 0x5555); in __sw_hweight16() local 33 res = (res & 0x3333) + ((res >> 2) & 0x3333); in __sw_hweight16() 34 res = (res + (res >> 4)) & 0x0F0F; in __sw_hweight16() 35 return (res + (res >> 8)) & 0x00FF; in __sw_hweight16() 41 unsigned int res = w - ((w >> 1) & 0x55); in __sw_hweight8() local [all …]
|
D | kstrtox.c | 50 unsigned long long res; in _parse_integer() local 53 res = 0; in _parse_integer() 73 if (unlikely(res & (~0ull << 60))) { in _parse_integer() 74 if (res > div_u64(ULLONG_MAX - val, base)) in _parse_integer() 77 res = res * base + val; in _parse_integer() 81 *p = res; in _parse_integer() 85 static int _kstrtoull(const char *s, unsigned int base, unsigned long long *res) in _kstrtoull() argument 101 *res = _res; in _kstrtoull() 121 int kstrtoull(const char *s, unsigned int base, unsigned long long *res) in kstrtoull() argument 125 return _kstrtoull(s, base, res); in kstrtoull() [all …]
|
D | strncpy_from_user.c | 31 unsigned long res = 0; in do_strncpy_from_user() local 40 unsafe_get_user(c, (unsigned long __user *)(src+res), byte_at_a_time); in do_strncpy_from_user() 42 *(unsigned long *)(dst+res) = c; in do_strncpy_from_user() 46 return res + find_zero(data); in do_strncpy_from_user() 48 res += sizeof(unsigned long); in do_strncpy_from_user() 56 unsafe_get_user(c,src+res, efault); in do_strncpy_from_user() 57 dst[res] = c; in do_strncpy_from_user() 59 return res; in do_strncpy_from_user() 60 res++; in do_strncpy_from_user() 68 if (res >= count) in do_strncpy_from_user() [all …]
|
D | devres.c | 15 void devm_ioremap_release(struct device *dev, void *res) in devm_ioremap_release() argument 17 iounmap(*(void __iomem **)res); in devm_ioremap_release() 20 static int devm_ioremap_match(struct device *dev, void *res, void *match_data) in devm_ioremap_match() argument 22 return *(void **)res == match_data; in devm_ioremap_match() 135 const struct resource *res) in devm_ioremap_resource() argument 142 if (!res || resource_type(res) != IORESOURCE_MEM) { in devm_ioremap_resource() 147 size = resource_size(res); in devm_ioremap_resource() 149 if (!devm_request_mem_region(dev, res->start, size, dev_name(dev))) { in devm_ioremap_resource() 150 dev_err(dev, "can't request region for resource %pR\n", res); in devm_ioremap_resource() 154 dest_ptr = devm_ioremap(dev, res->start, size); in devm_ioremap_resource() [all …]
|
D | test_bitfield.c | 12 #define CHECK_ENC_GET_U(tp, v, field, res) do { \ argument 17 if (_res != res) { \ 18 pr_warn("u" #tp "_encode_bits(" #v ", " #field ") is 0x%llx != " #res "\n",\ 27 #define CHECK_ENC_GET_LE(tp, v, field, res) do { \ argument 32 if (_res != cpu_to_le##tp(res)) { \ 35 (u64)(res)); \ 43 #define CHECK_ENC_GET_BE(tp, v, field, res) do { \ argument 48 if (_res != cpu_to_be##tp(res)) { \ 51 (u64)(res)); \ 59 #define CHECK_ENC_GET(tp, v, field, res) do { \ argument [all …]
|
D | strnlen_user.c | 26 unsigned long align, res = 0; in do_strnlen_user() local 45 return res + find_zero(data) + 1 - align; in do_strnlen_user() 47 res += sizeof(unsigned long); in do_strnlen_user() 52 unsafe_get_user(c, (unsigned long __user *)(src+res), efault); in do_strnlen_user() 54 res -= align; in do_strnlen_user() 60 if (res >= count) in do_strnlen_user()
|
D | usercopy.c | 10 unsigned long res = n; in _copy_from_user() local 14 res = raw_copy_from_user(to, from, n); in _copy_from_user() 16 if (unlikely(res)) in _copy_from_user() 17 memset(to + (n - res), 0, res); in _copy_from_user() 18 return res; in _copy_from_user()
|
D | string.c | 184 long res = 0; in strscpy() local 208 c = read_word_at_a_time(src+res); in strscpy() 212 *(unsigned long *)(dest+res) = c & zero_bytemask(data); in strscpy() 213 return res + find_zero(data); in strscpy() 215 *(unsigned long *)(dest+res) = c; in strscpy() 216 res += sizeof(unsigned long); in strscpy() 224 c = src[res]; in strscpy() 225 dest[res] = c; in strscpy() 227 return res; in strscpy() 228 res++; in strscpy() [all …]
|
D | cmdline.c | 89 int res, i = 1; in get_options() local 92 res = get_option((char **)&str, ints + i); in get_options() 93 if (res == 0) in get_options() 95 if (res == 3) { in get_options() 108 if (res == 1) in get_options()
|
D | digsig.c | 78 MPI in = NULL, res = NULL, pkey[2]; in digsig_verify_rsa() local 141 res = mpi_alloc(mpi_get_nlimbs(in) * 2); in digsig_verify_rsa() 142 if (!res) in digsig_verify_rsa() 145 err = mpi_powm(res, in, pkey[1], pkey[0]); in digsig_verify_rsa() 149 if (mpi_get_nlimbs(res) * BYTES_PER_MPI_LIMB > mlen) { in digsig_verify_rsa() 154 p = mpi_get_buffer(res, &l, NULL); in digsig_verify_rsa() 174 mpi_free(res); in digsig_verify_rsa()
|
D | string_helpers.c | 600 int i, res; in kstrdup_quotable_cmdline() local 606 res = get_cmdline(task, buffer, PAGE_SIZE - 1); in kstrdup_quotable_cmdline() 607 buffer[res] = '\0'; in kstrdup_quotable_cmdline() 610 while (--res >= 0 && buffer[res] == '\0') in kstrdup_quotable_cmdline() 614 for (i = 0; i <= res; i++) in kstrdup_quotable_cmdline()
|
D | seq_buf.c | 269 int res = -1; local 278 res = end - buf; 281 seq_buf_commit(s, res); 283 return res;
|
D | test-kstrtox.c | 51 type res; \ 54 rv = fn(t->str, t->base, &res); \ 60 if (res != t->expected_res) { \ 62 t->str, t->base, t->expected_res, res); \
|
D | iov_iter.c | 1192 unsigned long res = 0; in iov_iter_alignment() local 1201 (res |= (unsigned long)v.iov_base | v.iov_len, 0), in iov_iter_alignment() 1202 res |= v.bv_offset | v.bv_len, in iov_iter_alignment() 1203 res |= (unsigned long)v.iov_base | v.iov_len in iov_iter_alignment() 1205 return res; in iov_iter_alignment() 1211 unsigned long res = 0; in iov_iter_gap_alignment() local 1220 (res |= (!res ? 0 : (unsigned long)v.iov_base) | in iov_iter_gap_alignment() 1222 (res |= (!res ? 0 : (unsigned long)v.bv_offset) | in iov_iter_gap_alignment() 1224 (res |= (!res ? 0 : (unsigned long)v.iov_base) | in iov_iter_gap_alignment() 1227 return res; in iov_iter_gap_alignment() [all …]
|
D | kstrtox.h | 7 unsigned int _parse_integer(const char *s, unsigned int base, unsigned long long *res);
|
D | test-string_helpers.c | 341 char *res, in test_string_get_size_check() argument 345 if (!memcmp(res, exp, strlen(exp) + 1)) in test_string_get_size_check() 348 res[string_get_size_maxbuf - 1] = '\0'; in test_string_get_size_check() 353 pr_warn("expected: '%s', got '%s'\n", exp, res); in test_string_get_size_check()
|
D | random32.c | 82 u32 res; in prandom_u32() local 84 res = prandom_u32_state(state); in prandom_u32() 87 return res; in prandom_u32()
|
D | vsprintf.c | 981 char *resource_string(char *buf, char *end, struct resource *res, in resource_string() argument 1018 #define FLAG_BUF_SIZE (2 * sizeof(res->flags)) in resource_string() 1028 if (check_pointer(&buf, end, res, spec)) in resource_string() 1032 if (res->flags & IORESOURCE_IO) { in resource_string() 1035 } else if (res->flags & IORESOURCE_MEM) { in resource_string() 1038 } else if (res->flags & IORESOURCE_IRQ) { in resource_string() 1041 } else if (res->flags & IORESOURCE_DMA) { in resource_string() 1044 } else if (res->flags & IORESOURCE_BUS) { in resource_string() 1052 if (decode && res->flags & IORESOURCE_UNSET) { in resource_string() 1054 p = number(p, pend, resource_size(res), *specp); in resource_string() [all …]
|
D | genalloc.c | 772 static void devm_gen_pool_release(struct device *dev, void *res) in devm_gen_pool_release() argument 774 gen_pool_destroy(*(struct gen_pool **)res); in devm_gen_pool_release() 777 static int devm_gen_pool_match(struct device *dev, void *res, void *data) in devm_gen_pool_match() argument 779 struct gen_pool **p = res; in devm_gen_pool_match()
|
D | inflate.c | 1201 int res; in gunzip() local 1258 if ((res = inflate())) { in gunzip() 1259 switch (res) { in gunzip()
|
D | debugobjects.c | 1153 int res = -EINVAL; in check_results() local 1179 res = 0; in check_results() 1182 if (res) in check_results() 1184 return res; in check_results()
|
/lib/vdso/ |
D | gettimeofday.c | 121 __cvdso_clock_gettime32(clockid_t clock, struct old_timespec32 *res) in __cvdso_clock_gettime32() argument 130 return clock_gettime32_fallback(clock, res); in __cvdso_clock_gettime32() 137 res->tv_sec = ts.tv_sec; in __cvdso_clock_gettime32() 138 res->tv_nsec = ts.tv_nsec; in __cvdso_clock_gettime32() 181 int __cvdso_clock_getres_common(clockid_t clock, struct __kernel_timespec *res) in __cvdso_clock_getres_common() argument 217 if (likely(res)) { in __cvdso_clock_getres_common() 218 res->tv_sec = 0; in __cvdso_clock_getres_common() 219 res->tv_nsec = ns; in __cvdso_clock_getres_common() 224 int __cvdso_clock_getres(clockid_t clock, struct __kernel_timespec *res) in __cvdso_clock_getres() argument 226 int ret = __cvdso_clock_getres_common(clock, res); in __cvdso_clock_getres() [all …]
|
/lib/mpi/ |
D | mpi-pow.c | 24 int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) in mpi_powm() argument 46 rp = res->d; in mpi_powm() 55 res->nlimbs = (msize == 1 && mod->d[0] == 1) ? 0 : 1; in mpi_powm() 56 if (res->nlimbs) { in mpi_powm() 57 if (mpi_resize(res, 1) < 0) in mpi_powm() 59 rp = res->d; in mpi_powm() 62 res->sign = 0; in mpi_powm() 99 res->nlimbs = 0; in mpi_powm() 100 res->sign = 0; in mpi_powm() 104 if (res->alloced < size) { in mpi_powm() [all …]
|
/lib/fonts/ |
D | fonts.c | 109 int i, c, cc, res; in get_default_font() local 131 res = (xres / f->width) * (yres / f->height) / 1000; in get_default_font() 132 if (res > 20) in get_default_font() 133 c += 20 - res; in get_default_font()
|
/lib/math/ |
D | div64.c | 33 uint64_t res, d = 1; in __div64_32() local 37 res = 0; in __div64_32() 40 res = (uint64_t) high << 32; in __div64_32() 52 res += d; in __div64_32() 58 *n = res; in __div64_32()
|