Re: using mprotect to write to .text

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Oct 11, 2011 at 11:43:20AM -0700, David Daney wrote:

> 1) cacheflush() clears all hazards.

More by accident than design - when I wrote the cacheflush syscall and
manpage in 1995 the term execution hazard barrier didn't yet exist in
manuals though the CPU behaviour was documented in the R4000 / R4600
manual of those days as a small number of pipeline cycles required to
handle.  The return patch of the syscall was taking care of this
implicitly.  And today the required R2 hazard barrier is provided by
the ERET instruction of the return path, so everything is fine.

But it may be worth updating the man page.  A change every 15 years or
so isn't that bad ;-)

  Ralf



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux