forked from len0rd/rockbox
Coldfire: set_irq_level() mixed up the in/out registers
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@5363 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
bf41fcee8b
commit
abeb582a9c
1 changed files with 3 additions and 3 deletions
|
@ -147,12 +147,12 @@ enum {
|
|||
#define HIGHEST_IRQ_LEVEL (7<<8)
|
||||
static inline int set_irq_level(int level)
|
||||
{
|
||||
int i;
|
||||
int oldlevel;
|
||||
/* Read the old level and set the new one */
|
||||
asm volatile ("move.w %%sr,%0\n"
|
||||
"or.l #0x2000,%1\n"
|
||||
"move.w %1,%%sr\n" : "=r" (i) : "r" (level));
|
||||
return i;
|
||||
"move.w %1,%%sr\n" : "=r" (oldlevel), "+r" (level) : );
|
||||
return oldlevel;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue