blob: 010acb4cf96a57a336bd9db9068ada7a4a5c8610 [file] [log] [blame]
pbrook87ecb682007-11-17 17:14:51 +00001/*
2 * Misc ARM declarations
3 *
4 * Copyright (c) 2006 CodeSourcery.
5 * Written by Paul Brook
6 *
7 * This code is licenced under the LGPL.
8 *
9 */
10
11#ifndef ARM_MISC_H
12#define ARM_MISC_H 1
13
14/* The CPU is also modeled as an interrupt controller. */
15#define ARM_PIC_CPU_IRQ 0
16#define ARM_PIC_CPU_FIQ 1
17qemu_irq *arm_pic_init_cpu(CPUState *env);
18
19/* armv7m.c */
20qemu_irq *armv7m_init(int flash_size, int sram_size,
21 const char *kernel_filename, const char *cpu_model);
22
23/* arm_boot.c */
balrogf93eb9f2008-04-14 20:27:51 +000024struct arm_boot_info {
25 int ram_size;
26 const char *kernel_filename;
27 const char *kernel_cmdline;
28 const char *initrd_filename;
Anthony Liguoric227f092009-10-01 16:12:16 -050029 target_phys_addr_t loader_start;
30 target_phys_addr_t smp_loader_start;
Paul Brookf7c70322009-11-19 16:45:21 +000031 target_phys_addr_t smp_priv_base;
balrogf93eb9f2008-04-14 20:27:51 +000032 int nb_cpus;
33 int board_id;
34 int (*atag_board)(struct arm_boot_info *info, void *p);
Paul Brookf2d74972009-11-11 18:07:53 +000035 /* Used internally by arm_boot.c */
36 int is_linux;
37 target_phys_addr_t initrd_size;
38 target_phys_addr_t entry;
balrogf93eb9f2008-04-14 20:27:51 +000039};
40void arm_load_kernel(CPUState *env, struct arm_boot_info *info);
pbrook87ecb682007-11-17 17:14:51 +000041
blueswir179383c92008-08-30 09:51:20 +000042/* Multiplication factor to convert from system clock ticks to qemu timer
43 ticks. */
blueswir17ee930d2008-09-17 19:04:14 +000044extern int system_clock_scale;
pbrook87ecb682007-11-17 17:14:51 +000045
pbrook87ecb682007-11-17 17:14:51 +000046#endif /* !ARM_MISC_H */