access to file structure for sysfs read/write?
From: Markus Grabner (grabner_at_icg.tu-graz.ac.at)
Date: 12/22/04
- Next message: nick: "Re: which filesystem?"
- Previous message: Måns Rullgård: "Re: which filesystem?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Wed, 22 Dec 2004 22:19:54 +0100
Hi!
Is there a way to access the file structure ("struct file *") in the
read and write method for sysfs access? When creating a sysfs entry with
device_create_file, we have to pass a device_attribute data structure,
which contains a pointer to functions "show" and "store".
The "struct device *" is passed to these functions, so can I derive the
"struct file *" (representing the file the user openend to access the sysfs
file) from the pointer to the device?
Thanks,
Markus
-- Markus Grabner - Computer Graphics and Vision Graz University of Technology, Inffeldgasse 16/II, 8010 Graz, Austria Phone: +43/316/873-5041, Fax: +43/316/873-5050 Email: grabner@icg.tu-graz.ac.at, WWW: http://www.icg.tu-graz.ac.at/~grabner
- Next message: nick: "Re: which filesystem?"
- Previous message: Måns Rullgård: "Re: which filesystem?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|