qlge: fix an "&&" vs "||" bug
[linux-2.6/btrfs-unstable.git] / arch / sparc / kernel / kernel.h
blob291bb5de9ce0963184518a9a00872370821075d1
1 #ifndef __SPARC_KERNEL_H
2 #define __SPARC_KERNEL_H
4 #include <linux/interrupt.h>
6 #include <asm/traps.h>
7 #include <asm/head.h>
8 #include <asm/io.h>
10 /* cpu.c */
11 extern const char *sparc_pmu_type;
12 extern unsigned int fsr_storage;
13 extern int ncpus_probed;
15 #ifdef CONFIG_SPARC64
16 /* setup_64.c */
17 struct seq_file;
18 extern void cpucap_info(struct seq_file *);
20 static inline unsigned long kimage_addr_to_ra(const char *p)
22 unsigned long val = (unsigned long) p;
24 return kern_base + (val - KERNBASE);
26 #endif
28 #ifdef CONFIG_SPARC32
29 /* setup_32.c */
30 void sparc32_start_kernel(struct linux_romvec *rp);
32 /* cpu.c */
33 extern void cpu_probe(void);
35 /* traps_32.c */
36 extern void handle_hw_divzero(struct pt_regs *regs, unsigned long pc,
37 unsigned long npc, unsigned long psr);
38 /* irq_32.c */
39 extern struct irqaction static_irqaction[];
40 extern int static_irq_count;
41 extern spinlock_t irq_action_lock;
43 extern void unexpected_irq(int irq, void *dev_id, struct pt_regs * regs);
44 extern void init_IRQ(void);
46 /* sun4m_irq.c */
47 extern void sun4m_init_IRQ(void);
48 extern void sun4m_unmask_profile_irq(void);
49 extern void sun4m_clear_profile_irq(int cpu);
51 /* sun4d_irq.c */
52 extern spinlock_t sun4d_imsk_lock;
54 extern void sun4d_init_IRQ(void);
55 extern int sun4d_request_irq(unsigned int irq,
56 irq_handler_t handler,
57 unsigned long irqflags,
58 const char *devname, void *dev_id);
59 extern int show_sun4d_interrupts(struct seq_file *, void *);
60 extern void sun4d_distribute_irqs(void);
61 extern void sun4d_free_irq(unsigned int irq, void *dev_id);
63 /* head_32.S */
64 extern unsigned int t_nmi[];
65 extern unsigned int linux_trap_ipi15_sun4d[];
66 extern unsigned int linux_trap_ipi15_sun4m[];
68 extern struct tt_entry trapbase_cpu1;
69 extern struct tt_entry trapbase_cpu2;
70 extern struct tt_entry trapbase_cpu3;
72 extern char cputypval[];
74 /* entry.S */
75 extern unsigned long lvl14_save[4];
76 extern unsigned int real_irq_entry[];
77 extern unsigned int smp4d_ticker[];
78 extern unsigned int patchme_maybe_smp_msg[];
80 extern void floppy_hardint(void);
82 /* trampoline_32.S */
83 extern unsigned long sun4m_cpu_startup;
84 extern unsigned long sun4d_cpu_startup;
86 #else /* CONFIG_SPARC32 */
87 #endif /* CONFIG_SPARC32 */
88 #endif /* !(__SPARC_KERNEL_H) */