summaryrefslogtreecommitdiff
path: root/sys/src/9/pc/fns.h
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2014-10-21 06:03:03 +0200
committercinap_lenrek <cinap_lenrek@felloff.net>2014-10-21 06:03:03 +0200
commite81e1a4aeddad2bc612c9c5243573250b6ff33a4 (patch)
treef1c178d36e86819bc725fa3b009295553b01e737 /sys/src/9/pc/fns.h
parentdfe8c8bffb497ecd46e9e43eb838ff3e10912663 (diff)
pc, pc64: make mtrr() callable from interrupt context and before mpinit
to make it possible to mark the bootscreen framebuffer as write combining in early initialization, mtrr() is changed not not to error() but to return an error string. as bootscreen() is used before multiprocessor initialization, we have to synchronize the mtrr's for every processor as it comes online. for this, a new mtrrsync() function is provided that is called from cpuidentify() if mtrr support is indicated. the boot processor runs mtrrsync() which snarfs the registers. later, mtrrsync() is run again from the application processors which apply the values from the boot processor. checkmtrr() from mp.c was removed as its task is also done by mtrrsync() now.
Diffstat (limited to 'sys/src/9/pc/fns.h')
-rw-r--r--sys/src/9/pc/fns.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/src/9/pc/fns.h b/sys/src/9/pc/fns.h
index 99fa4b671..8ecaa0f7d 100644
--- a/sys/src/9/pc/fns.h
+++ b/sys/src/9/pc/fns.h
@@ -111,9 +111,10 @@ void mfence(void);
#define mmuflushtlb(pdb) putcr3(pdb)
void mmuinit(void);
ulong* mmuwalk(ulong*, ulong, int, int);
-int mtrr(uvlong, uvlong, char *);
+char* mtrr(uvlong, uvlong, char *);
void mtrrclock(void);
int mtrrprint(char *, long);
+void mtrrsync(void);
uchar nvramread(int);
void nvramwrite(int, uchar);
void outb(int, int);