Re: [PATCH] 2.5.17 /dev/ports

Dave Jones (davej@suse.de)
Wed, 22 May 2002 17:19:45 +0200


On Wed, May 22, 2002 at 03:53:24PM +0200, Martin Dalecki wrote:

> > XFree86 uses /proc/cpuinfo, /proc/bus/pci, /proc/mtrr, /proc/fb, /proc/dri
> > and even such goodies as /proc/sys/dev/mac_hid/keyboard_sends_linux_keycodes
> All the cases you encounter above are cases where Linux
> leaks a more palatable interface.

proc/cpuinfo -> /dev/cpu/n/cpuid driver
proc/mtrr -> /dev/cpu/mtrr if devfs is around, but given thats not the
common case, there is no alternative.

> /proc/cpuinfo for one could be replaced by dropping syslog
> messages at a fixed file in /etc/ during boot

userspace really should be using the per-cpu drivers.

> it's static after all!.

In most cses, yes. However this is not going to stay the same forever..
1. hotplug CPUs
2. speedscaling work like cpufreq
3. enabling/disabling of features by poking /dev/cpu/n/msr is possible, and
cpuinfo should reflect that (but currently doesn't)

Dave.

-- 
| Dave Jones.        http://www.codemonkey.org.uk
| SuSE Labs
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/