root / hw / ppc_mac.h @ 7bfe5777
History | View | Annotate | Download (2.5 kB)
1 | 3cbee15b | j_mayer | /*
|
---|---|---|---|
2 | 3cbee15b | j_mayer | * QEMU PowerMac emulation shared definitions and prototypes
|
3 | 3cbee15b | j_mayer | *
|
4 | 3cbee15b | j_mayer | * Copyright (c) 2004-2007 Fabrice Bellard
|
5 | 3cbee15b | j_mayer | * Copyright (c) 2007 Jocelyn Mayer
|
6 | 3cbee15b | j_mayer | *
|
7 | 3cbee15b | j_mayer | * Permission is hereby granted, free of charge, to any person obtaining a copy
|
8 | 3cbee15b | j_mayer | * of this software and associated documentation files (the "Software"), to deal
|
9 | 3cbee15b | j_mayer | * in the Software without restriction, including without limitation the rights
|
10 | 3cbee15b | j_mayer | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
11 | 3cbee15b | j_mayer | * copies of the Software, and to permit persons to whom the Software is
|
12 | 3cbee15b | j_mayer | * furnished to do so, subject to the following conditions:
|
13 | 3cbee15b | j_mayer | *
|
14 | 3cbee15b | j_mayer | * The above copyright notice and this permission notice shall be included in
|
15 | 3cbee15b | j_mayer | * all copies or substantial portions of the Software.
|
16 | 3cbee15b | j_mayer | *
|
17 | 3cbee15b | j_mayer | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
18 | 3cbee15b | j_mayer | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
19 | 3cbee15b | j_mayer | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
20 | 3cbee15b | j_mayer | * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
21 | 3cbee15b | j_mayer | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
22 | 3cbee15b | j_mayer | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
23 | 3cbee15b | j_mayer | * THE SOFTWARE.
|
24 | 3cbee15b | j_mayer | */
|
25 | 3cbee15b | j_mayer | #if !defined(__PPC_MAC_H__)
|
26 | 3cbee15b | j_mayer | #define __PPC_MAC_H__
|
27 | 3cbee15b | j_mayer | |
28 | 3cbee15b | j_mayer | /* SMP is not enabled, for now */
|
29 | 3cbee15b | j_mayer | #define MAX_CPUS 1 |
30 | 3cbee15b | j_mayer | |
31 | 3cbee15b | j_mayer | #define BIOS_FILENAME "ppc_rom.bin" |
32 | 3cbee15b | j_mayer | #define VGABIOS_FILENAME "video.x" |
33 | 3cbee15b | j_mayer | #define NVRAM_SIZE 0x2000 |
34 | 3cbee15b | j_mayer | |
35 | 3cbee15b | j_mayer | #define KERNEL_LOAD_ADDR 0x01000000 |
36 | 3cbee15b | j_mayer | #define INITRD_LOAD_ADDR 0x01800000 |
37 | 3cbee15b | j_mayer | |
38 | 3cbee15b | j_mayer | /* DBDMA */
|
39 | 3cbee15b | j_mayer | void dbdma_init (int *dbdma_mem_index); |
40 | 3cbee15b | j_mayer | |
41 | 3cbee15b | j_mayer | /* Cuda */
|
42 | 3cbee15b | j_mayer | void cuda_init (int *cuda_mem_index, qemu_irq irq); |
43 | 3cbee15b | j_mayer | |
44 | 3cbee15b | j_mayer | /* MacIO */
|
45 | 3cbee15b | j_mayer | void macio_init (PCIBus *bus, int device_id, int is_oldworld, int pic_mem_index, |
46 | 3cbee15b | j_mayer | int dbdma_mem_index, int cuda_mem_index, int nvram_mem_index, |
47 | 3cbee15b | j_mayer | int nb_ide, int *ide_mem_index); |
48 | 3cbee15b | j_mayer | |
49 | 3cbee15b | j_mayer | /* NewWorld PowerMac IDE */
|
50 | 3cbee15b | j_mayer | int pmac_ide_init (BlockDriverState **hd_table, qemu_irq irq);
|
51 | 3cbee15b | j_mayer | |
52 | 3cbee15b | j_mayer | /* Heathrow PIC */
|
53 | 3cbee15b | j_mayer | qemu_irq *heathrow_pic_init(int *pmem_index,
|
54 | 3cbee15b | j_mayer | int nb_cpus, qemu_irq **irqs);
|
55 | 3cbee15b | j_mayer | |
56 | 3cbee15b | j_mayer | /* Grackle PCI */
|
57 | 3cbee15b | j_mayer | PCIBus *pci_grackle_init(uint32_t base, qemu_irq *pic); |
58 | 3cbee15b | j_mayer | |
59 | 3cbee15b | j_mayer | /* UniNorth PCI */
|
60 | 3cbee15b | j_mayer | PCIBus *pci_pmac_init(qemu_irq *pic); |
61 | 3cbee15b | j_mayer | |
62 | 3cbee15b | j_mayer | /* Mac NVRAM */
|
63 | 3cbee15b | j_mayer | typedef struct MacIONVRAMState MacIONVRAMState; |
64 | 3cbee15b | j_mayer | |
65 | 3cbee15b | j_mayer | MacIONVRAMState *macio_nvram_init (int *mem_index);
|
66 | 3cbee15b | j_mayer | void pmac_format_nvram_partition (MacIONVRAMState *nvr, int len); |
67 | 3cbee15b | j_mayer | uint32_t macio_nvram_read (void *opaque, uint32_t addr);
|
68 | 3cbee15b | j_mayer | void macio_nvram_write (void *opaque, uint32_t addr, uint32_t val); |
69 | 3cbee15b | j_mayer | |
70 | 3cbee15b | j_mayer | #endif /* !defined(__PPC_MAC_H__) */ |