]> git.proxmox.com Git - mirror_qemu.git/blob - include/hw/sd/aspeed_sdhci.h
Move QOM typedefs and add missing includes
[mirror_qemu.git] / include / hw / sd / aspeed_sdhci.h
1 /*
2 * Aspeed SD Host Controller
3 * Eddie James <eajames@linux.ibm.com>
4 *
5 * Copyright (C) 2019 IBM Corp
6 * SPDX-License-Identifer: GPL-2.0-or-later
7 */
8
9 #ifndef ASPEED_SDHCI_H
10 #define ASPEED_SDHCI_H
11
12 #include "hw/sd/sdhci.h"
13 #include "qom/object.h"
14
15 #define TYPE_ASPEED_SDHCI "aspeed.sdhci"
16 typedef struct AspeedSDHCIState AspeedSDHCIState;
17 #define ASPEED_SDHCI(obj) OBJECT_CHECK(AspeedSDHCIState, (obj), \
18 TYPE_ASPEED_SDHCI)
19
20 #define ASPEED_SDHCI_CAPABILITIES 0x01E80080
21 #define ASPEED_SDHCI_NUM_SLOTS 2
22 #define ASPEED_SDHCI_NUM_REGS (ASPEED_SDHCI_REG_SIZE / sizeof(uint32_t))
23 #define ASPEED_SDHCI_REG_SIZE 0x100
24
25 struct AspeedSDHCIState {
26 SysBusDevice parent;
27
28 SDHCIState slots[ASPEED_SDHCI_NUM_SLOTS];
29 uint8_t num_slots;
30
31 MemoryRegion iomem;
32 qemu_irq irq;
33
34 uint32_t regs[ASPEED_SDHCI_NUM_REGS];
35 };
36
37 #endif /* ASPEED_SDHCI_H */