Signed-off-by: Imre Deak <imre.deak@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
*/
#include <unistd.h>
+#include <assert.h>
#include "intel_gpu_tools.h"
int main(int argc, char** argv)
struct pci_device *pci_dev;
uint32_t devid;
int mmio_bar;
+ int ret;
pci_dev = intel_get_pci_device();
devid = pci_dev->device_id;
else
mmio_bar = 0;
- write(1, mmio, pci_dev->regions[mmio_bar].size);
+ ret = write(1, mmio, pci_dev->regions[mmio_bar].size);
+ assert(ret > 0);
return 0;
}