quick_dump: Connect libpciaccess and other utils

Make a register access library with sample to do register reads

Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
This commit is contained in:
Ben Widawsky
2013-02-01 20:13:25 -08:00
parent 6437eed930
commit beb5de858d
5 changed files with 58 additions and 10 deletions
+7
View File
@@ -1,3 +1,4 @@
#include <pciaccess.h>
#include "intel_chipset.h"
int is_sandybridge(unsigned short pciid)
@@ -14,3 +15,9 @@ int is_valleyview(unsigned short pciid)
{
return IS_VALLEYVIEW(pciid);
}
/* Simple helper because I couldn't make this work in the script */
unsigned short pcidev_to_devid(struct pci_device *pdev)
{
return pdev->device_id;
}