/lib/ |
D | test_bitmap.c | 41 unsigned int nbits) in __check_eq_bitmap() argument 43 if (!bitmap_equal(exp_bmap, bmap, nbits)) { in __check_eq_bitmap() 46 nbits, exp_bmap, nbits, bmap); in __check_eq_bitmap() 55 const unsigned long *bitmap, unsigned int nbits) in __check_eq_pbl() argument 57 snprintf(pbl_buffer, sizeof(pbl_buffer), "%*pbl", nbits, bitmap); in __check_eq_pbl() 215 const int nbits; member 303 bmap, ptest.nbits); in __test_bitmap_parselist() 308 err = bitmap_parselist(ptest.in, bmap, ptest.nbits); in __test_bitmap_parselist() 319 && !__bitmap_equal(bmap, ptest.expected, ptest.nbits)) { in __test_bitmap_parselist() 346 unsigned int nbits, next_bit; in test_bitmap_arr32() local [all …]
|
D | bitmap.c | 102 unsigned shift, unsigned nbits) in __bitmap_shift_right() argument 104 unsigned k, lim = BITS_TO_LONGS(nbits); in __bitmap_shift_right() 106 unsigned long mask = BITMAP_LAST_WORD_MASK(nbits); in __bitmap_shift_right() 147 unsigned int shift, unsigned int nbits) in __bitmap_shift_left() argument 150 unsigned int lim = BITS_TO_LONGS(nbits); in __bitmap_shift_left() 380 int c, old_c, totaldigits, ndigits, nchunks, nbits; in __bitmap_parse() local 386 nchunks = nbits = totaldigits = c = 0; in __bitmap_parse() 438 nbits += (nchunks == 1) ? nbits_to_hold_value(chunk) : CHUNKSZ; in __bitmap_parse() 439 if (nbits > nmaskbits) in __bitmap_parse() 515 unsigned long *bitmap, int nbits) in bitmap_set_region() argument [all …]
|
D | find_bit.c | 31 const unsigned long *addr2, unsigned long nbits, in _find_next_bit() argument 36 if (unlikely(start >= nbits)) in _find_next_bit() 37 return nbits; in _find_next_bit() 50 if (start >= nbits) in _find_next_bit() 51 return nbits; in _find_next_bit() 59 return min(start + __ffs(tmp), nbits); in _find_next_bit() 166 const unsigned long *addr2, unsigned long nbits, in _find_next_bit_le() argument 171 if (unlikely(start >= nbits)) in _find_next_bit_le() 172 return nbits; in _find_next_bit_le() 185 if (start >= nbits) in _find_next_bit_le() [all …]
|
D | genalloc.c | 186 int nbits = size >> pool->min_alloc_order; in gen_pool_add_owner() local 188 BITS_TO_LONGS(nbits) * sizeof(long); in gen_pool_add_owner() 281 int nbits, start_bit, end_bit, remain; in gen_pool_alloc_algo_owner() local 293 nbits = (size + (1UL << order) - 1) >> order; in gen_pool_alloc_algo_owner() 303 nbits, data, pool, chunk->start_addr); in gen_pool_alloc_algo_owner() 306 remain = bitmap_set_ll(chunk->bits, start_bit, nbits); in gen_pool_alloc_algo_owner() 309 nbits - remain); in gen_pool_alloc_algo_owner() 315 size = nbits << order; in gen_pool_alloc_algo_owner() 490 int start_bit, nbits, remain; in gen_pool_free_owner() local 499 nbits = (size + (1UL << order) - 1) >> order; in gen_pool_free_owner() [all …]
|
D | find_bit_benchmark.c | 116 unsigned long nbits = BITMAP_LEN / SPARSE; in find_bit_test() local 139 while (nbits--) { in find_bit_test()
|
D | test_printf.c | 508 const int nbits = 1 << 16; in large_bitmap() local 509 unsigned long *bits = bitmap_zalloc(nbits, GFP_KERNEL); in large_bitmap() 515 test("1-20,60000-60014", "%*pbl", nbits, bits); in large_bitmap()
|
D | bch.c | 1001 unsigned int nbits; in decode_bch() local 1044 nbits = (len*8)+bch->ecc_bits; in decode_bch() 1046 if (errloc[i] >= nbits) { in decode_bch() 1050 errloc[i] = nbits-1-errloc[i]; in decode_bch() 1179 unsigned int i, j, nbits, r, word, *roots; in compute_generator_polynomial() local 1221 nbits = (n > 32) ? 32 : n; in compute_generator_polynomial() 1222 for (j = 0, word = 0; j < nbits; j++) { in compute_generator_polynomial() 1227 n -= nbits; in compute_generator_polynomial()
|
/lib/mpi/ |
D | mpicoder.c | 39 unsigned nbits, nlimbs; in mpi_read_raw_data() local 48 nbits = nbytes * 8; in mpi_read_raw_data() 49 if (nbits > MAX_EXTERN_MPI_BITS) { in mpi_read_raw_data() 50 pr_info("MPI: mpi too large (%u bits)\n", nbits); in mpi_read_raw_data() 54 nbits -= count_leading_zeros(buffer[0]) - (BITS_PER_LONG - 8); in mpi_read_raw_data() 60 val->nbits = nbits; in mpi_read_raw_data() 84 unsigned int nbits, nbytes; in mpi_read_from_buffer() local 89 nbits = buffer[0] << 8 | buffer[1]; in mpi_read_from_buffer() 91 if (nbits > MAX_EXTERN_MPI_BITS) { in mpi_read_from_buffer() 92 pr_info("MPI: mpi too large (%u bits)\n", nbits); in mpi_read_from_buffer() [all …]
|
D | mpiutil.c | 52 a->nbits = 0; in mpi_alloc()
|
/lib/math/ |
D | prime_numbers.c | 9 #define bitmap_size(nbits) (BITS_TO_LONGS(nbits) * sizeof(unsigned long)) argument
|