Re: Question about security system call in LSM ?

From: Greg KH (greg@private)
Date: Mon Mar 14 2005 - 07:39:12 PST


On Mon, Mar 14, 2005 at 09:10:46AM +0100, Kristian S?rensen wrote:
> On Monday 14 March 2005 03:59, Seth Arnold wrote:
> >   o  making your own /proc/ files (not recommended)
> Why not? It is simple, effective and transparent :-)

And highly discouraged by the kernel community.  The rule is, "No new
/proc files, _unless_ they actually deal with processes."

> You mention that sysfs is the way to go. What is the real difference between 
> sysfs and procfs?

That's a loaded question :)

There's lots of differences, from the programming interface (simpler,
but you have to use kobjects), to the hierarchy rules (must fit into the
proper place within sysfs), to the rules about the data (must have only
one value per file.)

If you want a fs that has no rules, and you can put anything in there
you want, please use debugfs, that is what it was created for.

Good luck,

greg k-h



This archive was generated by hypermail 2.1.3 : Mon Mar 14 2005 - 07:40:44 PST