From 9607cf96b0f4278f4c268e48e70d17bf641f8233 Mon Sep 17 00:00:00 2001 From: utzig Date: Wed, 9 Jul 2014 01:29:01 +0000 Subject: [PATCH] Fixed warning git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@7025 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/ports/AVR/pwm_lld.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/os/hal/ports/AVR/pwm_lld.c b/os/hal/ports/AVR/pwm_lld.c index 44454d502..450d57b78 100644 --- a/os/hal/ports/AVR/pwm_lld.c +++ b/os/hal/ports/AVR/pwm_lld.c @@ -115,6 +115,7 @@ static void config_channel(volatile uint8_t *tccra, static uint8_t timer_index(PWMDriver *pwmp) { uint8_t index = 0; + #if AVR_PWM_USE_TIM1 || defined(__DOXYGEN__) if (pwmp == &PWMD1) return index; else index++; @@ -135,6 +136,9 @@ static uint8_t timer_index(PWMDriver *pwmp) if (pwmp == &PWMD5) return index; else index++; #endif + + /* This is an error! */ + return index; } /*===========================================================================*/