Getting virtual address

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

 



I am writing sendpage (this is called when sendfile system call is used) function for my protocol. User application calls with socket and filename, kernel maps file and pass struct page * to sendpage function.

I use following expression to get virtual address and copy data

virtual_address = phys_to_virt(page_to_pfn(page) << PAGE_SHIFT);

This works fine on Pentium III machine with 515324 KB memory, but when I run same code on Xeon with 2074604 KB memory, I get

Unable to handle kernel paging request at virtual address 3ab6c000

Is this because this address (struct page *) is not mapped ? how do I check in my code whether it is mapped or not, since it is mapped on Pentium.

Thanks for help.
_________________________________________________________________
Peek-a-boo FREE Tricks & Treats for You!
http://www.reallivemoms.com?ocid=TXT_TAGHM&loc=us
--
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