1 /* 2 * SPDX-License-Identifier: GPL-2.0-or-later 3 * Copyright (C) 2023 IBM Corp. 4 * 5 * IBM Local bus and connected device structures. 6 */ 7 #ifndef FSI_LBUS_H 8 #define FSI_LBUS_H 9 10 #include "exec/memory.h" 11 #include "hw/qdev-core.h" 12 13 #define TYPE_FSI_LBUS_DEVICE "fsi.lbus.device" 14 OBJECT_DECLARE_TYPE(FSILBusDevice, FSILBusDeviceClass, FSI_LBUS_DEVICE) 15 16 #define FSI_LBUS_MEM_REGION_SIZE (2 * 1024 * 1024) 17 #define FSI_LBUSDEV_IOMEM_START 0xc00 /* 3K used by CFAM config etc */ 18 19 typedef struct FSILBusDevice { 20 DeviceState parent; 21 22 MemoryRegion iomem; 23 } FSILBusDevice; 24 25 typedef struct FSILBusDeviceClass { 26 DeviceClass parent; 27 28 uint32_t config; 29 } FSILBusDeviceClass; 30 31 #define TYPE_FSI_LBUS "fsi.lbus" 32 OBJECT_DECLARE_SIMPLE_TYPE(FSILBus, FSI_LBUS) 33 34 typedef struct FSILBus { 35 BusState bus; 36 37 MemoryRegion mr; 38 } FSILBus; 39 40 #endif /* FSI_LBUS_H */ 41