Fix this format string warning when defining MSI_DEBUG:

  hw/pci/msi.c:209:28: warning: format specifies type 'char' but the argument 
has type 'unsigned int' [-Wformat]
             offset, nr_vectors, msi64bit, msi_per_vector_mask);
             ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  hw/pci/msi.c:83:61: note: expanded from macro 'MSI_DEV_PRINTF'
      MSI_DPRINTF("%s:%x " fmt, (dev)->name, (dev)->devfn, ## __VA_ARGS__)
      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
  hw/pci/msi.c:78:58: note: expanded from macro 'MSI_DPRINTF'
      fprintf(stderr, "%s:%d " fmt, __func__, __LINE__, ## __VA_ARGS__)
                               ~~~                         ^~~~~~~~~~~

Signed-off-by: Philippe Mathieu-Daudé <phi...@linaro.org>
---
 hw/pci/msi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/pci/msi.c b/hw/pci/msi.c
index 041b0bdbec..5de6df8154 100644
--- a/hw/pci/msi.c
+++ b/hw/pci/msi.c
@@ -204,7 +204,7 @@ int msi_init(struct PCIDevice *dev, uint8_t offset,
     }
 
     MSI_DEV_PRINTF(dev,
-                   "init offset: 0x%"PRIx8" vector: %"PRId8
+                   "init offset: 0x%"PRIx8" vector: %u"
                    " 64bit %d mask %d\n",
                    offset, nr_vectors, msi64bit, msi_per_vector_mask);
 
-- 
2.38.1


Reply via email to