forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
most of it belonged in irqflags.h, actually Signed-off-by: Al Viro <[email protected]> Signed-off-by: Richard Weinberger <[email protected]>
- Loading branch information
1 parent
b8c655d
commit a34978c
Showing
3 changed files
with
40 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,42 @@ | ||
#ifndef __UM_IRQFLAGS_H | ||
#define __UM_IRQFLAGS_H | ||
|
||
/* Empty for now */ | ||
extern int get_signals(void); | ||
extern int set_signals(int enable); | ||
extern void block_signals(void); | ||
extern void unblock_signals(void); | ||
|
||
static inline unsigned long arch_local_save_flags(void) | ||
{ | ||
return get_signals(); | ||
} | ||
|
||
static inline void arch_local_irq_restore(unsigned long flags) | ||
{ | ||
set_signals(flags); | ||
} | ||
|
||
static inline void arch_local_irq_enable(void) | ||
{ | ||
unblock_signals(); | ||
} | ||
|
||
static inline void arch_local_irq_disable(void) | ||
{ | ||
block_signals(); | ||
} | ||
|
||
static inline unsigned long arch_local_irq_save(void) | ||
{ | ||
unsigned long flags; | ||
flags = arch_local_save_flags(); | ||
arch_local_irq_disable(); | ||
return flags; | ||
} | ||
|
||
static inline bool arch_irqs_disabled(void) | ||
{ | ||
return arch_local_save_flags() == 0; | ||
} | ||
|
||
#endif |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters