Skip to content

Commit

Permalink
drivers: sensor: Fix missing DT_DRV_COMPAT
Browse files Browse the repository at this point in the history
Some sensor drivers modify there struct's based on DT defines.  In those
cases we need to make sure that DT_DRV_COMPAT is set on all the source
files associated with that driver.  This updates any such files.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
  • Loading branch information
galak committed Apr 17, 2020
1 parent c8e3b1f commit 762b521
Show file tree
Hide file tree
Showing 13 changed files with 26 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/sensor/adxl362/adxl362_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
* SPDX-License-Identifier: Apache-2.0
*/

#define DT_DRV_COMPAT adi_adxl362

#include <device.h>
#include <drivers/gpio.h>
#include <sys/util.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/adxl372/adxl372_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
* SPDX-License-Identifier: Apache-2.0
*/

#define DT_DRV_COMPAT adi_adxl372

#include <device.h>
#include <drivers/gpio.h>
#include <sys/util.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/iis2dlpc/iis2dlpc_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/iis2dlpc.pdf
*/

#define DT_DRV_COMPAT st_iis2dlpc

#include <kernel.h>
#include <drivers/sensor.h>
#include <drivers/gpio.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/iis2mdc/iis2mdc_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/iis2mdc.pdf
*/

#define DT_DRV_COMPAT st_iis2mdc

#include <kernel.h>
#include <drivers/sensor.h>
#include <drivers/gpio.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/iis3dhhc/iis3dhhc_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/iis3dhhc.pdf
*/

#define DT_DRV_COMPAT st_iis3dhhc

#include <kernel.h>
#include <drivers/sensor.h>
#include <drivers/gpio.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/ism330dhcx/ism330dhcx_shub.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/ism330dhcx.pdf
*/

#define DT_DRV_COMPAT st_ism330dhcx

#include <device.h>
#include <drivers/i2c.h>
#include <sys/byteorder.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/ism330dhcx/ism330dhcx_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/ism330dhcx.pdf
*/

#define DT_DRV_COMPAT st_ism330dhcx

#include <kernel.h>
#include <drivers/sensor.h>
#include <drivers/gpio.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/lis2dw12/lis2dw12_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/lis2dw12.pdf
*/

#define DT_DRV_COMPAT st_lis2dw12

#include <kernel.h>
#include <drivers/sensor.h>
#include <drivers/gpio.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/lis2mdl/lis2mdl_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/lis2mdl.pdf
*/

#define DT_DRV_COMPAT st_lis2mdl

#include <kernel.h>
#include <drivers/sensor.h>
#include <drivers/gpio.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/lps22hh/lps22hh_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/lps22hh.pdf
*/

#define DT_DRV_COMPAT st_lps22hh

#include <kernel.h>
#include <drivers/sensor.h>
#include <drivers/gpio.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/lsm6dso/lsm6dso_shub.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/lsm6dso.pdf
*/

#define DT_DRV_COMPAT st_lsm6dso

#include <device.h>
#include <drivers/i2c.h>
#include <sys/byteorder.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/lsm6dso/lsm6dso_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/lsm6dso.pdf
*/

#define DT_DRV_COMPAT st_lsm6dso

#include <kernel.h>
#include <drivers/sensor.h>
#include <drivers/gpio.h>
Expand Down
2 changes: 2 additions & 0 deletions drivers/sensor/stts751/stts751_trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* https://www.st.com/resource/en/datasheet/stts751.pdf
*/

#define DT_DRV_COMPAT st_stts751

#include <kernel.h>
#include <drivers/sensor.h>
#include <drivers/gpio.h>
Expand Down

0 comments on commit 762b521

Please sign in to comment.