linux/arch/alpha/kernel/proto.h
<<
>>
Prefs
   1/* SPDX-License-Identifier: GPL-2.0 */
   2#include <linux/interrupt.h>
   3#include <linux/io.h>
   4
   5/* Prototypes of functions used across modules here in this directory.  */
   6
   7#define vucp    volatile unsigned char  *
   8#define vusp    volatile unsigned short *
   9#define vip     volatile int *
  10#define vuip    volatile unsigned int   *
  11#define vulp    volatile unsigned long  *
  12
  13struct pt_regs;
  14struct task_struct;
  15struct pci_dev;
  16struct pci_controller;
  17
  18/* core_apecs.c */
  19extern struct pci_ops apecs_pci_ops;
  20extern void apecs_init_arch(void);
  21extern void apecs_pci_clr_err(void);
  22extern void apecs_machine_check(unsigned long vector, unsigned long la_ptr);
  23extern void apecs_pci_tbi(struct pci_controller *, dma_addr_t, dma_addr_t);
  24
  25/* core_cia.c */
  26extern struct pci_ops cia_pci_ops;
  27extern void cia_init_pci(void);
  28extern void cia_init_arch(void);
  29extern void pyxis_init_arch(void);
  30extern void cia_kill_arch(int);
  31extern void cia_machine_check(unsigned long vector, unsigned long la_ptr);
  32extern void cia_pci_tbi(struct pci_controller *, dma_addr_t, dma_addr_t);
  33
  34/* core_irongate.c */
  35extern struct pci_ops irongate_pci_ops;
  36extern int irongate_pci_clr_err(void);
  37extern void irongate_init_arch(void);
  38#define irongate_pci_tbi ((void *)0)
  39
  40/* core_lca.c */
  41extern struct pci_ops lca_pci_ops;
  42extern void lca_init_arch(void);
  43extern void lca_machine_check(unsigned long vector, unsigned long la_ptr);
  44extern void lca_pci_tbi(struct pci_controller *, dma_addr_t, dma_addr_t);
  45
  46/* core_marvel.c */
  47extern struct pci_ops marvel_pci_ops;
  48extern void marvel_init_arch(void);
  49extern void marvel_kill_arch(int);
  50extern void marvel_machine_check(unsigned long, unsigned long);
  51extern void marvel_pci_tbi(struct pci_controller *, dma_addr_t, dma_addr_t);
  52extern int marvel_pa_to_nid(unsigned long);
  53extern int marvel_cpuid_to_nid(int);
  54extern unsigned long marvel_node_mem_start(int);
  55extern unsigned long marvel_node_mem_size(int);
  56extern struct _alpha_agp_info *marvel_agp_info(void);
  57struct io7 *marvel_find_io7(int pe);
  58struct io7 *marvel_next_io7(struct io7 *prev);
  59void io7_clear_errors(struct io7 *io7);
  60
  61/* core_mcpcia.c */
  62extern struct pci_ops mcpcia_pci_ops;
  63extern void mcpcia_init_arch(void);
  64extern void mcpcia_init_hoses(void);
  65extern void mcpcia_machine_check(unsigned long vector, unsigned long la_ptr);
  66extern void mcpcia_pci_tbi(struct pci_controller *, dma_addr_t, dma_addr_t);
  67
  68/* core_polaris.c */
  69extern struct pci_ops polaris_pci_ops;
  70extern int polaris_read_config_dword(struct pci_dev *, int, u32 *);
  71extern int polaris_write_config_dword(struct pci_dev *, int, u32);
  72extern void polaris_init_arch(void);
  73extern void polaris_machine_check(unsigned long vector, unsigned long la_ptr);
  74#define polaris_pci_tbi ((void *)0)
  75
  76/* core_t2.c */
  77extern struct pci_ops t2_pci_ops;
  78extern void t2_init_arch(void);
  79extern void t2_kill_arch(int);
  80extern void t2_machine_check(unsigned long vector, unsigned long la_ptr);
  81extern void t2_pci_tbi(struct pci_controller *, dma_addr_t, dma_addr_t);
  82
  83/* core_titan.c */
  84extern struct pci_ops titan_pci_ops;
  85extern void titan_init_arch(void);
  86extern void titan_kill_arch(int);
  87extern void titan_machine_check(unsigned long, unsigned long);
  88extern void titan_pci_tbi(struct pci_controller *, dma_addr_t, dma_addr_t);
  89extern struct _alpha_agp_info *titan_agp_info(void);
  90
  91/* core_tsunami.c */
  92extern struct pci_ops tsunami_pci_ops;
  93extern void tsunami_init_arch(void);
  94extern void tsunami_kill_arch(int);
  95extern void tsunami_machine_check(unsigned long vector, unsigned long la_ptr);
  96extern void tsunami_pci_tbi(struct pci_controller *, dma_addr_t, dma_addr_t);
  97
  98/* core_wildfire.c */
  99extern struct pci_ops wildfire_pci_ops;
 100extern void wildfire_init_arch(void);
 101extern void wildfire_kill_arch(int);
 102extern void wildfire_machine_check(unsigned long vector, unsigned long la_ptr);
 103extern void wildfire_pci_tbi(struct pci_controller *, dma_addr_t, dma_addr_t);
 104extern int wildfire_pa_to_nid(unsigned long);
 105extern int wildfire_cpuid_to_nid(int);
 106extern unsigned long wildfire_node_mem_start(int);
 107extern unsigned long wildfire_node_mem_size(int);
 108
 109/* console.c */
 110#ifdef CONFIG_VGA_HOSE
 111extern void find_console_vga_hose(void);
 112extern void locate_and_init_vga(void *(*)(void *, void *));
 113#else
 114static inline void find_console_vga_hose(void) { }
 115static inline void locate_and_init_vga(void *(*sel_func)(void *, void *)) { }
 116#endif
 117
 118/* setup.c */
 119extern unsigned long srm_hae;
 120extern int boot_cpuid;
 121#ifdef CONFIG_VERBOSE_MCHECK
 122extern unsigned long alpha_verbose_mcheck;
 123#endif
 124
 125/* srmcons.c */
 126#if defined(CONFIG_ALPHA_GENERIC) || defined(CONFIG_ALPHA_SRM)
 127extern void register_srm_console(void);
 128extern void unregister_srm_console(void);
 129#else
 130#define register_srm_console()
 131#define unregister_srm_console()
 132#endif
 133
 134/* smp.c */
 135extern void setup_smp(void);
 136extern void handle_ipi(struct pt_regs *);
 137
 138/* bios32.c */
 139/* extern void reset_for_srm(void); */
 140
 141/* time.c */
 142extern irqreturn_t rtc_timer_interrupt(int irq, void *dev);
 143extern void init_clockevent(void);
 144extern void common_init_rtc(void);
 145extern unsigned long est_cycle_freq;
 146
 147/* smc37c93x.c */
 148extern void SMC93x_Init(void);
 149
 150/* smc37c669.c */
 151extern void SMC669_Init(int);
 152
 153/* es1888.c */
 154extern void es1888_init(void);
 155
 156/* ../lib/fpreg.c */
 157extern void alpha_write_fp_reg (unsigned long reg, unsigned long val);
 158extern unsigned long alpha_read_fp_reg (unsigned long reg);
 159
 160/* head.S */
 161extern void wrmces(unsigned long mces);
 162extern void cserve_ena(unsigned long);
 163extern void cserve_dis(unsigned long);
 164extern void __smp_callin(unsigned long);
 165
 166/* entry.S */
 167extern void entArith(void);
 168extern void entIF(void);
 169extern void entInt(void);
 170extern void entMM(void);
 171extern void entSys(void);
 172extern void entUna(void);
 173extern void entDbg(void);
 174
 175/* ptrace.c */
 176extern int ptrace_set_bpt (struct task_struct *child);
 177extern int ptrace_cancel_bpt (struct task_struct *child);
 178
 179/* traps.c */
 180extern void dik_show_regs(struct pt_regs *regs, unsigned long *r9_15);
 181extern void die_if_kernel(char *, struct pt_regs *, long, unsigned long *);
 182
 183/* sys_titan.c */
 184extern void titan_dispatch_irqs(u64);
 185
 186/* ../mm/init.c */
 187extern void switch_to_system_map(void);
 188extern void srm_paging_stop(void);
 189
 190static inline int
 191__alpha_remap_area_pages(unsigned long address, unsigned long phys_addr,
 192                         unsigned long size, unsigned long flags)
 193{
 194        pgprot_t prot;
 195
 196        prot = __pgprot(_PAGE_VALID | _PAGE_ASM | _PAGE_KRE
 197                        | _PAGE_KWE | flags);
 198        return ioremap_page_range(address, address + size, phys_addr, prot);
 199}
 200
 201/* irq.c */
 202
 203#ifdef CONFIG_SMP
 204#define mcheck_expected(cpu)    (cpu_data[cpu].mcheck_expected)
 205#define mcheck_taken(cpu)       (cpu_data[cpu].mcheck_taken)
 206#define mcheck_extra(cpu)       (cpu_data[cpu].mcheck_extra)
 207#else
 208extern struct mcheck_info
 209{
 210        unsigned char expected __attribute__((aligned(8)));
 211        unsigned char taken;
 212        unsigned char extra;
 213} __mcheck_info;
 214
 215#define mcheck_expected(cpu)    (*((void)(cpu), &__mcheck_info.expected))
 216#define mcheck_taken(cpu)       (*((void)(cpu), &__mcheck_info.taken))
 217#define mcheck_extra(cpu)       (*((void)(cpu), &__mcheck_info.extra))
 218#endif
 219
 220extern void process_mcheck_info(unsigned long vector, unsigned long la_ptr,
 221                                const char *machine, int expected);
 222