mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-11 07:34:31 +00:00
arc: interrupts - fix mask setup
To disable interrupts we need to reset corresponding flags in STATUS32 register. For this we need to OR flags for interrupts level1 and level2 and then AND with current value in STATUS32. Before that implementation was incorrect. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Signed-off-by: Igor Guryanov <guryanov@synopsys.com>
This commit is contained in:
parent
e47d733867
commit
c0e9535e1d
1 changed files with 1 additions and 1 deletions
|
@ -23,7 +23,7 @@ int interrupt_init(void)
|
|||
int disable_interrupts(void)
|
||||
{
|
||||
int status = read_aux_reg(ARC_AUX_STATUS32);
|
||||
int state = (status | E1_MASK | E2_MASK) ? 1 : 0;
|
||||
int state = (status & (E1_MASK | E2_MASK)) ? 1 : 0;
|
||||
|
||||
status &= ~(E1_MASK | E2_MASK);
|
||||
/* STATUS32 register is updated indirectly with "FLAG" instruction */
|
||||
|
|
Loading…
Reference in a new issue