make /dev/pci really readable
M. Warner Losh
imp at bsdimp.com
Mon Jun 16 22:13:37 PDT 2003
In message: <20030617050905.GE73854 at funkthat.com>
John-Mark Gurney <gurney_j at efn.org> writes:
: M. Warner Losh wrote this message on Mon, Jun 16, 2003 at 22:52 -0600:
: > In message: <20030616074122.GF73854 at funkthat.com>
: > John-Mark Gurney <gurney_j at efn.org> writes:
: > : Does anyone have an objection to making /dev/pci really honor the
: > : permissions, and giving normal users (or just group wheel) premission
: > : to run pciconf -l. Right now the code requires the write bit set for
: > : any operation.
: > Yes. That's too dangerous and will panic a machine.
: I'm not talking about -r... and anyways, I have fixed part of the
: problem with unaligned reads/writes which has been posted to this
: thread already....
Saw that. Still not sure it is a good idea, but only if the code is
: > You can get the same information that pciconf -l does by going through
: > the alternative interface of devinfo.
: So, I hear you proposing to remove pciconf and the /dev/pci interface?
Not really. I'm saying that we should beef up devinfo interface so
that it can get PNP information from more databases that just the PCI
one. pciconf is the wrong place for -v to be placed. But it was the
only place to place it when it was written. Now that other busses
have begun to implement pnp info to userland, we should look at a good
way to deal.
Also, pciconf -r/-w provides inforamtion that devinfo cannot provide.
And they serve a useful purpose for low level debugging.
More information about the freebsd-arch