[prev in list] [next in list] [prev in thread] [next in thread]
List: freebsd-hackers
Subject: Re: Access pci devices' serial numbers programmatically
From: John Baldwin <jhb () freebsd ! org>
Date: 2014-01-20 21:02:23
Message-ID: 37639448.Wf1F1apyVZ () pippin ! baldwin ! cx
[Download RAW message or body]
On Tuesday 14 January 2014 22:05:59 Nomad Esst wrote:
> Yes I'm trying to get these information from user-land. Any ideas now?
I just committed a change to HEAD to add a new flag to pciconf to dump VPD
data. If you just need it in a shell script then 'pciconf -lV <device>' might
be sufficient for you. If you want it programmatically, you can use the new
ioctl I added to retrieve it from the kernel.
If you need to do this on an older OS version where you can't backport my
change (or upgrade to a version with this change), then you can use direct
config register access to find the VPD capability and read the data directly
using the VPD registers.
--
John Baldwin
_______________________________________________
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic