2019-07-01 18:26:18 +02:00
|
|
|
/*
|
|
|
|
* ASPEED XDMA Controller
|
|
|
|
* Eddie James <eajames@linux.ibm.com>
|
|
|
|
*
|
|
|
|
* Copyright (C) 2019 IBM Corp.
|
|
|
|
* SPDX-License-Identifer: GPL-2.0-or-later
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef ASPEED_XDMA_H
|
|
|
|
#define ASPEED_XDMA_H
|
|
|
|
|
|
|
|
#include "hw/sysbus.h"
|
2020-09-03 22:43:22 +02:00
|
|
|
#include "qom/object.h"
|
2019-07-01 18:26:18 +02:00
|
|
|
|
|
|
|
#define TYPE_ASPEED_XDMA "aspeed.xdma"
|
2020-09-16 20:25:19 +02:00
|
|
|
OBJECT_DECLARE_SIMPLE_TYPE(AspeedXDMAState, ASPEED_XDMA)
|
2019-07-01 18:26:18 +02:00
|
|
|
|
|
|
|
#define ASPEED_XDMA_NUM_REGS (ASPEED_XDMA_REG_SIZE / sizeof(uint32_t))
|
|
|
|
#define ASPEED_XDMA_REG_SIZE 0x7C
|
|
|
|
|
2020-09-03 22:43:22 +02:00
|
|
|
struct AspeedXDMAState {
|
2019-07-01 18:26:18 +02:00
|
|
|
SysBusDevice parent;
|
|
|
|
|
|
|
|
MemoryRegion iomem;
|
|
|
|
qemu_irq irq;
|
|
|
|
|
|
|
|
char bmc_cmdq_readp_set;
|
|
|
|
uint32_t regs[ASPEED_XDMA_NUM_REGS];
|
2020-09-03 22:43:22 +02:00
|
|
|
};
|
2019-07-01 18:26:18 +02:00
|
|
|
|
|
|
|
#endif /* ASPEED_XDMA_H */
|