Skip to contentSkip to conversation

hw/nmi: Fix the NMI() macro, based on INTERFACE_CHECK()

PATCH Applied Philippe Mathieu-Daudé 3 participants 3 messages Dec 7, 2019 – Dec 13, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 hw/nmi: Fix the NMI() macro, based on INTERFACE_CHECK()

There is no declaration of the 'NMI' type. INTERFACE_CHECK() returns an abstract type (see commit aa1b35b975d8). The abstract type corresponding to the TYPE_NMI interface is 'NMIState'.

Fixes 9cb805fd267
---
 include/hw/nmi.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/hw/nmi.h +1 -1
index a1e128724e..fe37ce3ad8 100644
@@ -31,7 +31,7 @@
 #define NMI_GET_CLASS(obj) \
     OBJECT_GET_CLASS(NMIClass, (obj), TYPE_NMI)
 #define NMI(obj) \
-     INTERFACE_CHECK(NMI, (obj), TYPE_NMI)
+     INTERFACE_CHECK(NMIState, (obj), TYPE_NMI)
 
 typedef struct NMIState NMIState;
 
Signature · 1 line
2.21.0
Reviewed-by on v1 1/1
#1 lore raw
Quoted 7 lines · Philippe Mathieu-Daudé

There is no declaration of the 'NMI' type. INTERFACE_CHECK() returns an abstract type (see commit aa1b35b975d8). The abstract type corresponding to the TYPE_NMI interface is 'NMIState'.

Fixes 9cb805fd267

---

Quoted 17 lines
  include/hw/nmi.h | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
include/hw/nmi.h +1 -1
index a1e128724e..fe37ce3ad8 100644
@@ -31,7 +31,7 @@
  #define NMI_GET_CLASS(obj) \
      OBJECT_GET_CLASS(NMIClass, (obj), TYPE_NMI)
  #define NMI(obj) \
-     INTERFACE_CHECK(NMI, (obj), TYPE_NMI)
+     INTERFACE_CHECK(NMIState, (obj), TYPE_NMI)
 
  typedef struct NMIState NMIState;