Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I want to make a common memory space between user and Kernel. I need to send each packet to a particular place from my network driver to a memory. And One of the application will take that and will do some process.Is there any way to share a common space between user and kernel. Thanks in advance for your help
You should do this using one of the standard mechanisms. Iptables module is one solution, you can also think about extra /proc or /dev file by your driver, depending on what you want to do with the packet after it is processed.
My suggestion is, using shared memory you can do this. Cretae an shared memory device in /dev, send ur data from ur driver to that share memory. Ur Application can access those spaces as a device, like "/dev/shm".
Sure. I have implemented this concept in RTLinux and Linux.
What type of help you want.
The ceoncept is simple,Create a shared memory device from kernel. Write your data here.Read the same data by application program.
Any other info you need.
Thank you very much Prakash.I understood your thought.But how to access the device from the Kernel(i mean to say from my driver). From the application you can access using open the dev,read and write . But how it is possible from the driver .
Then my logic is not suitable for you.I used IPC to shared the data b/w the processes.Ur case is diffi. You just ignore the above and go to the following link.Hope it will helpful for you.
I dont have more idea abt it, but APMK, we can share the data from kernel to user land by the following ways, relayfs, procfs, debugfs, ioctls, mmap....