[Tinyos-commits] CVS: tinyos-1.x/tos/platform/msp430
msp430hardware.h, 1.28, 1.29
David Gay
idgay at users.sourceforge.net
Mon Jun 20 15:07:47 PDT 2005
Update of /cvsroot/tinyos/tinyos-1.x/tos/platform/msp430
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5369/msp430
Modified Files:
msp430hardware.h
Log Message:
replace TOSH_sleep with __nesc_atomic_sleep (enable intr+sleep in one go),
to fix deadlock
Index: msp430hardware.h
===================================================================
RCS file: /cvsroot/tinyos/tinyos-1.x/tos/platform/msp430/msp430hardware.h,v
retrieving revision 1.28
retrieving revision 1.29
diff -C2 -d -r1.28 -r1.29
*** msp430hardware.h 14 May 2005 23:43:32 -0000 1.28
--- msp430hardware.h 20 Jun 2005 22:07:45 -0000 1.29
***************
*** 243,247 ****
}
! inline void TOSH_sleep() {
// The LPM we can go down to depends on the clocks used. We never go
// below LPM3, so ACLK is always enabled, also TimerB clock source
--- 243,247 ----
}
! inline void __nesc_atomic_sleep() {
// The LPM we can go down to depends on the clocks used. We never go
// below LPM3, so ACLK is always enabled, also TimerB clock source
***************
*** 252,262 ****
extern uint8_t TOSH_sched_full;
extern volatile uint8_t TOSH_sched_free;
- __nesc_atomic_t fInterruptFlags;
uint16_t LPMode_bits = 0;
! fInterruptFlags = __nesc_atomic_start();
!
! if ((LPMode_disabled) || (TOSH_sched_full != TOSH_sched_free)) {
! __nesc_atomic_end(fInterruptFlags);
return;
} else {
--- 252,259 ----
extern uint8_t TOSH_sched_full;
extern volatile uint8_t TOSH_sched_free;
uint16_t LPMode_bits = 0;
! if (LPMode_disabled) {
! __nesc_enable_interrupt();
return;
} else {
More information about the Tinyos-commits
mailing list