drm/tests: hdmi: Fix memory leaks in drm_display_mode_from_cea_vic()
[drm/drm-misc.git] / drivers / iio / gyro / st_gyro.h
blobf5332b6a02bc1fd4e08b752ac22e593e663129f0
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3 * STMicroelectronics gyroscopes driver
5 * Copyright 2012-2013 STMicroelectronics Inc.
7 * Denis Ciocca <denis.ciocca@st.com>
8 * v. 1.0.0
9 */
11 #ifndef ST_GYRO_H
12 #define ST_GYRO_H
14 #include <linux/types.h>
15 #include <linux/iio/common/st_sensors.h>
17 #define L3G4200D_GYRO_DEV_NAME "l3g4200d"
18 #define LSM330D_GYRO_DEV_NAME "lsm330d_gyro"
19 #define LSM330DL_GYRO_DEV_NAME "lsm330dl_gyro"
20 #define LSM330DLC_GYRO_DEV_NAME "lsm330dlc_gyro"
21 #define L3GD20_GYRO_DEV_NAME "l3gd20"
22 #define L3GD20H_GYRO_DEV_NAME "l3gd20h"
23 #define L3G4IS_GYRO_DEV_NAME "l3g4is_ui"
24 #define LSM330_GYRO_DEV_NAME "lsm330_gyro"
25 #define LSM9DS0_GYRO_DEV_NAME "lsm9ds0_gyro"
27 #ifdef CONFIG_IIO_BUFFER
28 int st_gyro_allocate_ring(struct iio_dev *indio_dev);
29 int st_gyro_trig_set_state(struct iio_trigger *trig, bool state);
30 #define ST_GYRO_TRIGGER_SET_STATE (&st_gyro_trig_set_state)
31 #else /* CONFIG_IIO_BUFFER */
32 static inline int st_gyro_allocate_ring(struct iio_dev *indio_dev)
34 return 0;
36 #define ST_GYRO_TRIGGER_SET_STATE NULL
37 #endif /* CONFIG_IIO_BUFFER */
39 #endif /* ST_GYRO_H */