Home
last modified time | relevance | path

Searched refs:vaddr (Results 1 – 25 of 822) sorted by relevance

12345678910>>...33

/linux-6.1.9/arch/m68k/include/asm/
Dbitops.h31 static inline void bset_reg_set_bit(int nr, volatile unsigned long *vaddr) in bset_reg_set_bit() argument
33 char *p = (char *)vaddr + (nr ^ 31) / 8; in bset_reg_set_bit()
41 static inline void bset_mem_set_bit(int nr, volatile unsigned long *vaddr) in bset_mem_set_bit() argument
43 char *p = (char *)vaddr + (nr ^ 31) / 8; in bset_mem_set_bit()
50 static inline void bfset_mem_set_bit(int nr, volatile unsigned long *vaddr) in bfset_mem_set_bit() argument
54 : "d" (nr ^ 31), "o" (*vaddr) in bfset_mem_set_bit()
59 #define set_bit(nr, vaddr) bset_reg_set_bit(nr, vaddr) argument
61 #define set_bit(nr, vaddr) bset_mem_set_bit(nr, vaddr) argument
63 #define set_bit(nr, vaddr) (__builtin_constant_p(nr) ? \ argument
64 bset_mem_set_bit(nr, vaddr) : \
[all …]
/linux-6.1.9/arch/riscv/mm/
Dkasan_init.c36 static void __init kasan_populate_pte(pmd_t *pmd, unsigned long vaddr, unsigned long end) in kasan_populate_pte() argument
46 ptep = base_pte + pte_index(vaddr); in kasan_populate_pte()
53 } while (ptep++, vaddr += PAGE_SIZE, vaddr != end); in kasan_populate_pte()
58 static void __init kasan_populate_pmd(pud_t *pud, unsigned long vaddr, unsigned long end) in kasan_populate_pmd() argument
72 pmdp = base_pmd + pmd_index(vaddr); in kasan_populate_pmd()
75 next = pmd_addr_end(vaddr, end); in kasan_populate_pmd()
77 if (pmd_none(*pmdp) && IS_ALIGNED(vaddr, PMD_SIZE) && (next - vaddr) >= PMD_SIZE) { in kasan_populate_pmd()
85 kasan_populate_pte(pmdp, vaddr, next); in kasan_populate_pmd()
86 } while (pmdp++, vaddr = next, vaddr != end); in kasan_populate_pmd()
98 unsigned long vaddr, unsigned long end, in kasan_populate_pud() argument
[all …]
/linux-6.1.9/arch/parisc/kernel/
Dpci-dma.c77 unsigned long vaddr, in map_pte_uncached() argument
81 unsigned long orig_vaddr = vaddr; in map_pte_uncached()
83 vaddr &= ~PMD_MASK; in map_pte_uncached()
84 end = vaddr + size; in map_pte_uncached()
96 vaddr += PAGE_SIZE; in map_pte_uncached()
100 } while (vaddr < end); in map_pte_uncached()
104 static inline int map_pmd_uncached(pmd_t * pmd, unsigned long vaddr, in map_pmd_uncached() argument
108 unsigned long orig_vaddr = vaddr; in map_pmd_uncached()
110 vaddr &= ~PGDIR_MASK; in map_pmd_uncached()
111 end = vaddr + size; in map_pmd_uncached()
[all …]
/linux-6.1.9/arch/arm/mm/
Dcache-xsc3l2.c88 unsigned long vaddr; in xsc3_l2_inv_range() local
95 vaddr = -1; /* to force the first mapping */ in xsc3_l2_inv_range()
101 vaddr = l2_map_va(start & ~(CACHE_LINE_SIZE - 1), vaddr); in xsc3_l2_inv_range()
102 xsc3_l2_clean_mva(vaddr); in xsc3_l2_inv_range()
103 xsc3_l2_inv_mva(vaddr); in xsc3_l2_inv_range()
111 vaddr = l2_map_va(start, vaddr); in xsc3_l2_inv_range()
112 xsc3_l2_inv_mva(vaddr); in xsc3_l2_inv_range()
120 vaddr = l2_map_va(start, vaddr); in xsc3_l2_inv_range()
121 xsc3_l2_clean_mva(vaddr); in xsc3_l2_inv_range()
122 xsc3_l2_inv_mva(vaddr); in xsc3_l2_inv_range()
[all …]
/linux-6.1.9/arch/x86/mm/
Dmem_encrypt_amd.c157 static void __init __sme_early_map_unmap_mem(void *vaddr, unsigned long size, in __sme_early_map_unmap_mem() argument
160 unsigned long paddr = (unsigned long)vaddr - __PAGE_OFFSET; in __sme_early_map_unmap_mem()
168 __early_make_pgtable((unsigned long)vaddr, pmd); in __sme_early_map_unmap_mem()
170 vaddr += PMD_SIZE; in __sme_early_map_unmap_mem()
291 static void enc_dec_hypercall(unsigned long vaddr, int npages, bool enc) in enc_dec_hypercall() argument
295 unsigned long vaddr_end = vaddr + sz; in enc_dec_hypercall()
297 while (vaddr < vaddr_end) { in enc_dec_hypercall()
302 kpte = lookup_address(vaddr, &level); in enc_dec_hypercall()
317 vaddr = (vaddr & pmask) + psize; in enc_dec_hypercall()
322 static void amd_enc_status_change_prepare(unsigned long vaddr, int npages, bool enc) in amd_enc_status_change_prepare() argument
[all …]
Dinit_32.c110 pmd_t * __init populate_extra_pmd(unsigned long vaddr) in populate_extra_pmd() argument
112 int pgd_idx = pgd_index(vaddr); in populate_extra_pmd()
113 int pmd_idx = pmd_index(vaddr); in populate_extra_pmd()
118 pte_t * __init populate_extra_pte(unsigned long vaddr) in populate_extra_pte() argument
120 int pte_idx = pte_index(vaddr); in populate_extra_pte()
123 pmd = populate_extra_pmd(vaddr); in populate_extra_pte()
135 unsigned long vaddr; in page_table_range_init_count() local
140 vaddr = start; in page_table_range_init_count()
141 pgd_idx = pgd_index(vaddr); in page_table_range_init_count()
142 pmd_idx = pmd_index(vaddr); in page_table_range_init_count()
[all …]
Dkaslr.c67 unsigned long vaddr_start, vaddr; in kernel_randomize_memory() local
74 vaddr = vaddr_start; in kernel_randomize_memory()
128 vaddr += entropy; in kernel_randomize_memory()
129 *kaslr_regions[i].base = vaddr; in kernel_randomize_memory()
135 vaddr += get_padding(&kaslr_regions[i]); in kernel_randomize_memory()
136 vaddr = round_up(vaddr + 1, PUD_SIZE); in kernel_randomize_memory()
145 unsigned long paddr, vaddr; in init_trampoline_kaslr() local
158 vaddr = (unsigned long)__va(paddr); in init_trampoline_kaslr()
159 pgd = pgd_offset_k(vaddr); in init_trampoline_kaslr()
161 p4d = p4d_offset(pgd, vaddr); in init_trampoline_kaslr()
[all …]
Dpgtable_32.c27 void set_pte_vaddr(unsigned long vaddr, pte_t pteval) in set_pte_vaddr() argument
35 pgd = swapper_pg_dir + pgd_index(vaddr); in set_pte_vaddr()
40 p4d = p4d_offset(pgd, vaddr); in set_pte_vaddr()
45 pud = pud_offset(p4d, vaddr); in set_pte_vaddr()
50 pmd = pmd_offset(pud, vaddr); in set_pte_vaddr()
55 pte = pte_offset_kernel(pmd, vaddr); in set_pte_vaddr()
57 set_pte_at(&init_mm, vaddr, pte, pteval); in set_pte_vaddr()
59 pte_clear(&init_mm, vaddr, pte); in set_pte_vaddr()
65 flush_tlb_one_kernel(vaddr); in set_pte_vaddr()
/linux-6.1.9/arch/parisc/mm/
Dfixmap.c15 unsigned long vaddr = __fix_to_virt(idx); in set_fixmap() local
16 pgd_t *pgd = pgd_offset_k(vaddr); in set_fixmap()
17 p4d_t *p4d = p4d_offset(pgd, vaddr); in set_fixmap()
18 pud_t *pud = pud_offset(p4d, vaddr); in set_fixmap()
19 pmd_t *pmd = pmd_offset(pud, vaddr); in set_fixmap()
23 pte = pte_alloc_kernel(pmd, vaddr); in set_fixmap()
25 pte = pte_offset_kernel(pmd, vaddr); in set_fixmap()
26 set_pte_at(&init_mm, vaddr, pte, __mk_pte(phys, PAGE_KERNEL_RWX)); in set_fixmap()
27 flush_tlb_kernel_range(vaddr, vaddr + PAGE_SIZE); in set_fixmap()
32 unsigned long vaddr = __fix_to_virt(idx); in clear_fixmap() local
[all …]
/linux-6.1.9/mm/
Dhighmem.c154 struct page *__kmap_to_page(void *vaddr) in __kmap_to_page() argument
156 unsigned long base = (unsigned long) vaddr & PAGE_MASK; in __kmap_to_page()
158 unsigned long addr = (unsigned long)vaddr; in __kmap_to_page()
181 return virt_to_page(vaddr); in __kmap_to_page()
234 unsigned long vaddr; in map_new_virtual() local
276 vaddr = PKMAP_ADDR(last_pkmap_nr); in map_new_virtual()
277 set_pte_at(&init_mm, vaddr, in map_new_virtual()
281 set_page_address(page, (void *)vaddr); in map_new_virtual()
283 return vaddr; in map_new_virtual()
296 unsigned long vaddr; in kmap_high() local
[all …]
Dioremap.c17 unsigned long offset, vaddr; in ioremap_prot() local
38 vaddr = (unsigned long)area->addr; in ioremap_prot()
41 if (ioremap_page_range(vaddr, vaddr + size, phys_addr, in ioremap_prot()
47 return (void __iomem *)(vaddr + offset); in ioremap_prot()
53 void *vaddr = (void *)((unsigned long)addr & PAGE_MASK); in iounmap() local
55 if (!iounmap_allowed(vaddr)) in iounmap()
58 if (is_vmalloc_addr(vaddr)) in iounmap()
59 vunmap(vaddr); in iounmap()
/linux-6.1.9/arch/m68k/sun3x/
Ddvma.c79 unsigned long vaddr, int len) in dvma_map_cpu() argument
88 vaddr &= PAGE_MASK; in dvma_map_cpu()
90 end = PAGE_ALIGN(vaddr + len); in dvma_map_cpu()
92 pr_debug("dvma: mapping kern %08lx to virt %08lx\n", kaddr, vaddr); in dvma_map_cpu()
93 pgd = pgd_offset_k(vaddr); in dvma_map_cpu()
94 p4d = p4d_offset(pgd, vaddr); in dvma_map_cpu()
95 pud = pud_offset(p4d, vaddr); in dvma_map_cpu()
101 if((pmd = pmd_alloc(&init_mm, pud, vaddr)) == NULL) { in dvma_map_cpu()
106 if((end & PGDIR_MASK) > (vaddr & PGDIR_MASK)) in dvma_map_cpu()
107 end2 = (vaddr + (PGDIR_SIZE-1)) & PGDIR_MASK; in dvma_map_cpu()
[all …]
/linux-6.1.9/drivers/net/ethernet/freescale/fman/
Dfman_muram.c20 unsigned long vaddr) in fman_muram_vbase_to_offset() argument
22 return vaddr - (unsigned long)muram->vbase; in fman_muram_vbase_to_offset()
41 void __iomem *vaddr; in fman_muram_init() local
54 vaddr = ioremap(base, size); in fman_muram_init()
55 if (!vaddr) { in fman_muram_init()
60 ret = gen_pool_add_virt(muram->pool, (unsigned long)vaddr, in fman_muram_init()
64 iounmap(vaddr); in fman_muram_init()
68 memset_io(vaddr, 0, (int)size); in fman_muram_init()
70 muram->vbase = vaddr; in fman_muram_init()
107 unsigned long vaddr; in fman_muram_alloc() local
[all …]
/linux-6.1.9/drivers/media/common/videobuf2/
Dvideobuf2-vmalloc.c26 void *vaddr; member
47 buf->vaddr = vmalloc_user(buf->size); in vb2_vmalloc_alloc()
48 if (!buf->vaddr) { in vb2_vmalloc_alloc()
68 vfree(buf->vaddr); in vb2_vmalloc_put()
74 unsigned long vaddr, unsigned long size) in vb2_vmalloc_get_userptr() argument
86 offset = vaddr & ~PAGE_MASK; in vb2_vmalloc_get_userptr()
88 vec = vb2_create_framevec(vaddr, size); in vb2_vmalloc_get_userptr()
105 buf->vaddr = (__force void *) in vb2_vmalloc_get_userptr()
108 buf->vaddr = vm_map_ram(frame_vector_pages(vec), n_pages, -1); in vb2_vmalloc_get_userptr()
111 if (!buf->vaddr) in vb2_vmalloc_get_userptr()
[all …]
/linux-6.1.9/arch/m68k/sun3/
Ddvma.c23 static unsigned long dvma_page(unsigned long kaddr, unsigned long vaddr) in dvma_page() argument
35 if(ptelist[(vaddr & 0xff000) >> PAGE_SHIFT] != pte) { in dvma_page()
36 sun3_put_pte(vaddr, pte); in dvma_page()
37 ptelist[(vaddr & 0xff000) >> PAGE_SHIFT] = pte; in dvma_page()
40 return (vaddr + (kaddr & ~PAGE_MASK)); in dvma_page()
49 unsigned long vaddr; in dvma_map_iommu() local
51 vaddr = dvma_btov(baddr); in dvma_map_iommu()
53 end = vaddr + len; in dvma_map_iommu()
55 while(vaddr < end) { in dvma_map_iommu()
56 dvma_page(kaddr, vaddr); in dvma_map_iommu()
[all …]
Dmmu_emu.c117 void print_pte_vaddr (unsigned long vaddr) in print_pte_vaddr() argument
119 pr_cont(" vaddr=%lx [%02lx]", vaddr, sun3_get_segmap (vaddr)); in print_pte_vaddr()
120 print_pte (__pte (sun3_get_pte (vaddr))); in print_pte_vaddr()
281 inline void mmu_emu_map_pmeg (int context, int vaddr) in mmu_emu_map_pmeg() argument
287 vaddr &= ~SUN3_PMEG_MASK; in mmu_emu_map_pmeg()
296 curr_pmeg, context, vaddr); in mmu_emu_map_pmeg()
308 if(vaddr >= PAGE_OFFSET) { in mmu_emu_map_pmeg()
314 sun3_put_segmap (vaddr, curr_pmeg); in mmu_emu_map_pmeg()
324 sun3_put_segmap (vaddr, curr_pmeg); in mmu_emu_map_pmeg()
327 pmeg_vaddr[curr_pmeg] = vaddr; in mmu_emu_map_pmeg()
[all …]
/linux-6.1.9/arch/sparc/mm/
Dio-unit.c96 static unsigned long iounit_get_area(struct iounit_struct *iounit, unsigned long vaddr, int size) in iounit_get_area() argument
102 npages = ((vaddr & ~PAGE_MASK) + size + (PAGE_SIZE-1)) >> PAGE_SHIFT; in iounit_get_area()
111 IOD(("iounit_get_area(%08lx,%d[%d])=", vaddr, size, npages)); in iounit_get_area()
126 panic("iounit_get_area: Couldn't find free iopte slots for (%08lx,%d)\n", vaddr, size); in iounit_get_area()
134 iopte = MKIOPTE(__pa(vaddr & PAGE_MASK)); in iounit_get_area()
135 vaddr = IOUNIT_DMA_BASE + (scan << PAGE_SHIFT) + (vaddr & ~PAGE_MASK); in iounit_get_area()
140 IOD(("%08lx\n", vaddr)); in iounit_get_area()
141 return vaddr; in iounit_get_area()
148 void *vaddr = page_address(page) + offset; in iounit_map_page() local
157 ret = iounit_get_area(iounit, (unsigned long)vaddr, len); in iounit_map_page()
[all …]
/linux-6.1.9/arch/sh/mm/
Dkmap.c21 unsigned long vaddr; in kmap_coherent_init() local
24 vaddr = __fix_to_virt(FIX_CMAP_BEGIN); in kmap_coherent_init()
25 kmap_coherent_pte = virt_to_kpte(vaddr); in kmap_coherent_init()
31 unsigned long vaddr; in kmap_coherent() local
42 vaddr = __fix_to_virt(idx); in kmap_coherent()
47 return (void *)vaddr; in kmap_coherent()
53 unsigned long vaddr = (unsigned long)kvaddr & PAGE_MASK; in kunmap_coherent() local
54 enum fixed_addresses idx = __virt_to_fix(vaddr); in kunmap_coherent()
57 __flush_purge_region((void *)vaddr, PAGE_SIZE); in kunmap_coherent()
59 pte_clear(&init_mm, vaddr, kmap_coherent_pte - idx); in kunmap_coherent()
[all …]
/linux-6.1.9/arch/mips/mm/
Dpgtable-32.c53 unsigned long vaddr; in pagetable_init() local
73 vaddr = __fix_to_virt(__end_of_fixed_addresses - 1); in pagetable_init()
74 fixrange_init(vaddr & PMD_MASK, vaddr + FIXADDR_SIZE, pgd_base); in pagetable_init()
80 vaddr = PKMAP_BASE; in pagetable_init()
81 fixrange_init(vaddr & PMD_MASK, vaddr + PAGE_SIZE*LAST_PKMAP, pgd_base); in pagetable_init()
83 pgd = swapper_pg_dir + pgd_index(vaddr); in pagetable_init()
84 p4d = p4d_offset(pgd, vaddr); in pagetable_init()
85 pud = pud_offset(p4d, vaddr); in pagetable_init()
86 pmd = pmd_offset(pud, vaddr); in pagetable_init()
87 pte = pte_offset_kernel(pmd, vaddr); in pagetable_init()
/linux-6.1.9/arch/sparc/include/asm/
Dviking.h214 static inline unsigned long viking_hwprobe(unsigned long vaddr) in viking_hwprobe() argument
218 vaddr &= PAGE_MASK; in viking_hwprobe()
222 : "r" (vaddr | 0x400), "i" (ASI_M_FLUSH_PROBE)); in viking_hwprobe()
229 : "r" (vaddr | 0x200), "i" (ASI_M_FLUSH_PROBE)); in viking_hwprobe()
231 vaddr &= ~PGDIR_MASK; in viking_hwprobe()
232 vaddr >>= PAGE_SHIFT; in viking_hwprobe()
233 return val | (vaddr << 8); in viking_hwprobe()
239 : "r" (vaddr | 0x100), "i" (ASI_M_FLUSH_PROBE)); in viking_hwprobe()
241 vaddr &= ~PMD_MASK; in viking_hwprobe()
242 vaddr >>= PAGE_SHIFT; in viking_hwprobe()
[all …]
/linux-6.1.9/arch/xtensa/mm/
Dcache.c60 unsigned long vaddr) in kmap_invalidate_coherent() argument
62 if (!DCACHE_ALIAS_EQ(page_to_phys(page), vaddr)) { in kmap_invalidate_coherent()
82 unsigned long vaddr, unsigned long *paddr) in coherent_kvaddr() argument
85 return (void *)(base + (vaddr & DCACHE_ALIAS_MASK)); in coherent_kvaddr()
88 void clear_user_highpage(struct page *page, unsigned long vaddr) in clear_user_highpage() argument
91 void *kvaddr = coherent_kvaddr(page, TLBTEMP_BASE_1, vaddr, &paddr); in clear_user_highpage()
94 kmap_invalidate_coherent(page, vaddr); in clear_user_highpage()
102 unsigned long vaddr, struct vm_area_struct *vma) in copy_user_highpage() argument
105 void *dst_vaddr = coherent_kvaddr(dst, TLBTEMP_BASE_1, vaddr, in copy_user_highpage()
107 void *src_vaddr = coherent_kvaddr(src, TLBTEMP_BASE_2, vaddr, in copy_user_highpage()
[all …]
/linux-6.1.9/drivers/misc/sgi-gru/
Dgrufault.c48 struct vm_area_struct *gru_find_vma(unsigned long vaddr) in gru_find_vma() argument
52 vma = vma_lookup(current->mm, vaddr); in gru_find_vma()
66 static struct gru_thread_state *gru_find_lock_gts(unsigned long vaddr) in gru_find_lock_gts() argument
73 vma = gru_find_vma(vaddr); in gru_find_lock_gts()
75 gts = gru_find_thread_state(vma, TSID(vaddr, vma)); in gru_find_lock_gts()
83 static struct gru_thread_state *gru_alloc_locked_gts(unsigned long vaddr) in gru_alloc_locked_gts() argument
90 vma = gru_find_vma(vaddr); in gru_alloc_locked_gts()
94 gts = gru_alloc_thread_state(vma, TSID(vaddr, vma)); in gru_alloc_locked_gts()
178 unsigned long vaddr, int write, in non_atomic_pte_lookup() argument
188 if (get_user_pages(vaddr, 1, write ? FOLL_WRITE : 0, &page, NULL) <= 0) in non_atomic_pte_lookup()
[all …]
/linux-6.1.9/arch/um/kernel/
Dmem.c119 unsigned long vaddr; in fixrange_init() local
121 vaddr = start; in fixrange_init()
122 i = pgd_index(vaddr); in fixrange_init()
123 j = pmd_index(vaddr); in fixrange_init()
126 for ( ; (i < PTRS_PER_PGD) && (vaddr < end); pgd++, i++) { in fixrange_init()
127 p4d = p4d_offset(pgd, vaddr); in fixrange_init()
128 pud = pud_offset(p4d, vaddr); in fixrange_init()
131 pmd = pmd_offset(pud, vaddr); in fixrange_init()
132 for (; (j < PTRS_PER_PMD) && (vaddr < end); pmd++, j++) { in fixrange_init()
134 vaddr += PMD_SIZE; in fixrange_init()
[all …]
/linux-6.1.9/arch/csky/mm/
Dtcm.c29 unsigned long vaddr, paddr; local
42 vaddr = __fix_to_virt(FIX_TCM - i);
45 pte_offset_kernel((pmd_t *)pgd_offset_k(vaddr), vaddr);
49 flush_tlb_one(vaddr);
61 vaddr = __fix_to_virt(FIX_TCM - CONFIG_ITCM_NR_PAGES - i);
64 pte_offset_kernel((pmd_t *) pgd_offset_k(vaddr), vaddr);
68 flush_tlb_one(vaddr);
111 unsigned long vaddr; local
116 vaddr = gen_pool_alloc(tcm_pool, len);
117 if (!vaddr)
[all …]
/linux-6.1.9/arch/x86/include/asm/
Dsev.h159 static inline int rmpadjust(unsigned long vaddr, bool rmp_psize, unsigned long attrs) in rmpadjust() argument
166 : "a"(vaddr), "c"(rmp_psize), "d"(attrs) in rmpadjust()
171 static inline int pvalidate(unsigned long vaddr, bool rmp_psize, bool validate) in pvalidate() argument
180 : "a"(vaddr), "c"(rmp_psize), "d"(validate) in pvalidate()
189 void __init early_snp_set_memory_private(unsigned long vaddr, unsigned long paddr,
191 void __init early_snp_set_memory_shared(unsigned long vaddr, unsigned long paddr,
194 void snp_set_memory_shared(unsigned long vaddr, unsigned int npages);
195 void snp_set_memory_private(unsigned long vaddr, unsigned int npages);
206 static inline int pvalidate(unsigned long vaddr, bool rmp_psize, bool validate) { return 0; } in pvalidate() argument
207 static inline int rmpadjust(unsigned long vaddr, bool rmp_psize, unsigned long attrs) { return 0; } in rmpadjust() argument
[all …]

12345678910>>...33