From 0bcea3f74b04cdc23ecd6822bea7e46a55eb4be7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Date: Wed, 3 Jul 2024 11:12:00 +0200 Subject: hw/sd/sdcard: Extract TYPE_SDMMC_COMMON from TYPE_SD_CARD MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In order to keep eMMC model simpler to maintain, extract common properties and the common code from class_init to the (internal) TYPE_SDMMC_COMMON. Update the corresponding QOM cast macros. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Cédric Le Goater Tested-by: Andrew Jeffery Tested-by: Cédric Le Goater Message-Id: <20240703134356.85972-6-philmd@linaro.org> --- hw/sd/sdmmc-internal.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'hw/sd/sdmmc-internal.h') diff --git a/hw/sd/sdmmc-internal.h b/hw/sd/sdmmc-internal.h index cc0b69e..91eb5b6 100644 --- a/hw/sd/sdmmc-internal.h +++ b/hw/sd/sdmmc-internal.h @@ -11,6 +11,9 @@ #ifndef SDMMC_INTERNAL_H #define SDMMC_INTERNAL_H +#define TYPE_SDMMC_COMMON "sdmmc-common" +DECLARE_OBJ_CHECKERS(SDState, SDCardClass, SDMMC_COMMON, TYPE_SDMMC_COMMON) + /* * EXT_CSD Modes segment * -- cgit v1.1