]> git.ipfire.org Git - thirdparty/pciutils.git/commit
Fix device_class calculatoin for non-root FreeBSD users
authorOleksandr Tymoshenko <gonzo@bluezbox.com>
Sun, 19 Aug 2018 19:48:07 +0000 (12:48 -0700)
committerMartin Mares <mj@ucw.cz>
Tue, 16 Oct 2018 16:23:47 +0000 (18:23 +0200)
commit0f3898a44ad32bec37543a03ed8021f5c880e3c1
treeb86dd44bb1f9f4ba4fd46102acd2222d7c5ee35d
parent888ddf0e53f304d61326665bca3294f38129d7c9
Fix device_class calculatoin for non-root FreeBSD users

libpci uses PCIOCGETCONF for non-privileged access to /dev/pci
and calculates device_class value based on pc_class/pc_subclass
fields expecting the former to be higher 8 bits of the target value.
0f3d0ca73ecedaba180bf4607bb57fb8abe6d405 errorneously swapped
order of class/subclass during calculations.

Signed-off-by: Oleksandr Tymoshenko <gonzo@bluezbox.com>
lib/fbsd-device.c