Revision a8170e5e hw/isa_mmio.c
b/hw/isa_mmio.c | ||
---|---|---|
26 | 26 |
#include "isa.h" |
27 | 27 |
#include "exec-memory.h" |
28 | 28 |
|
29 |
static void isa_mmio_writeb (void *opaque, target_phys_addr_t addr,
|
|
29 |
static void isa_mmio_writeb (void *opaque, hwaddr addr,
|
|
30 | 30 |
uint32_t val) |
31 | 31 |
{ |
32 | 32 |
cpu_outb(addr & IOPORTS_MASK, val); |
33 | 33 |
} |
34 | 34 |
|
35 |
static void isa_mmio_writew(void *opaque, target_phys_addr_t addr,
|
|
35 |
static void isa_mmio_writew(void *opaque, hwaddr addr,
|
|
36 | 36 |
uint32_t val) |
37 | 37 |
{ |
38 | 38 |
cpu_outw(addr & IOPORTS_MASK, val); |
39 | 39 |
} |
40 | 40 |
|
41 |
static void isa_mmio_writel(void *opaque, target_phys_addr_t addr,
|
|
41 |
static void isa_mmio_writel(void *opaque, hwaddr addr,
|
|
42 | 42 |
uint32_t val) |
43 | 43 |
{ |
44 | 44 |
cpu_outl(addr & IOPORTS_MASK, val); |
45 | 45 |
} |
46 | 46 |
|
47 |
static uint32_t isa_mmio_readb (void *opaque, target_phys_addr_t addr)
|
|
47 |
static uint32_t isa_mmio_readb (void *opaque, hwaddr addr)
|
|
48 | 48 |
{ |
49 | 49 |
return cpu_inb(addr & IOPORTS_MASK); |
50 | 50 |
} |
51 | 51 |
|
52 |
static uint32_t isa_mmio_readw(void *opaque, target_phys_addr_t addr)
|
|
52 |
static uint32_t isa_mmio_readw(void *opaque, hwaddr addr)
|
|
53 | 53 |
{ |
54 | 54 |
return cpu_inw(addr & IOPORTS_MASK); |
55 | 55 |
} |
56 | 56 |
|
57 |
static uint32_t isa_mmio_readl(void *opaque, target_phys_addr_t addr)
|
|
57 |
static uint32_t isa_mmio_readl(void *opaque, hwaddr addr)
|
|
58 | 58 |
{ |
59 | 59 |
return cpu_inl(addr & IOPORTS_MASK); |
60 | 60 |
} |
... | ... | |
67 | 67 |
.endianness = DEVICE_LITTLE_ENDIAN, |
68 | 68 |
}; |
69 | 69 |
|
70 |
void isa_mmio_setup(MemoryRegion *mr, target_phys_addr_t size)
|
|
70 |
void isa_mmio_setup(MemoryRegion *mr, hwaddr size)
|
|
71 | 71 |
{ |
72 | 72 |
memory_region_init_io(mr, &isa_mmio_ops, NULL, "isa-mmio", size); |
73 | 73 |
} |
74 | 74 |
|
75 |
void isa_mmio_init(target_phys_addr_t base, target_phys_addr_t size)
|
|
75 |
void isa_mmio_init(hwaddr base, hwaddr size)
|
|
76 | 76 |
{ |
77 | 77 |
MemoryRegion *mr = g_malloc(sizeof(*mr)); |
78 | 78 |
|
Also available in: Unified diff