Re: How to read file in kernel module?

From: Fao, Sean
Date: Mon Jan 10 2005 - 11:17:03 EST


linux lover wrote:

I want to read file in kernel module. can
anybody help me by giving code for that?
Also whats suitable way to do that in kernel /proc or
shared memory? what i want is to read and write a user
file frequently.
regards,


Linux Lover,

After reading a number of posts from you in the past couple of months, it's become rather obvious that you're taking a brute force approach to Linux kernel development rather than starting from the beginning and working your way up. Furthermore, some of the questions you ask indicate that you're approaching kernel programming the same way you would program in user space.

Others (myself included) have suggested a couple of books to get you started quickly. It will take some work on your part, however, if you ever want to be a proficient kernel developer. Examples are good to back up theory, but are a horrible way to learn any kind of programming.

Please take us up on our advise to do some reading. I can promiss you that the energy you spend on reading will be time well spent if Linux kernel programming is for you. If you have questions about portions you read in the book, somebody here might be willing to give you a hand.

Please do not take this as an insult. You sound like you have a lot of interest in Kernel development. If that's the case, I'd like to see you turn into a good developer, not just another "so-so" programmer.

Good luck,

--
Sean
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/