summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordzzxzz <[email protected]>2011-10-07 03:04:15 +0000
committerdzzxzz <[email protected]>2011-10-07 03:04:15 +0000
commit0d2624313a32529dd401ae841df4ea22472c2d7b (patch)
tree439c098873bcc94307ba39124e9dd857dc1445da
parente97c87d6a0947ff5e235d3e2c36a3d00279a78ae (diff)
fixed a potential issue in m16c porting:
the variable rt_thread_switch_interrupt_flag was treated as a word in interrupts.asm but it wad defined as a byte in cpuport.c rt_uint8_t rt_thread_switch_interrupt_flag; git-svn-id: https://rt-thread.googlecode.com/svn/trunk@1741 bbd45198-f89e-11dd-88c7-29a3b14d5316
-rw-r--r--bsp/m16c62p/interrupts.asm6
1 files changed, 3 insertions, 3 deletions
diff --git a/bsp/m16c62p/interrupts.asm b/bsp/m16c62p/interrupts.asm
index fb2d301d27..d3da490d0b 100644
--- a/bsp/m16c62p/interrupts.asm
+++ b/bsp/m16c62p/interrupts.asm
@@ -31,7 +31,7 @@
RSEG CODE:CODE:NOROOT(2)
rt_hw_context_switch_interrupt_do
- MOV.W #0, rt_thread_switch_interrupt_flag
+ MOV.B #0, rt_thread_switch_interrupt_flag
MOV.W rt_interrupt_from_thread, A0
STC ISP, [A0]
@@ -47,7 +47,7 @@ rt_hw_timer_handler:
JSR rt_tick_increase
JSR rt_interrupt_leave
- CMP.W #1, rt_thread_switch_interrupt_flag
+ CMP.B #1, rt_thread_switch_interrupt_flag
JEQ rt_hw_context_switch_interrupt_do
POPM R0,R1,R2,R3,A0,A1,SB,FB ; Restore current task's registers
@@ -60,7 +60,7 @@ rt_hw_uart0_receive_handler:
JSR u0rec_handler
JSR rt_interrupt_leave
- CMP.W #1, rt_thread_switch_interrupt_flag
+ CMP.B #1, rt_thread_switch_interrupt_flag
JEQ rt_hw_context_switch_interrupt_do
POPM R0,R1,R2,R3,A0,A1,SB,FB ; Restore current task's registers