nubus-device: add romfile property for loading declaration ROMs

The declaration ROM is located at the top-most address of the standard slot
space.

Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Laurent Vivier <laurent@vivier.eu>
Message-Id: <20210924073808.1041-12-mark.cave-ayland@ilande.co.uk>
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
This commit is contained in:
Mark Cave-Ayland 2021-09-24 08:37:59 +01:00 committed by Laurent Vivier
parent 2469dc1dda
commit 3616f424c9
2 changed files with 49 additions and 1 deletions

View file

@ -12,6 +12,7 @@
#include "hw/qdev-properties.h"
#include "exec/address-spaces.h"
#include "qom/object.h"
#include "qemu/units.h"
#define NUBUS_SUPER_SLOT_SIZE 0x10000000U
#define NUBUS_SUPER_SLOT_NB 0xe
@ -38,12 +39,17 @@ struct NubusBus {
uint16_t slot_available_mask;
};
#define NUBUS_DECL_ROM_MAX_SIZE (128 * KiB)
struct NubusDevice {
DeviceState qdev;
int32_t slot;
MemoryRegion super_slot_mem;
MemoryRegion slot_mem;
char *romfile;
MemoryRegion decl_rom;
};
#endif