Re: Mapping memory between kernel and user space

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

 



On Thu, Feb 10, 2011 at 06:45, Sri Ram Vemulpali
<sri.ram.gmu06@xxxxxxxxx> wrote:
> Hi all,
>
>  How do I map some space between kernel and user space. Can anyone
> point me in to right direction. I was trying to map the packets from
> my netfilter function to kernel user space, to avoid over head of
> copying. Thanks in advance.

Not trying to discourage you, but I assume your "filtering" function
will be engaged many many times in the case of rapid traffic...thus,
the buffer might grow rapidly too, right? In that case, are you sure
direct mapping could cope with it? Well unless you're ready to loose
some data .....

Anyway, I think you can do that by reserve the buffer in user space
and the get_user_page() them. As the bridge, a unique device with
ioctl() might do the job.

-- 
regards,

Mulyadi Santosa
Freelance Linux trainer and consultant

blog: the-hydra.blogspot.com
training: mulyaditraining.blogspot.com

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies



[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