restore_flags man page on OpenMandriva

Man page or keyword search:  
man Server   8135 pages
apropos Keyword Search (all sections)
Output format
OpenMandriva logo
[printable version]

save_flags(9)		    Linux Kernel Functions		 save_flags(9)

NAME
       save_flags, restore_flags - save/restore processor state and irq mask

SYNOPSIS
       #include <asm/system.h>

       unsigned long flags;
       void save_flags(flags)
       void restore_flags(flags)

DESCRIPTION
       The save_flags and restore_flags macros cooperate with the cli function
       to provide interrupt protection	to  critical  sections	of  code.  The
       save_flags  function  saves  the current processor state, most specifi‐
       cally the interrupt priority level, in the flags value (which  must  be
       an  l-value).  The  flags  must	be  passed  to	a  subsequent  call to
       restore_flags to restore the processor state.

       The save_flags macro does not affect the processor state,  but  drivers
       may  use	 the cli(9) and sti functions to disable and enable interrupts
       after saving the current flags. When the critical section  of  code  is
       passed,	the  restore_flags  returns  the processor to its state at the
       point where the matching save_flags was called.

       Only values returned by save_flags can be passed to restore_flags.  Any
       other  values  may  cause  unpredictable results, and are certainly not
       portable.

RETURN VALUE
       The restore_flags macro saves the processor state in the flags  parame‐
       ter, which must be a non-const l-value.

AVAILABILITY
       Linux 1.0+

SEE ALSO
       cli(9)

AUTHOR
       Stephen Williams (steve@icarus.com)

BUGS
       How does all this react with symmetric multiprocessor machines?

Linux DDI			    $Date:$			 save_flags(9)
[top]

List of man pages available for OpenMandriva

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net