Added safety () around a macro parameter.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2315 35acf78f-673a-0410-8e92-d51de3d6d3f4master
parent
a53d698bb3
commit
a5c6d5b45b
|
@ -257,14 +257,14 @@ typedef enum {
|
||||||
* @notapi
|
* @notapi
|
||||||
*/
|
*/
|
||||||
#define _spi_isr_code(spip) { \
|
#define _spi_isr_code(spip) { \
|
||||||
if (spip->spd_config->spc_endcb) { \
|
if ((spip)->spd_config->spc_endcb) { \
|
||||||
spip->spd_state = SPI_COMPLETE; \
|
(spip)->spd_state = SPI_COMPLETE; \
|
||||||
spip->spd_config->spc_endcb(spip); \
|
(spip)->spd_config->spc_endcb(spip); \
|
||||||
if (spip->spd_state == SPI_COMPLETE) \
|
if ((spip)->spd_state == SPI_COMPLETE) \
|
||||||
spip->spd_state = SPI_READY; \
|
(spip)->spd_state = SPI_READY; \
|
||||||
} \
|
} \
|
||||||
else { \
|
else { \
|
||||||
spip->spd_state = SPI_READY; \
|
(spip)->spd_state = SPI_READY; \
|
||||||
_spi_wakeup(spip); \
|
_spi_wakeup(spip); \
|
||||||
} \
|
} \
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue