Home
last modified time | relevance | path

Searched refs:is_power_of_2 (Results 1 – 25 of 299) sorted by relevance

12345678910>>...12

/linux-6.6.21/include/linux/
Drandom.h79 if (likely(is_power_of_2(ceil) || (u8)mult >= (1U << 8) % ceil)) in get_random_u32_below()
83 if (likely(is_power_of_2(ceil) || (u16)mult >= (1U << 16) % ceil)) in get_random_u32_below()
87 if (likely(is_power_of_2(ceil) || (u32)mult >= -ceil % ceil)) in get_random_u32_below()
Dlog2.h45 bool is_power_of_2(unsigned long n) in is_power_of_2() function
230 if (is_power_of_2(n)) in __bits_per()
Dgeneric-radix-tree.h108 if (!is_power_of_2(obj_size)) { in __idx_to_offset()
196 if (!is_power_of_2(obj_size) && in __genradix_iter_advance()
Diommu-helper.h23 BUG_ON(!is_power_of_2(boundary_size)); in iommu_is_span_boundary()
/linux-6.6.21/tools/perf/util/bpf_skel/
Daugmented_raw_syscalls.bpf.c21 #define is_power_of_2(n) (n != 0 && ((n & (n - 1)) == 0)) macro
165 …_Static_assert(is_power_of_2(sizeof(augmented_arg->value)), "sizeof(augmented_arg->value) needs to… in augmented_arg__read_str()
203 …_Static_assert(is_power_of_2(sizeof(augmented_args->saddr)), "sizeof(augmented_args->saddr) needs … in sys_enter_connect()
/linux-6.6.21/fs/verity/
Dhash_algs.c244 BUG_ON(!is_power_of_2(alg->digest_size)); in fsverity_check_hash_algs()
245 BUG_ON(!is_power_of_2(alg->block_size)); in fsverity_check_hash_algs()
/linux-6.6.21/mm/
Dhugetlb_vmemmap.h36 if (!is_power_of_2(sizeof(struct page))) in hugetlb_vmemmap_optimizable_size()
/linux-6.6.21/arch/x86/kvm/
Dkvm_cache_regs.h163 BUILD_BUG_ON(!is_power_of_2(cr0_bit)); in kvm_is_cr0_bit_set()
185 BUILD_BUG_ON(!is_power_of_2(cr4_bit)); in kvm_is_cr4_bit_set()
/linux-6.6.21/scripts/dtc/
Ddtc.c26 static int is_power_of_2(int x) in is_power_of_2() function
210 if (!is_power_of_2(alignsize)) in main()
/linux-6.6.21/include/crypto/
Dctr.h31 if (WARN_ON_ONCE(!is_power_of_2(blocksize))) in crypto_ctr_encrypt_walk()
/linux-6.6.21/tools/include/linux/
Dlog2.h38 bool is_power_of_2(unsigned long n) in is_power_of_2() function
/linux-6.6.21/drivers/cxl/
Dcxl.h105 !is_power_of_2(granularity)) in granularity_to_eig()
115 if (is_power_of_2(ways)) { in ways_to_eiw()
122 if (!is_power_of_2(ways)) in ways_to_eiw()
/linux-6.6.21/drivers/scsi/bnx2i/
Dbnx2i_sysfs.c77 (is_power_of_2(val))) in bnx2i_set_sq_info()
/linux-6.6.21/arch/x86/include/asm/
Ddiv64.h26 if (__builtin_constant_p(__base) && is_power_of_2(__base)) { \
/linux-6.6.21/drivers/gpu/drm/i915/
Di915_ioctl.c57 GEM_BUG_ON(!is_power_of_2(entry->size)); in i915_reg_read_ioctl()
/linux-6.6.21/arch/powerpc/mm/
Dinit-common.c134 BUG_ON(!is_power_of_2(minalign)); in pgtable_cache_add()
/linux-6.6.21/sound/mips/
Dsnd-n64.c170 if (is_power_of_2(c->min)) { in hw_rule_period_size()
174 if (is_power_of_2(c->max)) { in hw_rule_period_size()
/linux-6.6.21/arch/arm/mm/
Dcache-uniphier.c350 !is_power_of_2(data->line_size)) { in __uniphier_cache_init()
358 !is_power_of_2(data->nsets)) { in __uniphier_cache_init()
/linux-6.6.21/arch/um/kernel/
Dum_arch.c300 if (kstrtoul(to_parse, 10, &res) == 0 && is_power_of_2(res)) in parse_cache_line()
332 BUILD_BUG_ON(!is_power_of_2(STUB_DATA_PAGES)); in linux_main()
/linux-6.6.21/drivers/infiniband/hw/vmw_pvrdma/
Dpvrdma_doorbell.c58 if (!is_power_of_2(num)) in pvrdma_uar_table_init()
/linux-6.6.21/drivers/media/rc/img-ir/
Dimg-ir-sony.c75 if (!is_power_of_2(protocols)) { in img_ir_sony_filter()
/linux-6.6.21/drivers/gpu/drm/i915/gt/
Dintel_ring.h138 GEM_BUG_ON(!is_power_of_2(size)); in __intel_ring_space()
/linux-6.6.21/drivers/net/ipa/
Dreg.h85 if (WARN_ON(!is_power_of_2(fmask))) in reg_bit()
/linux-6.6.21/drivers/net/ethernet/huawei/hinic/
Dhinic_hw_wq.c513 if (!is_power_of_2(wqebb_size)) { in hinic_wq_allocate()
532 if (!is_power_of_2(num_wqebbs_per_page)) { in hinic_wq_allocate()
610 if (!is_power_of_2(wqebb_size)) { in hinic_wqs_cmdq_alloc()
629 if (!is_power_of_2(num_wqebbs_per_page)) { in hinic_wqs_cmdq_alloc()
/linux-6.6.21/fs/pstore/
Dram.c762 if (pdata->record_size && !is_power_of_2(pdata->record_size)) in ramoops_probe()
764 if (pdata->console_size && !is_power_of_2(pdata->console_size)) in ramoops_probe()
766 if (pdata->ftrace_size && !is_power_of_2(pdata->ftrace_size)) in ramoops_probe()
768 if (pdata->pmsg_size && !is_power_of_2(pdata->pmsg_size)) in ramoops_probe()

12345678910>>...12