Re: mmap non-kmalloc'ed or non-vmalloc'ed buffer?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Rajat,

> I think the following code should work:
> 
> unsigned long pfn = virt_to_phys(foobar_table) >> PAGE_SHIFT;
> unsigned long size = vma->vm_end - vma->vm_start;
> remap_pfn_range(vma, vma->vm_start, pfn, vsize, vma->vm_page_prot);

Yeah, this code didn't work. All I got were the "zero filled" pages. My
user space programm just gave me zeroes when doing printf on the structure.

Best regards,
Daniel

P.s.: The procfs idea came up to my mind, too. Will have a further look
at it.

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux