]> mj.ucw.cz Git - pciutils.git/commit
Report NUMA node in lspci -v
authorMatthew Wilcox <willy@linux.intel.com>
Wed, 22 Apr 2015 20:27:21 +0000 (16:27 -0400)
committerMartin Mares <mj@ucw.cz>
Mon, 14 Sep 2015 14:43:15 +0000 (16:43 +0200)
commit90ec4a6d0ae85ccd018be3da2d080f602fc56ca7
tree0794a59d692d0442f1bc191eb5f644f1359e200a
parentc8b1fb09a992a76e0d7fd30bf291e95c5033b71d
Report NUMA node in lspci -v

In multi-socket systems, it's useful to see which node a particular
PCI device belongs to.  Linux provides this information through sysfs,
but some users don't like poking through sysfs themselves to find it,
and it's pretty straightforward to report it in lspci.

I should note that when there is no NUMA node for a particular device,
Linux reports -1.  I've chosen to continue that convention in pciutils,
and simply omit the information if the device does not belong to a NUMA
node (eg on single-socket systems, or devices which are not preferentially
attached to a particular node, like Nehalem-based systems).
lib/access.c
lib/pci.h
lib/sysfs.c
lspci.c