#if !defined(__HW_SPAPR_H__)
#define __HW_SPAPR_H__
+#include "hw/xics.h"
+
struct VIOsPAPRBus;
struct icp_state;
struct VIOsPAPRBus *vio_bus;
struct icp_state *icp;
+ target_phys_addr_t ram_limit;
void *htab;
long htab_size;
target_phys_addr_t fdt_addr, rtas_addr;
long rtas_size;
void *fdt_skel;
target_ulong entry_point;
+ int next_irq;
+ int rtc_offset;
} sPAPREnvironment;
#define H_SUCCESS 0
target_ulong spapr_hypercall(CPUState *env, target_ulong opcode,
target_ulong *args);
+qemu_irq spapr_allocate_irq(uint32_t hint, uint32_t *irq_num);
+
static inline uint32_t rtas_ld(target_ulong phys, int n)
{
return ldl_be_phys(phys + 4*n);