From 260bc9d8aa887bdd72d1b2499a9080f75b289cb4 Mon Sep 17 00:00:00 2001 From: Peter Maydell Date: Thu, 18 Feb 2016 14:16:18 +0000 Subject: hw/sd/sd.c: QOMify Turn the SD card into a QOM device. This conversion only changes the device itself; the various functions which are effectively methods on the device are not touched at this point. Signed-off-by: Peter Maydell Reviewed-by: Peter Crosthwaite Reviewed-by: Alistair Francis Message-id: 1455646193-13238-3-git-send-email-peter.maydell@linaro.org --- include/hw/sd/sd.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/hw/sd') diff --git a/include/hw/sd/sd.h b/include/hw/sd/sd.h index 79adb5bb48..404d5896db 100644 --- a/include/hw/sd/sd.h +++ b/include/hw/sd/sd.h @@ -68,6 +68,9 @@ typedef struct { typedef struct SDState SDState; +#define TYPE_SD_CARD "sd-card" +#define SD_CARD(obj) OBJECT_CHECK(SDState, (obj), TYPE_SD_CARD) + SDState *sd_init(BlockBackend *bs, bool is_spi); int sd_do_command(SDState *sd, SDRequest *req, uint8_t *response); -- cgit v1.2.3-55-g7522