# HG changeset patch # User vae # Date 1333308977 0 # Node ID d5c8fd9bf282cea5e65d3f747f4b139e936147a6 # Parent 18fc84cf7262e532083166246da0b8e0aa1d81f7 Fix compiler warning, used uninitialized variable in a2fxxx_spi_set_ss(). diff --git a/packages/devs/spi/cortexm/a2fxxx/current/ChangeLog b/packages/devs/spi/cortexm/a2fxxx/current/ChangeLog --- a/packages/devs/spi/cortexm/a2fxxx/current/ChangeLog +++ b/packages/devs/spi/cortexm/a2fxxx/current/ChangeLog @@ -1,10 +1,14 @@ +2012-01-04 Christophe Coutand + * src/spi_a2fxxx.c: + Fix compiler warning, used uninitialized variable in a2fxxx_spi_set_ss(). + 2011-04-13 Christophe Coutand - * cdl/spi_a2fxxx.cdl: - * include/spi_a2fxxx.h: - * src/spi_a2fxxx.c: - New package -- Smartfusion Cortex-M3 SPI driver package. - [Bugzilla 1001291] + * cdl/spi_a2fxxx.cdl: + * include/spi_a2fxxx.h: + * src/spi_a2fxxx.c: + New package -- Smartfusion Cortex-M3 SPI driver package. + [Bugzilla 1001291] //=========================================================================== // ####GPLCOPYRIGHTBEGIN#### diff --git a/packages/devs/spi/cortexm/a2fxxx/current/src/spi_a2fxxx.c b/packages/devs/spi/cortexm/a2fxxx/current/src/spi_a2fxxx.c --- a/packages/devs/spi/cortexm/a2fxxx/current/src/spi_a2fxxx.c +++ b/packages/devs/spi/cortexm/a2fxxx/current/src/spi_a2fxxx.c @@ -310,6 +310,7 @@ static inline void a2fxxx_spi_set_ss ss = CYGHWR_HAL_A2FXXX_SPI0_SS3; } else { CYG_ASSERT (ss < 4, "SPI : SPI0 SS out of range."); + return; } } else { @@ -331,6 +332,7 @@ static inline void a2fxxx_spi_set_ss ss = CYGHWR_HAL_A2FXXX_SPI1_SS7; } else { CYG_ASSERT (ss < 8, "SPI : SPI1 SS out of range."); + return; } }