diff mbox series

[PULL,072/126] hw/audio/es1370: Replace container_of() by ES1370() QOM cast macro

Message ID 20230227140213.35084-63-philmd@linaro.org
State Accepted
Commit 721d8f254090c8f2b716bf988fcacac16bd9ecf7
Headers show
Series None | expand

Commit Message

Philippe Mathieu-Daudé Feb. 27, 2023, 2:01 p.m. UTC
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20230220131837.26292-4-philmd@linaro.org>
---
 hw/audio/es1370.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/hw/audio/es1370.c b/hw/audio/es1370.c
index ea76c9a734..4f738a0ad8 100644
--- a/hw/audio/es1370.c
+++ b/hw/audio/es1370.c
@@ -843,7 +843,8 @@  static const VMStateDescription vmstate_es1370 = {
 
 static void es1370_on_reset(DeviceState *dev)
 {
-    ES1370State *s = container_of(dev, ES1370State, dev.qdev);
+    ES1370State *s = ES1370(dev);
+
     es1370_reset (s);
 }