drivers/sensor: Add the ARG_UNUSED macro

Add the ARG_UNUSED macro to avoid compiler warnings.

Change-Id: I2e0d8ccdcd2d525e109cee6c3bd1035640618eb0
Signed-off-by: Flavio Santes <flavio.santes@intel.com>
This commit is contained in:
Flavio Santes 2016-12-21 00:07:42 -06:00 committed by Anas Nashif
parent 3d7d373a2f
commit 5799495a5b
3 changed files with 9 additions and 0 deletions

View File

@ -31,6 +31,9 @@ static void bmg160_gpio_callback(struct device *port, struct gpio_callback *cb,
struct bmg160_device_data *bmg160 =
CONTAINER_OF(cb, struct bmg160_device_data, gpio_cb);
ARG_UNUSED(port);
ARG_UNUSED(pin);
#if defined(CONFIG_BMG160_TRIGGER_OWN_THREAD)
k_sem_give(&bmg160->trig_sem);
#elif defined(CONFIG_BMG160_TRIGGER_GLOBAL_THREAD)

View File

@ -121,6 +121,9 @@ static void bmi160_gpio_callback(struct device *port,
struct bmi160_device_data *bmi160 =
CONTAINER_OF(cb, struct bmi160_device_data, gpio_cb);
ARG_UNUSED(port);
ARG_UNUSED(pin);
#if defined(CONFIG_BMI160_TRIGGER_OWN_THREAD)
k_sem_give(&bmi160->sem);
#elif defined(CONFIG_BMI160_TRIGGER_GLOBAL_THREAD)

View File

@ -79,6 +79,9 @@ static void fxos8700_thread_main(void *arg1, void *unused1, void *unused2)
struct device *dev = (struct device *)arg1;
struct fxos8700_data *data = dev->driver_data;
ARG_UNUSED(unused1);
ARG_UNUSED(unused2);
while (true) {
k_sem_take(&data->trig_sem, K_FOREVER);
fxos8700_handle_int(dev);