My question is where to allocate the bit vector.
1. If I allocate the bit vector in user-level, then everytime the kernel wants to read the bit vector, I has to do a copy_from_user(). I tried this solution, this incurs a lot of overhead and also crash the os. Since the copy_from_user() needs to look up the virtual address which corresponds to the starting address of bit-vector, it will cause paging in the middle of scheduling. Is there any other way that the kernel can directly access user-level space without doing copying and address translation?
2. If I allocate the bit vector directly in the kernel space. How can I do this? Is it possible to create an extra system call that allows user-level program to allocate a kernel buffer?
Could anyone help me out on this? Thanks!
_______________________________________________ Fedora-kernel-list mailing list Fedora-kernel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/fedora-kernel-list