943,587 Members | Top Members by Rank

Ad:
Jan 5th, 2006
0

Altering copy_to_user buffer contents

Expand Post »
hi.
i am developing a small module for the linux 2.6.14 kernel.
so far i have been able to create the character devices that will contain any kind of char data i send them.

for example, if i type
echo HELLO WORLD > /dev/vale0
and then
cat < /dev/vale0
then the output will be
HELLO WORLD

but now i would like to alter the result of the last cat comment.
let's say i want to swap the letter O with the letter X so that the output will be:

cat < /dev/vale0

HELLX WXRLD

i suppose the main task is to modify the copy_to_user buffer, but I have absolutely no idea of doing it.
any suggestion will be gladfully accepted.

thanks guys
Similar Threads
Reputation Points: 11
Solved Threads: 0
Light Poster
trashed is offline Offline
30 posts
since Oct 2004

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Linux Kernel and Hardware Setup Forum Timeline: Mozilla and PDA sync
Next Thread in Linux Kernel and Hardware Setup Forum Timeline: cd-rw not showing





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC