Specifications
System Macros Invoked by Drivers
INVALIDATE_TB
preventing all other processors in the system from referencing the page it maps.
Because the INVALIDATE_TB macro calls system routines that rely on the stack
contents and use R2, none of the specified instruction arguments should reference
the stack or use R2.
To invalidate the entire translation buffer (without modifying PTEs), invoke
the INVALIDATE_TB macro with no addr and instruction arguments. Note
that, if the addr argument is not present and any instruction arguments are
specified, the INVALIDATE_TB macro invalidates the entire translation buffer
but does not execute any of the instructions. In this case, if checks=YES is
not overridden, the macro generates an assembly-time warning message if any
instruction arguments are present.
To invoke INVALIDATE_TB, code must be executing at or below IPL$_
INVALIDATE, holding—in a multiprocessing environment—no spinlock ranked
higher than INVALIDATE. If you issue the INVALIDATE_TB macro from
pageable code, you must ensure that the location of the code has been locked in
memory.
Example
MOVL 8(SP),R2 ;Load virtual address to invalidate
MOVL 12(SP),R3 ;Load address of PTE
INVALIDATE_TB R2,- ;Invalidate translation buffer
INST1=<BICL2 #PTE$M_VALID,(R3)> ;Clear PTE valid bit
The INVALIDATE_TB macro causes the PTE corresponding to the virtual address
supplied in R2 to be flushed from the system’s translation buffers. The macro
causes the specified BICL2 instruction to be executed while other processors in
the system are prevented from referencing the stale PTE.
2–42