diff options
author | Thiemo Seufer <ths@networkno.de> | 2005-02-21 11:44:31 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2005-10-29 19:30:41 +0100 |
commit | 049b13c358f0187cf3c5003d5fb9848dbcb28bc3 (patch) | |
tree | f37a46c080ae49ca932ca23ba33f44a80aca688a /include/asm-mips/io.h | |
parent | 9f83d839dfd2dbe421224c29f02cef77f5b4b875 (diff) | |
download | linux-3.10-049b13c358f0187cf3c5003d5fb9848dbcb28bc3.tar.gz linux-3.10-049b13c358f0187cf3c5003d5fb9848dbcb28bc3.tar.bz2 linux-3.10-049b13c358f0187cf3c5003d5fb9848dbcb28bc3.zip |
Enable/disable irq's only if needed.
Signed-off-by: Thiemo Seufer <ths@networkno.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'include/asm-mips/io.h')
-rw-r--r-- | include/asm-mips/io.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/include/asm-mips/io.h b/include/asm-mips/io.h index 039845f2e6b..1f2fe11f412 100644 --- a/include/asm-mips/io.h +++ b/include/asm-mips/io.h @@ -319,7 +319,8 @@ static inline type pfx##read##bwlq(volatile void __iomem *mem) \ else if (cpu_has_64bits) { \ unsigned long __flags; \ \ - local_irq_save(__flags); \ + if (irq) \ + local_irq_save(__flags); \ __asm__ __volatile__( \ ".set mips3" "\t\t# __readq" "\n\t" \ "ld %L0, %1" "\n\t" \ @@ -328,7 +329,8 @@ static inline type pfx##read##bwlq(volatile void __iomem *mem) \ ".set mips0" "\n" \ : "=r" (__val) \ : "m" (*__mem)); \ - local_irq_restore(__flags); \ + if (irq) \ + local_irq_restore(__flags); \ } else { \ __val = 0; \ BUG(); \ |