public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Re: Device Registry (DevReg) Patch 0.2.0
@ 2001-04-25 17:10 Dan Kegel
  2001-04-25 18:09 ` H. Peter Anvin
  2001-04-25 18:55 ` /proc format (was Device Registry (DevReg) Patch 0.2.0) Tim Jansen
  0 siblings, 2 replies; 24+ messages in thread
From: Dan Kegel @ 2001-04-25 17:10 UTC (permalink / raw)
  To: tim, linux-kernel@vger.kernel.org

Tim Jansen wrote:
> On Tuesday 24 April 2001 18:39, Martin Dalecki wrote: 
> >> Are there alternatives to get complex and extendable information out to 
> >> user space? 
> > Yes filesystem structures. 
> 
> How exactly can this work? A single value per file is not very helpful if you 
> have a thousand values. You could cluster them (for example one level in the 
> XML hierarchy == one file), but this will soon get very complicated. Its much 
> more work to implement in the kernel, its painful in user-space and you cant 
> just use a text editor to look at it (because you always have to look at 10 
> files per device). 

The command
  more foo/* foo/*/* 
will display the values in the foo subtree nicely, I think.

Think of the /proc tree as the XML parse tree already exploded for you.

The only problem with /proc as it stands is that there is no formal
syntax for its entries.  Some of them are hard to parse.

Before we add a new /proc entry that generates XML which summarizes
the rest of /proc, it might make sense to standardize /proc entries
and write a regression test to verify they are formatted correctly.
It would then be trivial to write a /proc to XML converter which
ran solely in userspace.

See 
http://www.uwsg.indiana.edu/hypermail/linux/kernel/0101.0/0506.html
and
http://marc.theaimsgroup.com/?l=linux-kernel&s=%2Fproc+xml

for prior discussion on the matter.

I don't want to dismiss the reasons you want to use XML for this,
but tread carefully, lest you duplicate lots of code and introduce
cruft.  Better to factor the XML part out to a userspace library...

- Dan

^ permalink raw reply	[flat|nested] 24+ messages in thread
* Device Registry (DevReg) Patch 0.2.0
@ 2001-04-24  1:08 Tim Jansen
  2001-04-24  9:40 ` Martin Dalecki
  0 siblings, 1 reply; 24+ messages in thread
From: Tim Jansen @ 2001-04-24  1:08 UTC (permalink / raw)
  To: linux-kernel; +Cc: linux-hotplug-devel

The Linux Device Registry (devreg) is a kernel patch that adds a device 
database in XML format to the /proc filesystem. It collects all information 
about the system's physical devices, creates persistent device ids and 
provides them in the file /proc/devreg.

Devreg has three purposes:
- collect all configuration data from drivers so the user can browse his 
hardware configuration. 
-allow an application to display all devices that provide a certain interface 
(for example all mice) so the user can chose one. 
-allow an application to find the device that the user has selected after a 
reboot or a hotplug action: the device files in /dev do not offer stable 
names, they depend on the order in that the devices have been plugged in or 
powered on. 

Changes since last release (0.1.1):
- converted file format to XML
- bus-specific information from pci and usb added
- fixed locking

The patch (for 2.4.3) can be found at 
http://www.tjansen.de/devreg/devreg-2.4.3-0.2.0.diff.gz
To test it, apply the patch, select CONFIG_DEVFS_FS and CONFIG_DEVREG and 
compile. Note that the patch will break binary drivers.

Supported hardware in version 0.2.0: PCI subsystem, USB subsystem, most PCI 
sound cards, USB HID devices, USB hubs, USB printers

Other information and a user-space library can be found at 
http://www.tjansen.de/devreg

^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2001-04-26 14:09 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-04-25 17:10 Device Registry (DevReg) Patch 0.2.0 Dan Kegel
2001-04-25 18:09 ` H. Peter Anvin
2001-04-25 18:55 ` /proc format (was Device Registry (DevReg) Patch 0.2.0) Tim Jansen
2001-04-25 19:19   ` Dan Kegel
2001-04-25 23:09     ` Tim Jansen
2001-04-25 19:37   ` Jesse Pollard
2001-04-25 20:08     ` Dan Kegel
2001-04-25 20:40     ` Tim Jansen
2001-04-25 21:16       ` Jesse Pollard
2001-04-25 21:50         ` J . A . Magallon
2001-04-25 21:58           ` Doug McNaught
2001-04-25 22:03             ` J . A . Magallon
2001-04-25 22:24               ` Marko Kreen
2001-04-25 22:42               ` Alexander Viro
2001-04-25 22:24             ` Mark Hahn
2001-04-26 14:06               ` Tim Jansen
2001-04-25 22:46         ` Tim Jansen
  -- strict thread matches above, loose matches on Subject: below --
2001-04-24  1:08 Device Registry (DevReg) Patch 0.2.0 Tim Jansen
2001-04-24  9:40 ` Martin Dalecki
2001-04-24 11:44   ` Tim Jansen
2001-04-24 16:39     ` Martin Dalecki
2001-04-24 18:27       ` Tim Jansen
2001-04-24 16:43     ` mirabilos
2001-04-24 18:57       ` Tim Jansen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox