Skip to content

Commit

Permalink
pci.c: fix compile warning
Browse files Browse the repository at this point in the history
pci/pci.c:1128:15: warning: format '%x' expects argument of type 'unsigned int', but argument 3 has type 'uint32_t' {aka 'long unsigned int'} [-Wformat=]
 1128 |       pciinfo("Limit MME to %x, num to %d\n", mmc, num);
      |               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~  ~~~
      |                                               |
      |                                               uint32_t {aka long unsigned int}
pci/pci.c:1128:30: note: format string is defined here
 1128 |       pciinfo("Limit MME to %x, num to %d\n", mmc, num);
      |                             ~^
      |                              |
      |                              unsigned int
      |                             %lx

Signed-off-by: Yongrong Wang <wangyongrong@xiaomi.com>
  • Loading branch information
wyr-7 authored and lipengfei28 committed Sep 27, 2024
1 parent 18bdb52 commit 818d80d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/pci/pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -1127,7 +1127,7 @@ static int pci_enable_msi(FAR struct pci_device_s *dev, FAR int *irq,
{
mme = mmc;
num = 1 << mme;
pciinfo("Limit MME to %x, num to %d\n", mmc, num);
pciinfo("Limit MME to %"PRIx32", num to %d\n", mmc, num);
}

/* Configure MSI (arch-specific) */
Expand Down

0 comments on commit 818d80d

Please sign in to comment.