lkml.org 
[lkml]   [1999]   [Jul]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Kernel hacking ? - Can this be done?
Stanislav Krasilovskiy had the wisdom to write:
SK> Hi folks,

SK> I have another short question -- is there ANY way to open/read/write
SK> to a file from a kernel routine?

Yes. For example, take a look at kHTTPd (http://www.fenrus.demon.nl),
which does exactly this.

SK> sys_read calls the the filesystem's read function, which uses
SK> copy_to_user (since it assumes it is invoked from user space through
SK> a system call).

See the "set_fs" stuff in kHTTPd.

Greetings,
Arjan van de Ven


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

\
 
 \ /
  Last update: 2005-03-22 13:53    [W:1.157 / U:0.064 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site