Honest opinion as a kernel module writer: No, it is not okay.

I believe that kernel modules should take arguments on the insmod
(modprobe, whatever) and/or configuration via /proc (or ioctl()s on /dev,
/udev entries) and/or static values from previous loads of the module left
in kernel storage under a key, but not files.

Reading from a file while in kernel-space is kludgy at best, and quite
error-prone at worst.

Eric Rossman

Linux on 390 Port <[EMAIL PROTECTED]> wrote on 03/10/2004 06:12:29
PM:

> It has always worried me that drivers would read a file.
> Files are "user space" and drivers are supposed to be "kernel space".
> But I have to ask,  are my worries justified?
SNIP
> Perhaps I'm being a purist.
> So I pose the question to the group:
> Is it okay for kernel code to read plain files for config info?
>
> -- R;

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390

Reply via email to