]> git.lizzy.rs Git - plan9front.git/blob - sys/src/9/alphapc/fns.h
etheriwl: implement 4965 firmware bootstrap (untested)
[plan9front.git] / sys / src / 9 / alphapc / fns.h
1 #include "../port/portfns.h"
2
3 Dirtab* addarchfile(char*, int, long(*)(Chan*,void*,long,vlong), long(*)(Chan*,void*,long,vlong));
4 void    archinit(void);
5 void    arginit(void);
6 void    arith(void);
7 ulong   cankaddr(ulong);
8 void    clock(Ureg*);
9 void    clockinit(void);
10 void    clockintrsched(void);
11 #define coherence       mb
12 int     cistrcmp(char*, char*);
13 int     cistrncmp(char*, char*, int);
14 int     cmpswap(long*, long, long);
15 void    cpuidprint(void);
16 void    cserve(ulong, ulong);
17 #define cycles(x)       do{}while(0)
18 void    timeradd(Timer *);
19 void    timerdel(Timer *);
20 int     dmacount(int);
21 int     dmadone(int);
22 void    dmaend(int);
23 int     dmainit(int, int);
24 long    dmasetup(int, void*, long, int);
25 void    _dumpstack(Ureg *);
26 void    evenaddr(ulong);
27 void    fataltrap(Ureg *, char *);
28 void    fault0(void);
29 void    faultalpha(Ureg*);
30 ulong   fcr31(void);
31 void    firmware(void);
32 void    fpenab(int);
33 void    fptrap(Ureg*);
34 int     getcfields(char*, char**, int, char*);
35 char    *getconf(char*);
36 int     havetimer(void);
37 int     i8042auxcmd(int);
38 void    i8042auxenable(void (*)(int, int));
39 void    i8042reset(void);
40 void    i8250console(void);
41 void    i8250mouse(char*, int(*)(Queue*,int), int);
42 void    i8250setmouseputc(char*, int (*)(Queue*, int));
43 void    i8259init(void);
44 int     i8259enable(int, int, Vctl*);
45 #define idlehands()             /* nothing to do in the runproc */
46 void    icflush(void);
47 void    illegal0(void);
48 void    intr0(void);
49 void    intrenable(int, void (*)(Ureg*, void*), void*, int, char*);
50 int     intrdisable(int, void (*)(Ureg *, void *), void*, int, char*);
51 int     ioalloc(int, int, int, char*);
52 void    iofree(int);
53 void    ioinit(void);
54 int     iounused(int, int);
55 int     irqallocread(char*, long, vlong);
56 int     isaconfig(char*, int, ISAConf*);
57 #define kexit(a)
58 #define kmapinval()
59 void    *kmapv(uvlong, int);
60 int     kprint(char*, ...);
61 void    links(void);
62 void    mb(void);
63 void    memholes(void);
64 ulong   meminit(void);
65 void    mmudump(void);
66 void    mmuinit(void);
67 void    mmupark(void);
68 #define mtrr(a, b, c)
69 ulong   pcibarsize(Pcidev*, int);
70 int     pcicfgr8(Pcidev*, int);
71 int     pcicfgr16(Pcidev*, int);
72 int     pcicfgr32(Pcidev*, int);
73 void    pcicfgw8(Pcidev*, int, int);
74 void    pcicfgw16(Pcidev*, int, int);
75 void    pcicfgw32(Pcidev*, int, int);
76 void    pciclrbme(Pcidev*);
77 void    pcihinv(Pcidev*);
78 Pcidev* pcimatch(Pcidev*, int, int);
79 Pcidev* pcimatchtbdf(int);
80 void    pcireset(void);
81 void    pcisetbme(Pcidev*);
82 int     pcmspecial(char*, ISAConf*);
83 int     (*_pcmspecial)(char *, ISAConf *);
84 void    pcmspecialclose(int);
85 void    (*_pcmspecialclose)(int);
86 void    prflush(void);
87 void    printinit(void);
88 #define procrestore(p)
89 void    procsave(Proc*);
90 void    procsetup(Proc*);
91 void    procfork(Proc*);
92 void    restfpregs(FPsave*);
93 uvlong  rpcc(uvlong*);
94 void    screeninit(void);
95 void    (*screenputs)(char*, int);
96 void    setpcb(PCB *);
97 PCB     *swpctx(PCB *);
98 void    syscall0(void);
99 int     tas(ulong*);
100 void    tlbflush(int, ulong);
101 void    touser(void*);
102 void    trapinit(void);
103 void    unaligned(void);
104 ulong   upaalloc(int, int);
105 void    upafree(ulong, int);
106 #define userureg(ur) ((ur)->status & UMODE)
107 void*   vmap(ulong, int);
108 void    wrent(int, void*);
109 void    wrvptptr(uvlong);
110 void    vunmap(void*, int);
111
112 #define waserror()      (up->nerrlab++, setlabel(&up->errlab[up->nerrlab-1]))
113 #define KADDR(a)        ((void*)((ulong)(a)|KZERO))
114 #define PADDR(a)        ((ulong)(a)&~KZERO)
115
116 #define inb(p)  (arch->_inb)(p)
117 #define ins(p)  (arch->_ins)(p)
118 #define inl(p)  (arch->_inl)(p)
119 #define outb(p, x)      (arch->_outb)((p), (x))
120 #define outs(p, x)      (arch->_outs)((p), (x))
121 #define outl(p, x)      (arch->_outl)((p), (x))
122
123 #define insb(p, buf, len)       (arch->_insb)((p), (buf), (len))
124 #define inss(p, buf, len)       (arch->_inss)((p), (buf), (len))
125 #define insl(p, buf, len)       (arch->_insl)((p), (buf), (len))
126 #define outsb(p, buf, len)      (arch->_outsb)((p), (buf), (len))
127 #define outss(p, buf, len)      (arch->_outss)((p), (buf), (len))
128 #define outsl(p, buf, len)      (arch->_outsl)((p), (buf), (len))