diff options
author | Marti Bolivar <mbolivar@leaflabs.com> | 2011-03-24 07:56:29 -0400 |
---|---|---|
committer | Marti Bolivar <mbolivar@leaflabs.com> | 2011-03-24 08:01:13 -0400 |
commit | bc246609ccd44601a0564fea8da407cc500ad471 (patch) | |
tree | 37dfa88dfc74f1fa18206c8587da6cfc4d39795d /libmaple | |
parent | 61db54f52f32e63c895d775982fbcdcb67f2dde6 (diff) | |
download | librambutan-bc246609ccd44601a0564fea8da407cc500ad471.tar.gz librambutan-bc246609ccd44601a0564fea8da407cc500ad471.zip |
timer_set_dma_burst_length() and TIMER8 comment bugfixes
Diffstat (limited to 'libmaple')
-rw-r--r-- | libmaple/timer.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libmaple/timer.h b/libmaple/timer.h index 025bcb0..fa19cc9 100644 --- a/libmaple/timer.h +++ b/libmaple/timer.h @@ -170,7 +170,7 @@ extern timer_dev *TIMER5; extern timer_dev *TIMER6; /** Timer 7 device (basic) */ extern timer_dev *TIMER7; -/** Timer 8 device (basic) */ +/** Timer 8 device (advanced) */ extern timer_dev *TIMER8; #endif @@ -855,7 +855,7 @@ static inline uint8 timer_get_dma_burst_length(timer_dev *dev) { static inline void timer_set_dma_burst_length(timer_dev *dev, uint8 length) { uint32 tmp = (dev->regs).gen->DCR; tmp &= ~TIMER_DCR_DBL; - tmp |= (length << 8) - 1; + tmp |= (length - 1) << 8; (dev->regs).gen->DCR = tmp; } |