configs/nucleo-l476rg/src/stm32_gpio.c, configs/stm32f103-minimum/src/stm32_gpio.c, and drivers/sensors/zerocross.c: Fix some errors when debug assertions are enabled.

This commit is contained in:
Matous Pokorny 2019-03-29 09:11:08 -06:00 committed by Gregory Nutt
parent 8ed0d21b73
commit 245bf33eb3
3 changed files with 3 additions and 3 deletions

View File

@ -207,7 +207,7 @@ static int gpint_read(FAR struct gpio_dev_s *dev, FAR bool *value)
FAR struct stm32gpint_dev_s *stm32gpint = (FAR struct stm32gpint_dev_s *)dev; FAR struct stm32gpint_dev_s *stm32gpint = (FAR struct stm32gpint_dev_s *)dev;
DEBUGASSERT(stm32gpint != NULL && value != NULL); DEBUGASSERT(stm32gpint != NULL && value != NULL);
DEBUGASSERT(stm32gpint->stm32gpio && stm32gpint->stm32gpio.id < BOARD_NGPIOINT); DEBUGASSERT(stm32gpint->stm32gpio.id < BOARD_NGPIOINT);
gpioinfo("Reading int pin...\n"); gpioinfo("Reading int pin...\n");
*value = stm32l4_gpioread(g_gpiointinputs[stm32gpint->stm32gpio.id]); *value = stm32l4_gpioread(g_gpiointinputs[stm32gpint->stm32gpio.id]);

View File

@ -204,7 +204,7 @@ static int gpint_read(FAR struct gpio_dev_s *dev, FAR bool *value)
FAR struct stm32gpint_dev_s *stm32gpint = (FAR struct stm32gpint_dev_s *)dev; FAR struct stm32gpint_dev_s *stm32gpint = (FAR struct stm32gpint_dev_s *)dev;
DEBUGASSERT(stm32gpint != NULL && value != NULL); DEBUGASSERT(stm32gpint != NULL && value != NULL);
DEBUGASSERT(stm32gpint->stm32gpio && stm32gpint->stm32gpio.id < BOARD_NGPIOINT); DEBUGASSERT(stm32gpint->stm32gpio.id < BOARD_NGPIOINT);
gpioinfo("Reading int pin...\n"); gpioinfo("Reading int pin...\n");
*value = stm32_gpioread(g_gpiointinputs[stm32gpint->stm32gpio.id]); *value = stm32_gpioread(g_gpiointinputs[stm32gpint->stm32gpio.id]);

View File

@ -417,7 +417,7 @@ static int zc_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
DEBUGASSERT(filep && filep->f_priv && filep->f_inode); DEBUGASSERT(filep && filep->f_priv && filep->f_inode);
opriv = filep->f_priv; opriv = filep->f_priv;
inode = filep->f_inode; inode = filep->f_inode;
DEBUGASSERT(inode->i_private) DEBUGASSERT(inode->i_private);
priv = (FAR struct zc_upperhalf_s *)inode->i_private; priv = (FAR struct zc_upperhalf_s *)inode->i_private;
/* Get exclusive access to the device structures */ /* Get exclusive access to the device structures */