diff options
author | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1995-12-01 17:47:17 +0000 |
---|---|---|
committer | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1995-12-01 17:47:17 +0000 |
commit | 3d7831adc09b830fff5e1904636fb672c5ed83e9 (patch) | |
tree | f0fc7f737ff7ecd4e0c705b2a45dafdea4ff2f42 /sys | |
parent | 59d27cc743cf94b797a17bd72703b8cb00d66add (diff) |
niklas pointed out the new MDP_UNCACHE_WX might break fork/exec.
always set/clear in setregs() now
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/amiga/amiga/machdep.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/sys/arch/amiga/amiga/machdep.c b/sys/arch/amiga/amiga/machdep.c index 739d05ae23a..f736d1ec425 100644 --- a/sys/arch/amiga/amiga/machdep.c +++ b/sys/arch/amiga/amiga/machdep.c @@ -416,6 +416,17 @@ setregs(p, pack, stack, retval) p->p_addr->u_pcb.pcb_fpregs.fpf_null = 0; m68881_restore(&p->p_addr->u_pcb.pcb_fpregs); #endif +#ifdef COMPAT_SUNOS + /* + * SunOS' ld.so does self-modifying code without knowing + * about the 040's cache purging needs. So we need to uncache + * writeable executable pages. + */ + if (p->p_emul == &emul_sunos) + p->p_md.md_flags |= MDP_UNCACHE_WX; + else + p->p_md.md_flags &= ~MDP_UNCACHE_WX; +#endif } /* |