As i understoodÂwhenver a user space program is run it is represented in kernel using VMA which is managed by struct mm_struct
and whenever the program is trying to read/write to a memory location in user space it will be directed to physical address using PAGE TABLE translation done by struct mm_struct(done in kernel space).Am i right?
Â
SupposeÂa simple driver wantsÂtheÂuser to directly access its device memory thenÂwe use mmap.This mmapÂassociates a set of user space virtual address withÂdevice driver memory and it is done by creating kernel page tables for the user space virtual addresses.Is the page table translation done everytime whenever user spaceÂdoes read/write to the device memory??
Â
In .nopage functionÂcall we return the page associatedÂwith the physical address which the user wants to associate with user spaceÂvirtual address.Is the pageÂaddressÂreturned by the nopage function same asÂseen by the user or will it be converted to user space virtual address(range between 0-2 GB)?Â
Â
Thanks for reading.
_______________________________________________ Kernelnewbies mailing list Kernelnewbies@xxxxxxxxxxxxxxxxx http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies