Home
last modified time | relevance | path

Searched refs:BUG_ON (Results 1 – 25 of 2344) sorted by relevance

12345678910>>...94

/Linux-v4.19/tools/testing/selftests/vm/
Dmap_populate.c24 #define BUG_ON(condition, description) \ macro
38 BUG_ON(ret <= 0, "read(sock)"); in parent_f()
42 BUG_ON(ret, "msync()"); in parent_f()
45 BUG_ON(ret <= 0, "write(sock)"); in parent_f()
48 BUG_ON(!WIFEXITED(status), "child in unexpected state"); in parent_f()
59 BUG_ON(smap == MAP_FAILED, "mmap()"); in child_f()
61 BUG_ON(*smap != 0xdeadbabe, "MAP_PRIVATE | MAP_POPULATE changed file"); in child_f()
64 BUG_ON(ret <= 0, "write(sock)"); in child_f()
67 BUG_ON(ret <= 0, "read(sock)"); in child_f()
69 BUG_ON(*smap == 0x22222BAD, "MAP_POPULATE didn't COW private page"); in child_f()
[all …]
/Linux-v4.19/lib/
Datomic64_test.c53 BUG_ON(atomic##bit##_##op(val, &v) != r); \
54 BUG_ON(atomic##bit##_read(&v) != r); \
62 BUG_ON(atomic##bit##_##op(val, &v) != v0); \
63 BUG_ON(atomic##bit##_read(&v) != r); \
79 BUG_ON(atomic##bit##_##op(&v, ##args) != ret); \
80 BUG_ON(atomic##bit##_read(&v) != expect); \
163 BUG_ON(v.counter != r); in test_atomic64()
167 BUG_ON(v.counter != r); in test_atomic64()
168 BUG_ON(atomic64_read(&v) != r); in test_atomic64()
197 BUG_ON(v.counter != r); in test_atomic64()
[all …]
Dplist.c152 BUG_ON(plist_head_empty(head)); in plist_requeue()
153 BUG_ON(plist_node_empty(node)); in plist_requeue()
189 BUG_ON(nr_expect != 0); in plist_test_check()
200 BUG_ON(!list_empty(&node_pos->prio_list)); in plist_test_check()
204 BUG_ON(prio_pos->prio > node_pos->prio); in plist_test_check()
205 BUG_ON(prio_pos->prio_list.next != &node_pos->prio_list); in plist_test_check()
209 BUG_ON(nr_expect != 0); in plist_test_check()
210 BUG_ON(prio_pos->prio_list.next != &first->prio_list); in plist_test_check()
218 BUG_ON(node->prio == plist_next(node)->prio); in plist_test_requeue()
Dlru_cache.c41 BUG_ON(!lc); \
42 BUG_ON(!lc->nr_elements); \
43 BUG_ON(test_and_set_bit(__LC_PARANOIA, &lc->flags)); \
55 BUG_ON(i >= lc_->nr_elements); \
56 BUG_ON(lc_->lc_element[i] != e_); } while (0)
266 BUG_ON(!lc); in __lc_find()
267 BUG_ON(!lc->nr_elements); in __lc_find()
325 BUG_ON(e->refcnt); in lc_del()
442 BUG_ON(!e); in __lc_get()
445 BUG_ON(++e->refcnt != 1); in __lc_get()
[all …]
/Linux-v4.19/net/mac802154/
Dmib.c37 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_dev_set_page_channel()
54 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_get_params()
70 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_set_params()
86 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_add_key()
101 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_del_key()
116 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_add_dev()
130 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_del_dev()
146 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_add_devkey()
162 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_del_devkey()
177 BUG_ON(dev->type != ARPHRD_IEEE802154); in mac802154_add_seclevel()
[all …]
/Linux-v4.19/drivers/clk/sirf/
Dclk-atlas7.c1452 BUG_ON(!clk); in atlas7_clk_init()
1454 BUG_ON(!clk); in atlas7_clk_init()
1456 BUG_ON(!clk); in atlas7_clk_init()
1458 BUG_ON(!clk); in atlas7_clk_init()
1460 BUG_ON(!clk); in atlas7_clk_init()
1462 BUG_ON(!clk); in atlas7_clk_init()
1467 BUG_ON(!clk); in atlas7_clk_init()
1471 BUG_ON(!clk); in atlas7_clk_init()
1475 BUG_ON(!clk); in atlas7_clk_init()
1480 BUG_ON(!clk); in atlas7_clk_init()
[all …]
/Linux-v4.19/tools/perf/bench/
Dsched-pipe.c66 BUG_ON(ret != sizeof(int)); in worker_thread()
68 BUG_ON(ret != sizeof(int)); in worker_thread()
71 BUG_ON(ret != sizeof(int)); in worker_thread()
73 BUG_ON(ret != sizeof(int)); in worker_thread()
99 BUG_ON(pipe(pipe_1)); in bench_sched_pipe()
100 BUG_ON(pipe(pipe_2)); in bench_sched_pipe()
125 BUG_ON(ret); in bench_sched_pipe()
132 BUG_ON(ret); in bench_sched_pipe()
Dnuma.c266 BUG_ON(ret); in bind_to_cpu()
276 BUG_ON(target_cpu < 0 || target_cpu >= g->p.nr_cpus); in bind_to_cpu()
281 BUG_ON(ret); in bind_to_cpu()
293 BUG_ON(cpus_per_node * nr_numa_nodes() != g->p.nr_cpus); in bind_to_node()
294 BUG_ON(!cpus_per_node); in bind_to_node()
297 BUG_ON(ret); in bind_to_node()
308 BUG_ON(cpu_stop > g->p.nr_cpus); in bind_to_node()
315 BUG_ON(ret); in bind_to_node()
325 BUG_ON(ret); in bind_to_cpumask()
334 BUG_ON(ret); in mempol_restore()
[all …]
/Linux-v4.19/mm/
Duserfaultfd.c243 BUG_ON(dst_addr >= dst_start + len); in __mcopy_atomic_hugetlb()
279 BUG_ON(!page); in __mcopy_atomic_hugetlb()
293 BUG_ON(page); in __mcopy_atomic_hugetlb()
358 BUG_ON(copied < 0); in __mcopy_atomic_hugetlb()
359 BUG_ON(err > 0); in __mcopy_atomic_hugetlb()
360 BUG_ON(!copied && !err); in __mcopy_atomic_hugetlb()
420 BUG_ON(dst_start & ~PAGE_MASK); in __mcopy_atomic()
421 BUG_ON(len & ~PAGE_MASK); in __mcopy_atomic()
424 BUG_ON(src_start + len <= src_start); in __mcopy_atomic()
425 BUG_ON(dst_start + len <= dst_start); in __mcopy_atomic()
[all …]
/Linux-v4.19/drivers/net/wireless/ti/wlcore/
Dhw_ops.h32 BUG_ON(1); in wlcore_hw_calc_tx_blocks()
42 BUG_ON(1); in wlcore_hw_set_tx_desc_blocks()
53 BUG_ON(1); in wlcore_hw_set_tx_desc_data_len()
63 BUG_ON(1); in wlcore_hw_get_rx_buf_align()
81 BUG_ON(1); in wlcore_hw_get_rx_packet_len()
113 BUG_ON(!wl->ops->convert_fw_status); in wlcore_hw_convert_fw_status()
122 BUG_ON(1); in wlcore_hw_sta_get_ap_rate_mask()
141 BUG_ON(1); in wlcore_hw_set_tx_desc_csum()
187 BUG_ON(1); in wlcore_hw_get_spare_blocks()
199 BUG_ON(1); in wlcore_hw_set_key()
[all …]
/Linux-v4.19/fs/ntfs/
Daops.c146 BUG_ON(!recs); in ntfs_end_buffer_async_read()
203 BUG_ON(!ni->runlist.rl && !ni->mft_no && !NInoAttr(ni)); in ntfs_read_block()
216 BUG_ON(!bh); in ntfs_read_block()
408 BUG_ON(!PageLocked(page)); in ntfs_readpage()
438 BUG_ON(ni->type != AT_DATA); in ntfs_readpage()
444 BUG_ON(ni->type != AT_DATA); in ntfs_readpage()
445 BUG_ON(ni->name_len); in ntfs_readpage()
572 BUG_ON(!NInoNonResident(ni)); in ntfs_write_block()
573 BUG_ON(NInoMstProtected(ni)); in ntfs_write_block()
577 BUG_ON(!PageUptodate(page)); in ntfs_write_block()
[all …]
Dcollate.c53 BUG_ON(data1_len != data2_len); in ntfs_collate_ntofs_ulong()
54 BUG_ON(data1_len != 4); in ntfs_collate_ntofs_ulong()
111 BUG_ON(cr != COLLATION_BINARY && cr != COLLATION_NTOFS_ULONG); in ntfs_collate()
113 BUG_ON(i < 0); in ntfs_collate()
117 BUG_ON(i < 0x10); in ntfs_collate()
Dbitmap.c58 BUG_ON(!vi); in __ntfs_bitmap_set_bits_in_run()
63 BUG_ON(start_bit < 0); in __ntfs_bitmap_set_bits_in_run()
64 BUG_ON(cnt < 0); in __ntfs_bitmap_set_bits_in_run()
65 BUG_ON(value > 1); in __ntfs_bitmap_set_bits_in_run()
121 BUG_ON(cnt <= 0); in __ntfs_bitmap_set_bits_in_run()
147 BUG_ON(cnt > 7); in __ntfs_bitmap_set_bits_in_run()
/Linux-v4.19/arch/sparc/include/asm/
Dvga.h25 BUG_ON((long) addr >= 0); in scr_writew()
32 BUG_ON((long) addr >= 0); in scr_readw()
39 BUG_ON((long) p >= 0); in scr_memsetw()
46 BUG_ON((long) d >= 0); in scr_memcpyw()
53 BUG_ON((long) d >= 0); in scr_memmovew()
/Linux-v4.19/drivers/gpu/drm/amd/include/linux/
Dchash.h293 BUG_ON((unsigned)iter.slot >= (1 << iter.table->bits)); in chash_iter_is_valid()
299 BUG_ON((unsigned)iter.slot >= (1 << iter.table->bits)); in chash_iter_is_empty()
306 BUG_ON((unsigned)iter.slot >= (1 << iter.table->bits)); in chash_iter_set_valid()
312 BUG_ON((unsigned)iter.slot >= (1 << iter.table->bits)); in chash_iter_set_invalid()
317 BUG_ON((unsigned)iter.slot >= (1 << iter.table->bits)); in chash_iter_set_empty()
323 BUG_ON(iter.table->key_size != 4); in chash_iter_key32()
324 BUG_ON((unsigned)iter.slot >= (1 << iter.table->bits)); in chash_iter_key32()
329 BUG_ON(iter.table->key_size != 8); in chash_iter_key64()
330 BUG_ON((unsigned)iter.slot >= (1 << iter.table->bits)); in chash_iter_key64()
335 BUG_ON((unsigned)iter.slot >= (1 << iter.table->bits)); in chash_iter_key()
[all …]
/Linux-v4.19/net/ceph/
Dmessenger.c121 BUG_ON(!con_flag_valid(con_flag)); in con_flag_clear()
128 BUG_ON(!con_flag_valid(con_flag)); in con_flag_set()
135 BUG_ON(!con_flag_valid(con_flag)); in con_flag_test()
143 BUG_ON(!con_flag_valid(con_flag)); in con_flag_test_and_clear()
151 BUG_ON(!con_flag_valid(con_flag)); in con_flag_test_and_set()
233 BUG_ON(ceph_msg_cache); in ceph_msgr_slab_init()
238 BUG_ON(ceph_msg_data_cache); in ceph_msgr_slab_init()
251 BUG_ON(!ceph_msg_data_cache); in ceph_msgr_slab_exit()
255 BUG_ON(!ceph_msg_cache); in ceph_msgr_slab_exit()
267 BUG_ON(zero_page == NULL); in _ceph_msgr_exit()
[all …]
/Linux-v4.19/arch/arm/kvm/
Dcoproc.h88 BUG_ON(!r->reg); in reset_unknown()
89 BUG_ON(r->reg >= ARRAY_SIZE(vcpu->arch.ctxt.cp15)); in reset_unknown()
95 BUG_ON(!r->reg); in reset_val()
96 BUG_ON(r->reg >= ARRAY_SIZE(vcpu->arch.ctxt.cp15)); in reset_val()
103 BUG_ON(!r->reg); in reset_unknown64()
104 BUG_ON(r->reg + 1 >= ARRAY_SIZE(vcpu->arch.ctxt.cp15)); in reset_unknown64()
113 BUG_ON(i1 == i2); in cmp_reg()
/Linux-v4.19/arch/ia64/sn/pci/
Dpci_dma.c37 BUG_ON(!dev_is_pci(dev)); in sn_dma_supported()
53 BUG_ON(!dev_is_pci(dev)); in sn_dma_set_mask()
88 BUG_ON(!dev_is_pci(dev)); in sn_dma_alloc_coherent()
146 BUG_ON(!dev_is_pci(dev)); in sn_dma_free_coherent()
187 BUG_ON(!dev_is_pci(dev)); in sn_dma_map_page()
223 BUG_ON(!dev_is_pci(dev)); in sn_dma_unmap_page()
247 BUG_ON(!dev_is_pci(dev)); in sn_dma_unmap_sg()
281 BUG_ON(!dev_is_pci(dev)); in sn_dma_map_sg()
320 BUG_ON(!dev_is_pci(dev)); in sn_dma_sync_single_for_cpu()
327 BUG_ON(!dev_is_pci(dev)); in sn_dma_sync_single_for_device()
[all …]
/Linux-v4.19/scripts/coccinelle/misc/
Dbugon.cocci1 /// Use BUG_ON instead of a if condition followed by BUG.
5 //# with a BUG_ON having the conditional expression of the if statement
37 +BUG_ON(e);
54 coccilib.org.print_todo(p[0], "WARNING use BUG_ON")
60 …="WARNING: Use BUG_ON instead of if condition followed by BUG.\nPlease make sure the condition has…
/Linux-v4.19/arch/x86/xen/
Dmulticalls.c64 BUG_ON(preemptible()); in xen_mc_flush()
75 BUG_ON(b->argidx != 0); in xen_mc_flush()
141 BUG_ON(preemptible()); in __xen_mc_entry()
142 BUG_ON(b->argidx >= MC_ARGS); in __xen_mc_entry()
160 BUG_ON(b->argidx >= MC_ARGS); in __xen_mc_entry()
169 BUG_ON(preemptible()); in xen_mc_extend_args()
170 BUG_ON(b->argidx >= MC_ARGS); in xen_mc_extend_args()
187 BUG_ON(b->argidx >= MC_ARGS); in xen_mc_extend_args()
/Linux-v4.19/fs/ocfs2/dlm/
Ddlmast.c71 BUG_ON(lock->ml.highest_blocked == LKM_NLMODE); in dlm_should_cancel_bast()
95 BUG_ON(!dlm); in __dlm_queue_ast()
96 BUG_ON(!lock); in __dlm_queue_ast()
148 BUG_ON(!dlm); in dlm_queue_ast()
149 BUG_ON(!lock); in dlm_queue_ast()
161 BUG_ON(!dlm); in __dlm_queue_bast()
162 BUG_ON(!lock); in __dlm_queue_bast()
168 BUG_ON(!list_empty(&lock->bast_list)); in __dlm_queue_bast()
185 BUG_ON(!dlm); in dlm_queue_bast()
186 BUG_ON(!lock); in dlm_queue_bast()
[all …]
/Linux-v4.19/drivers/staging/erofs/
Ddata.c28 BUG_ON(PageUptodate(page)); in read_endio()
57 BUG_ON(!page || !PageLocked(page)); in erofs_get_meta_page()
65 BUG_ON(err != PAGE_SIZE); in erofs_get_meta_page()
99 BUG_ON(is_inode_layout_compression(inode)); in erofs_map_blocks_flatmode()
126 BUG_ON(erofs_blkoff(map->m_pa) + map->m_plen > PAGE_SIZE); in erofs_map_blocks_flatmode()
193 BUG_ON(!nblocks); in erofs_read_raw_page()
236 BUG_ON(map.m_plen != map.m_llen); in erofs_read_raw_page()
246 BUG_ON(map.m_plen > PAGE_SIZE); in erofs_read_raw_page()
273 BUG_ON(erofs_blkoff(map.m_pa) != 0); in erofs_read_raw_page()
334 BUG_ON(bio != NULL); /* since we have only one bio -- must be NULL */ in erofs_raw_access_readpage()
[all …]
/Linux-v4.19/arch/arm64/mm/
Dmmu.c144 BUG_ON(!pgattr_change_is_safe(pte_val(old_pte), in init_pte()
162 BUG_ON(pmd_sect(pmd)); in alloc_init_cont_pte()
165 BUG_ON(!pgtable_alloc); in alloc_init_cont_pte()
170 BUG_ON(pmd_bad(pmd)); in alloc_init_cont_pte()
210 BUG_ON(!pgattr_change_is_safe(pmd_val(old_pmd), in init_pmd()
216 BUG_ON(pmd_val(old_pmd) != 0 && in init_pmd()
236 BUG_ON(pud_sect(pud)); in alloc_init_cont_pmd()
239 BUG_ON(!pgtable_alloc); in alloc_init_cont_pmd()
244 BUG_ON(pud_bad(pud)); in alloc_init_cont_pmd()
285 BUG_ON(!pgtable_alloc); in alloc_init_pud()
[all …]
/Linux-v4.19/fs/ocfs2/
Duptodate.c74 BUG_ON(!ci || !ci->ci_ops); in ocfs2_metadata_cache_owner()
81 BUG_ON(!ci || !ci->ci_ops); in ocfs2_metadata_cache_get_super()
88 BUG_ON(!ci || !ci->ci_ops); in ocfs2_metadata_cache_lock()
95 BUG_ON(!ci || !ci->ci_ops); in ocfs2_metadata_cache_unlock()
102 BUG_ON(!ci || !ci->ci_ops); in ocfs2_metadata_cache_io_lock()
109 BUG_ON(!ci || !ci->ci_ops); in ocfs2_metadata_cache_io_unlock()
130 BUG_ON(!ops); in ocfs2_metadata_cache_init()
176 BUG_ON(!ci || !ci->ci_ops); in ocfs2_metadata_cache_purge()
306 BUG_ON(ci->ci_num_cached >= OCFS2_CACHE_INFO_MAX_ARRAY); in ocfs2_append_cache_array()
525 BUG_ON(ocfs2_buffer_cached(ci, bh)); in ocfs2_set_new_buffer_uptodate()
[all …]
/Linux-v4.19/arch/powerpc/mm/
Dpgtable-book3e.c35 BUG_ON(mmu_psize_defs[mmu_vmemmap_psize].enc > 0xf); in vmemmap_create_mapping()
45 BUG_ON(map_kernel_page(start + i, phys, flags)); in vmemmap_create_mapping()
99 BUG_ON(pudp == NULL); in map_kernel_page()
106 BUG_ON(pmdp == NULL); in map_kernel_page()
112 BUG_ON(ptep == NULL); in map_kernel_page()

12345678910>>...94