xref: /openbmc/qemu/include/hw/mem/npcm7xx_mc.h (revision 1351f892467bd8d9655b43b8fbf10a8d08890612)
1*1351f892SHavard Skinnemoen /*
2*1351f892SHavard Skinnemoen  * Nuvoton NPCM7xx Memory Controller stub
3*1351f892SHavard Skinnemoen  *
4*1351f892SHavard Skinnemoen  * Copyright 2020 Google LLC
5*1351f892SHavard Skinnemoen  *
6*1351f892SHavard Skinnemoen  * This program is free software; you can redistribute it and/or modify it
7*1351f892SHavard Skinnemoen  * under the terms of the GNU General Public License as published by the
8*1351f892SHavard Skinnemoen  * Free Software Foundation; either version 2 of the License, or
9*1351f892SHavard Skinnemoen  * (at your option) any later version.
10*1351f892SHavard Skinnemoen  *
11*1351f892SHavard Skinnemoen  * This program is distributed in the hope that it will be useful, but WITHOUT
12*1351f892SHavard Skinnemoen  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13*1351f892SHavard Skinnemoen  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14*1351f892SHavard Skinnemoen  * for more details.
15*1351f892SHavard Skinnemoen  */
16*1351f892SHavard Skinnemoen #ifndef NPCM7XX_MC_H
17*1351f892SHavard Skinnemoen #define NPCM7XX_MC_H
18*1351f892SHavard Skinnemoen 
19*1351f892SHavard Skinnemoen #include "exec/memory.h"
20*1351f892SHavard Skinnemoen #include "hw/sysbus.h"
21*1351f892SHavard Skinnemoen 
22*1351f892SHavard Skinnemoen /**
23*1351f892SHavard Skinnemoen  * struct NPCM7xxMCState - Device state for the memory controller.
24*1351f892SHavard Skinnemoen  * @parent: System bus device.
25*1351f892SHavard Skinnemoen  * @mmio: Memory region through which registers are accessed.
26*1351f892SHavard Skinnemoen  */
27*1351f892SHavard Skinnemoen typedef struct NPCM7xxMCState {
28*1351f892SHavard Skinnemoen     SysBusDevice parent;
29*1351f892SHavard Skinnemoen 
30*1351f892SHavard Skinnemoen     MemoryRegion mmio;
31*1351f892SHavard Skinnemoen } NPCM7xxMCState;
32*1351f892SHavard Skinnemoen 
33*1351f892SHavard Skinnemoen #define TYPE_NPCM7XX_MC "npcm7xx-mc"
34*1351f892SHavard Skinnemoen #define NPCM7XX_MC(obj) OBJECT_CHECK(NPCM7xxMCState, (obj), TYPE_NPCM7XX_MC)
35*1351f892SHavard Skinnemoen 
36*1351f892SHavard Skinnemoen #endif /* NPCM7XX_MC_H */
37