summary refs log tree commit diff stats
path: root/hw/usb/hcd-ehci-pci.c
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@linaro.org>2024-02-13 05:38:59 +0100
committerMichael Tokarev <mjt@tls.msk.ru>2024-02-20 20:34:21 +0300
commit1c83f366f909198a7bb50db2b40b3486ac977da2 (patch)
tree5ca54f0ea40deea9922fde0a171e445bbcceadaf /hw/usb/hcd-ehci-pci.c
parentfe693e32c8136bba792a355617d2b0f5d1914721 (diff)
downloadfocaccia-qemu-1c83f366f909198a7bb50db2b40b3486ac977da2.tar.gz
focaccia-qemu-1c83f366f909198a7bb50db2b40b3486ac977da2.zip
hw/usb/ehci: Rename NB_PORTS -> EHCI_PORTS
Rename NB_PORTS as EHCI_PORTS to avoid definition clash
with UHCI equivalent:

  hw/usb/hcd-ehci.h:40:9: error: 'NB_PORTS' macro redefined [-Werror,-Wmacro-redefined]
  #define NB_PORTS         6        /* Max. Number of downstream ports */
          ^
  hw/usb/hcd-uhci.h:38:9: note: previous definition is here
  #define NB_PORTS 2
          ^

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Diffstat (limited to 'hw/usb/hcd-ehci-pci.c')
-rw-r--r--hw/usb/hcd-ehci-pci.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/usb/hcd-ehci-pci.c b/hw/usb/hcd-ehci-pci.c
index 0b26db74d8..3ff54edf62 100644
--- a/hw/usb/hcd-ehci-pci.c
+++ b/hw/usb/hcd-ehci-pci.c
@@ -83,7 +83,7 @@ static void usb_ehci_pci_init(Object *obj)
     s->capsbase = 0x00;
     s->opregbase = 0x20;
     s->portscbase = 0x44;
-    s->portnr = NB_PORTS;
+    s->portnr = EHCI_PORTS;
 
     if (!dc->hotpluggable) {
         s->companion_enable = true;