X-Git-Url: http://ftp.safe.ca/?a=blobdiff_plain;f=include%2Fasm-powerpc%2Fpaca.h;h=748b35ab37b5aa7fdf02291149777d3117803467;hb=08ddb2f4c270b5dff063f7dbcd7e9248a52e7c65;hp=ec94b51074fcf775dbf7f7102200a7999808c61b;hpb=2ef9481e666b4654159ac9f847e6963809e3c470;p=safe%2Fjmp%2Flinux-2.6 diff --git a/include/asm-powerpc/paca.h b/include/asm-powerpc/paca.h index ec94b51..748b35a 100644 --- a/include/asm-powerpc/paca.h +++ b/include/asm-powerpc/paca.h @@ -16,14 +16,25 @@ #define _ASM_POWERPC_PACA_H #ifdef __KERNEL__ -#include #include #include #include register struct paca_struct *local_paca asm("r13"); + +#if defined(CONFIG_DEBUG_PREEMPT) && defined(CONFIG_SMP) +extern unsigned int debug_smp_processor_id(void); /* from linux/smp.h */ +/* + * Add standard checks that preemption cannot occur when using get_paca(): + * otherwise the paca_struct it points to may be the wrong one just after. + */ +#define get_paca() ((void) debug_smp_processor_id(), local_paca) +#else #define get_paca() local_paca +#endif + #define get_lppaca() (get_paca()->lppaca_ptr) +#define get_slb_shadow() (get_paca()->slb_shadow_ptr) struct task_struct; @@ -70,6 +81,7 @@ struct paca_struct { s16 hw_cpu_id; /* Physical processor number */ u8 cpu_start; /* At startup, processor spins until */ /* this becomes non-zero. */ + struct slb_shadow *slb_shadow_ptr; /* * Now, starting in cacheline 2, the exception save areas @@ -79,13 +91,11 @@ struct paca_struct { u64 exmc[10]; /* used for machine checks */ u64 exslb[10]; /* used for SLB/segment table misses * on the linear mapping */ -#ifdef CONFIG_PPC_64K_PAGES - pgd_t *pgdir; -#endif /* CONFIG_PPC_64K_PAGES */ mm_context_t context; - u16 slb_cache[SLB_CACHE_ENTRIES]; + u16 vmalloc_sllp; u16 slb_cache_ptr; + u16 slb_cache[SLB_CACHE_ENTRIES]; /* * then miscellaneous read-write fields @@ -95,7 +105,16 @@ struct paca_struct { u64 stab_rr; /* stab/slb round-robin counter */ u64 saved_r1; /* r1 save for RTAS calls */ u64 saved_msr; /* MSR saved here by enter_rtas */ - u8 proc_enabled; /* irq soft-enable flag */ + u16 trap_save; /* Used when bad stack is encountered */ + u8 soft_enabled; /* irq soft-enable flag */ + u8 hard_enabled; /* set if irqs are enabled in MSR */ + u8 io_sync; /* writel() needs spin_unlock sync */ + + /* Stuff for accurate time accounting */ + u64 user_time; /* accumulated usermode TB ticks */ + u64 system_time; /* accumulated system TB ticks */ + u64 startpurr; /* PURR/TB value snapshot */ + u64 startspurr; /* SPURR value snapshot */ }; extern struct paca_struct paca[];