Home
last modified time | relevance | path

Searched refs:page_sz (Results 1 – 15 of 15) sorted by relevance

/linux/tools/testing/selftests/arm64/mte/
H A Dcheck_ksm_options.c23 static size_t page_sz; variable
110 ptr = mte_allocate_memory(TEST_UNIT * page_sz, mem_type, mapping, true); in check_madvise_options()
111 if (check_allocated_memory(ptr, TEST_UNIT * page_sz, mem_type, false) != KSFT_PASS) in check_madvise_options()
115 memset(ptr, 'A', TEST_UNIT * page_sz); in check_madvise_options()
116 ret = madvise(ptr, TEST_UNIT * page_sz, MADV_MERGEABLE); in check_madvise_options()
127 mte_free_memory(ptr, TEST_UNIT * page_sz, mem_type, true); in check_madvise_options()
138 page_sz = getpagesize(); in main()
139 if (!page_sz) { in main()
H A Dcheck_user_mem.c22 static size_t page_sz; variable
43 int sizes[] = {1, 2, 3, 8, 16, 32, 4096, page_sz}; in check_usermem_access_fault()
46 len = 2 * page_sz; in check_usermem_access_fault()
201 int tag_offsets[] = {page_sz, MT_GRANULE_SIZE}; in main()
204 page_sz = getpagesize(); in main()
205 if (!page_sz) { in main()
/linux/arch/sparc/mm/
H A Dtsb.c197 unsigned long page_sz, tte; in setup_tsb_params() local
228 page_sz = 8192; in setup_tsb_params()
233 page_sz = 64 * 1024; in setup_tsb_params()
238 page_sz = 64 * 1024; in setup_tsb_params()
243 page_sz = 64 * 1024; in setup_tsb_params()
248 page_sz = 512 * 1024; in setup_tsb_params()
253 page_sz = 512 * 1024; in setup_tsb_params()
258 page_sz = 512 * 1024; in setup_tsb_params()
263 page_sz = 4 * 1024 * 1024; in setup_tsb_params()
271 tte |= pte_sz_bits(page_sz); in setup_tsb_params()
[all …]
/linux/tools/testing/selftests/powerpc/nx-gzip/
H A Dgunz_test.c94 const int page_sz = 1<<16; variable
172 static int nx_touch_pages_dde(struct nx_dde_t *ddep, long buf_sz, long page_sz, in nx_touch_pages_dde() argument
199 nxu_touch_pages((void *)buf_addr, buf_len, page_sz, wr); in nx_touch_pages_dde()
202 buf_sz), page_sz, wr); in nx_touch_pages_dde()
230 nxu_touch_pages((void *)buf_addr, buf_len, page_sz, wr); in nx_touch_pages_dde()
236 nxu_touch_pages((void *)buf_addr, buf_len, page_sz, wr); in nx_touch_pages_dde()
403 fifo_in_len + page_sz)) != NULL); in decompress_file()
405 fifo_out_len + page_sz + line_sz)) != NULL); in decompress_file()
408 nxu_touch_pages(fifo_out, fifo_out_len, page_sz, 1); in decompress_file()
692 nxu_touch_pages(cmdp, sizeof(struct nx_gzip_crb_cpb_t), page_sz, 1); in decompress_file()
[all …]
/linux/drivers/infiniband/hw/mana/
H A Dmain.c346 mana_handle_t *gdma_region, unsigned long page_sz) in mana_ib_gd_create_dma_region() argument
366 num_pages_total = ib_umem_num_dma_blocks(umem, page_sz); in mana_ib_gd_create_dma_region()
385 create_req->offset_in_page = ib_umem_dma_offset(umem, page_sz); in mana_ib_gd_create_dma_region()
386 create_req->gdma_page_type = order_base_2(page_sz) - MANA_PAGE_SHIFT; in mana_ib_gd_create_dma_region()
393 page_sz, create_req->offset_in_page); in mana_ib_gd_create_dma_region()
399 rdma_umem_for_each_dma_block(umem, &biter, page_sz) { in mana_ib_gd_create_dma_region()
454 unsigned long page_sz; in mana_ib_create_dma_region() local
456 page_sz = ib_umem_find_best_pgsz(umem, PAGE_SZ_BM, virt); in mana_ib_create_dma_region()
457 if (!page_sz) { in mana_ib_create_dma_region()
462 return mana_ib_gd_create_dma_region(dev, umem, gdma_region, page_sz); in mana_ib_create_dma_region()
[all …]
/linux/tools/testing/selftests/bpf/
H A Duprobe_multi.c100 int page_sz = sysconf(_SC_PAGESIZE); in trigger_uprobe() local
104 addr = (void *)((uintptr_t)&build_id_start & ~(page_sz - 1)); in trigger_uprobe()
110 madvise(addr, page_sz, MADV_POPULATE_READ); in trigger_uprobe()
112 madvise(addr, page_sz, MADV_PAGEOUT); in trigger_uprobe()
/linux/drivers/mtd/devices/
H A Dmchp48l640.c217 size_t page_sz = flash->caps->page_size; in mchp48l640_write() local
224 ws = min((len - wlen), page_sz); in mchp48l640_write()
275 size_t page_sz = flash->caps->page_size; in mchp48l640_read() local
282 ws = min((len - wlen), page_sz); in mchp48l640_read()
/linux/drivers/mtd/nand/raw/
H A Darasan-nand-controller.c175 unsigned int page_sz; member
416 CMD_PAGE_SIZE(anand->page_sz) | in anfc_read_page_hw_ecc()
534 CMD_PAGE_SIZE(anand->page_sz) | in anfc_write_page_hw_ecc()
608 nfc_op->cmd_reg = CMD_PAGE_SIZE(anand->page_sz); in anfc_parse_instructions()
1215 anand->page_sz = 0; in anfc_attach_chip()
1218 anand->page_sz = 5; in anfc_attach_chip()
1221 anand->page_sz = 1; in anfc_attach_chip()
1224 anand->page_sz = 2; in anfc_attach_chip()
1227 anand->page_sz = 3; in anfc_attach_chip()
1230 anand->page_sz = 4; in anfc_attach_chip()
/linux/drivers/net/ethernet/huawei/hinic/
H A Dhinic_hw_wq.c104 void ***shadow_vaddr, size_t page_sz) in queue_alloc_page() argument
109 *vaddr = dma_alloc_coherent(&pdev->dev, page_sz, &dma_addr, in queue_alloc_page()
119 *shadow_vaddr = vzalloc(page_sz); in queue_alloc_page()
126 dma_free_coherent(&pdev->dev, page_sz, *vaddr, dma_addr); in queue_alloc_page()
/linux/drivers/net/ethernet/qlogic/qed/
H A Dqed_cxt.c319 u32 page_sz = p_mgr->clients[ILT_CLI_CDUC].p_size.val; in qed_cxt_set_proto_cid_count() local
321 u32 elems_per_page = ILT_PAGE_IN_BYTES(page_sz) / cxt_size; in qed_cxt_set_proto_cid_count()
1299 u32 page_sz, elems_per_page, block_waste, cxt_size, cdu_params = 0; in qed_cdu_init_common() local
1302 page_sz = p_hwfn->p_cxt_mngr->clients[ILT_CLI_CDUC].p_size.val; in qed_cdu_init_common()
1304 elems_per_page = ILT_PAGE_IN_BYTES(page_sz) / cxt_size; in qed_cdu_init_common()
1305 block_waste = ILT_PAGE_IN_BYTES(page_sz) - elems_per_page * cxt_size; in qed_cdu_init_common()
1313 page_sz = p_hwfn->p_cxt_mngr->clients[ILT_CLI_CDUT].p_size.val; in qed_cdu_init_common()
1315 elems_per_page = ILT_PAGE_IN_BYTES(page_sz) / cxt_size; in qed_cdu_init_common()
1316 block_waste = ILT_PAGE_IN_BYTES(page_sz) - elems_per_page * cxt_size; in qed_cdu_init_common()
1327 elems_per_page = ILT_PAGE_IN_BYTES(page_sz) / cxt_size; in qed_cdu_init_common()
[all …]
/linux/Documentation/arch/arm64/
H A Dmemory-tagging-extension.rst312 unsigned long page_sz = sysconf(_SC_PAGESIZE);
332 a = mmap(0, page_sz, PROT_READ | PROT_WRITE,
343 if (mprotect(a, page_sz, PROT_READ | PROT_WRITE | PROT_MTE)) {
/linux/drivers/net/ethernet/brocade/bna/
H A Dbfi_enet.h161 u16 page_sz; member
H A Dbna_tx_rx.c1298 (bfi_q)->page_sz = htons((u16)(bna_qpt)->page_size);\
/linux/tools/bpf/bpftool/
H A Dgen.c488 long page_sz = sysconf(_SC_PAGE_SIZE); in bpf_map_mmap_sz() local
492 map_sz = roundup(map_sz, page_sz); in bpf_map_mmap_sz()
/linux/tools/lib/bpf/
H A Dlibbpf.c1780 const long page_sz = sysconf(_SC_PAGE_SIZE); in array_map_mmap_sz() local
1784 map_sz = roundup(map_sz, page_sz); in array_map_mmap_sz()
1790 const long page_sz = sysconf(_SC_PAGE_SIZE); in bpf_map_mmap_sz() local
1796 return page_sz * map->def.max_entries; in bpf_map_mmap_sz()
2754 __u32 page_sz = sysconf(_SC_PAGE_SIZE); in adjust_ringbuf_sz() local
2764 if ((sz % page_sz) == 0 && is_pow_of_2(sz / page_sz)) in adjust_ringbuf_sz()
2771 for (mul = 1; mul <= UINT_MAX / page_sz; mul <<= 1) { in adjust_ringbuf_sz()
2772 if (mul * page_sz > sz) in adjust_ringbuf_sz()
2773 return mul * page_sz; in adjust_ringbuf_sz()
2953 const long page_sz = sysconf(_SC_PAGE_SIZE); in init_arena_map_data() local
[all …]