setpci.c (ex_op): The demo mode was never documented to disable reads,
only writes, so conform with the definition.
git-archimport-id: mj@ucw.cz--public/pciutils--main--2.2--patch-12
* setpci.c (main): Better error messages.
+ * setpci.c (ex_op): The demo mode was never documented to disable reads,
+ only writes, so conform with the definition.
+
* pciutils.h, common.c, setpci.c: Introduced a NONRET macro encapsulating
the GCC specific __attribute__((noreturn)) and killed the hack with
redefining __attribute__ on non-GCC compilers.
{
if (verbose)
printf(" = ");
- if (!demo_mode)
+ switch (width)
{
- switch (width)
- {
- case 1:
- x = pci_read_byte(dev, addr);
- break;
- case 2:
- x = pci_read_word(dev, addr);
- break;
- default:
- x = pci_read_long(dev, addr);
- break;
- }
- printf(formats[width], x);
+ case 1:
+ x = pci_read_byte(dev, addr);
+ break;
+ case 2:
+ x = pci_read_word(dev, addr);
+ break;
+ default:
+ x = pci_read_long(dev, addr);
+ break;
}
- else
- putchar('?');
+ printf(formats[width], x);
putchar('\n');
}
}