xref: /OK3568_Linux_fs/kernel/drivers/input/sensors/accel/da215s/da215s.c (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun // SPDX-License-Identifier: GPL-2.0
2*4882a593Smuzhiyun /*
3*4882a593Smuzhiyun  * Copyright (c) 2021 Rockchip Electronics Co. Ltd.
4*4882a593Smuzhiyun  *
5*4882a593Smuzhiyun  * Author: Kay Guo <kay.guo@rock-chips.com>
6*4882a593Smuzhiyun  */
7*4882a593Smuzhiyun #include <linux/atomic.h>
8*4882a593Smuzhiyun #include <linux/delay.h>
9*4882a593Smuzhiyun #ifdef CONFIG_HAS_EARLYSUSPEND
10*4882a593Smuzhiyun #include <linux/earlysuspend.h>
11*4882a593Smuzhiyun #endif
12*4882a593Smuzhiyun #include <linux/freezer.h>
13*4882a593Smuzhiyun #include <linux/gpio.h>
14*4882a593Smuzhiyun #include <linux/i2c.h>
15*4882a593Smuzhiyun #include <linux/input.h>
16*4882a593Smuzhiyun #include <linux/interrupt.h>
17*4882a593Smuzhiyun #include <linux/irq.h>
18*4882a593Smuzhiyun #include <linux/miscdevice.h>
19*4882a593Smuzhiyun #include <linux/of_gpio.h>
20*4882a593Smuzhiyun #include <linux/sensor-dev.h>
21*4882a593Smuzhiyun #include <linux/slab.h>
22*4882a593Smuzhiyun #include <linux/uaccess.h>
23*4882a593Smuzhiyun #include <linux/workqueue.h>
24*4882a593Smuzhiyun 
25*4882a593Smuzhiyun #include "da215s_core.h"
26*4882a593Smuzhiyun 
27*4882a593Smuzhiyun /* Linear acceleration  register */
28*4882a593Smuzhiyun #define DA215S_CONFIG	0X00
29*4882a593Smuzhiyun #define DA215S_CHIP_ID	0x01
30*4882a593Smuzhiyun #define ACC_X_LSB	0x02
31*4882a593Smuzhiyun #define ACC_X_MSB	0x03
32*4882a593Smuzhiyun #define ACC_Y_LSB	0x04
33*4882a593Smuzhiyun #define ACC_Y_MSB	0x05
34*4882a593Smuzhiyun #define ACC_Z_LSB       0x06
35*4882a593Smuzhiyun #define ACC_Z_MSB       0x07
36*4882a593Smuzhiyun #define MOTION_FLAG	0x09
37*4882a593Smuzhiyun #define NEWDATA_FLAG	0x0A
38*4882a593Smuzhiyun #define ACTIVE_STATUS	0x0B
39*4882a593Smuzhiyun #define DA215S_RANGE	0x0F
40*4882a593Smuzhiyun #define ODR_AXIS	0x10
41*4882a593Smuzhiyun #define DA215S_MODE_BW	0x11
42*4882a593Smuzhiyun #define SWAP_POLARITY	0x12
43*4882a593Smuzhiyun #define INT_ACTIVE_SET1	0x16
44*4882a593Smuzhiyun #define INT_DATA_SET2	0x17
45*4882a593Smuzhiyun #define INT_MAP1	0x19
46*4882a593Smuzhiyun #define INT_MAP2	0x1A
47*4882a593Smuzhiyun #define INT_CONFIG	0x20
48*4882a593Smuzhiyun #define INT_LATCH	0x21
49*4882a593Smuzhiyun #define ACTIVE_DUR	0x27
50*4882a593Smuzhiyun #define ACTIVE_THS	0x28
51*4882a593Smuzhiyun 
52*4882a593Smuzhiyun #define DA215S_CHIPID_DATA	0x13
53*4882a593Smuzhiyun #define DA215S_CTRL_NORMAL	0x34
54*4882a593Smuzhiyun #define DA215S_CTRL_SUSPEND	0x80
55*4882a593Smuzhiyun #define INT_ACTIVE_ENABLE	0x87
56*4882a593Smuzhiyun #define INT_NEW_DATA_ENABLE	0x10
57*4882a593Smuzhiyun 
58*4882a593Smuzhiyun #define DA215S_OFFSET_MAX	200
59*4882a593Smuzhiyun #define DA215S_OFFSET_CUS	130
60*4882a593Smuzhiyun #define DA215S_OFFSET_SEN	1024
61*4882a593Smuzhiyun 
62*4882a593Smuzhiyun #define GSENSOR_MIN		2
63*4882a593Smuzhiyun #define DA215S_PRECISION	14
64*4882a593Smuzhiyun #define DA215S_DATA_RANGE	(16384*4)
65*4882a593Smuzhiyun #define DA215S_BOUNDARY		(0x1 << (DA215S_PRECISION - 1))
66*4882a593Smuzhiyun #define DA215S_GRAVITY_STEP	(DA215S_DATA_RANGE/DA215S_BOUNDARY)
67*4882a593Smuzhiyun 
68*4882a593Smuzhiyun 
sensor_active(struct i2c_client * client,int enable,int rate)69*4882a593Smuzhiyun static int sensor_active(struct i2c_client *client, int enable, int rate)
70*4882a593Smuzhiyun {
71*4882a593Smuzhiyun 	struct sensor_private_data *sensor =
72*4882a593Smuzhiyun 		(struct sensor_private_data *)i2c_get_clientdata(client);
73*4882a593Smuzhiyun 	int result = 0;
74*4882a593Smuzhiyun 
75*4882a593Smuzhiyun 	sensor->ops->ctrl_data = sensor_read_reg(client, sensor->ops->ctrl_reg);
76*4882a593Smuzhiyun 	if (enable)
77*4882a593Smuzhiyun 		sensor->ops->ctrl_data &= DA215S_CTRL_NORMAL;
78*4882a593Smuzhiyun 	else
79*4882a593Smuzhiyun 		sensor->ops->ctrl_data |= DA215S_CTRL_SUSPEND;
80*4882a593Smuzhiyun 
81*4882a593Smuzhiyun 	result = sensor_write_reg(client, sensor->ops->ctrl_reg,
82*4882a593Smuzhiyun 				  sensor->ops->ctrl_data);
83*4882a593Smuzhiyun 	if (result)
84*4882a593Smuzhiyun 		dev_err(&client->dev, "%s:fail to active sensor\n", __func__);
85*4882a593Smuzhiyun 
86*4882a593Smuzhiyun 	dev_dbg(&client->dev, "reg = 0x%x, reg_ctrl = 0x%x, enable= %d\n",
87*4882a593Smuzhiyun 		 sensor->ops->ctrl_reg, sensor->ops->ctrl_data, enable);
88*4882a593Smuzhiyun 
89*4882a593Smuzhiyun 	return result;
90*4882a593Smuzhiyun }
91*4882a593Smuzhiyun 
sensor_init(struct i2c_client * client)92*4882a593Smuzhiyun static int sensor_init(struct i2c_client *client)
93*4882a593Smuzhiyun {
94*4882a593Smuzhiyun 	struct sensor_private_data *sensor =
95*4882a593Smuzhiyun 		(struct sensor_private_data *)i2c_get_clientdata(client);
96*4882a593Smuzhiyun 	int status = 0;
97*4882a593Smuzhiyun 	int result = 0;
98*4882a593Smuzhiyun 
99*4882a593Smuzhiyun 	result = sensor->ops->active(client, 0, 0);
100*4882a593Smuzhiyun 	if (result) {
101*4882a593Smuzhiyun 		dev_err(&client->dev,
102*4882a593Smuzhiyun 			"%s:line=%d,error\n", __func__, __LINE__);
103*4882a593Smuzhiyun 		return result;
104*4882a593Smuzhiyun 	}
105*4882a593Smuzhiyun 	sensor->status_cur = SENSOR_OFF;
106*4882a593Smuzhiyun 
107*4882a593Smuzhiyun 	result = sensor_write_reg(client, 0x00, 0x24);
108*4882a593Smuzhiyun 	mdelay(25);
109*4882a593Smuzhiyun 	/*+/-4G,14bit  normal mode  ODR = 62.5hz*/
110*4882a593Smuzhiyun 	result |= sensor_write_reg(client, DA215S_RANGE, 0x61);
111*4882a593Smuzhiyun 	result |= sensor_write_reg(client, DA215S_MODE_BW, 0x34);
112*4882a593Smuzhiyun 	result |= sensor_write_reg(client, ODR_AXIS, 0x06);
113*4882a593Smuzhiyun 	if (result) {
114*4882a593Smuzhiyun 		dev_err(&client->dev, "%s:fail to config DA215S_accel.\n",
115*4882a593Smuzhiyun 		__func__);
116*4882a593Smuzhiyun 		return result;
117*4882a593Smuzhiyun 	}
118*4882a593Smuzhiyun 
119*4882a593Smuzhiyun 
120*4882a593Smuzhiyun 	/* Enable or Disable for active Interrupt */
121*4882a593Smuzhiyun 	status = sensor_read_reg(client, INT_ACTIVE_SET1);
122*4882a593Smuzhiyun 	if (sensor->pdata->irq_enable)
123*4882a593Smuzhiyun 		status |= INT_ACTIVE_ENABLE;
124*4882a593Smuzhiyun 	else
125*4882a593Smuzhiyun 		status &= ~INT_ACTIVE_ENABLE;
126*4882a593Smuzhiyun 	result = sensor_write_reg(client, INT_ACTIVE_SET1, status);
127*4882a593Smuzhiyun 	if (result) {
128*4882a593Smuzhiyun 		dev_err(&client->dev,
129*4882a593Smuzhiyun 			"%s:fail to set DA215S_INT_ACTIVE.\n", __func__);
130*4882a593Smuzhiyun 		return result;
131*4882a593Smuzhiyun 	}
132*4882a593Smuzhiyun 
133*4882a593Smuzhiyun 	/* Enable or Disable for new data Interrupt */
134*4882a593Smuzhiyun 	status = sensor_read_reg(client, INT_DATA_SET2);
135*4882a593Smuzhiyun 	if (sensor->pdata->irq_enable)
136*4882a593Smuzhiyun 		status |= INT_NEW_DATA_ENABLE;
137*4882a593Smuzhiyun 	else
138*4882a593Smuzhiyun 		status &= ~INT_NEW_DATA_ENABLE;
139*4882a593Smuzhiyun 	result = sensor_write_reg(client, INT_DATA_SET2, status);
140*4882a593Smuzhiyun 	if (result) {
141*4882a593Smuzhiyun 		dev_err(&client->dev,
142*4882a593Smuzhiyun 			"%s:fail to set DA215S_INT_NEW_DATA.\n", __func__);
143*4882a593Smuzhiyun 		return result;
144*4882a593Smuzhiyun 	}
145*4882a593Smuzhiyun 
146*4882a593Smuzhiyun 	return result;
147*4882a593Smuzhiyun }
148*4882a593Smuzhiyun 
sensor_convert_data(struct i2c_client * client,unsigned char low_byte4,unsigned char high_byte8)149*4882a593Smuzhiyun static int sensor_convert_data(struct i2c_client *client,
150*4882a593Smuzhiyun 			      unsigned char low_byte4, unsigned char high_byte8)
151*4882a593Smuzhiyun {
152*4882a593Smuzhiyun 	s64 result;
153*4882a593Smuzhiyun 
154*4882a593Smuzhiyun 	result = ((short)((high_byte8 << 8)|low_byte4)) >> 2;
155*4882a593Smuzhiyun 
156*4882a593Smuzhiyun 	return (int)result;
157*4882a593Smuzhiyun }
158*4882a593Smuzhiyun 
159*4882a593Smuzhiyun 
gsensor_report_value(struct i2c_client * client,struct sensor_axis * axis)160*4882a593Smuzhiyun static int gsensor_report_value(struct i2c_client *client,
161*4882a593Smuzhiyun 				struct sensor_axis *axis)
162*4882a593Smuzhiyun {
163*4882a593Smuzhiyun 	struct sensor_private_data *sensor =
164*4882a593Smuzhiyun 		(struct sensor_private_data *)i2c_get_clientdata(client);
165*4882a593Smuzhiyun 	if ((abs(sensor->axis.x - axis->x) > GSENSOR_MIN) ||
166*4882a593Smuzhiyun 	    (abs(sensor->axis.y - axis->y) > GSENSOR_MIN) ||
167*4882a593Smuzhiyun 	    (abs(sensor->axis.z - axis->z) > GSENSOR_MIN)) {
168*4882a593Smuzhiyun 		input_report_abs(sensor->input_dev, ABS_X, axis->x);
169*4882a593Smuzhiyun 		input_report_abs(sensor->input_dev, ABS_Y, axis->y);
170*4882a593Smuzhiyun 		input_report_abs(sensor->input_dev, ABS_Z, axis->z);
171*4882a593Smuzhiyun 		input_sync(sensor->input_dev);
172*4882a593Smuzhiyun 	}
173*4882a593Smuzhiyun 
174*4882a593Smuzhiyun 	return 0;
175*4882a593Smuzhiyun }
176*4882a593Smuzhiyun 
sensor_report_value(struct i2c_client * client)177*4882a593Smuzhiyun static int sensor_report_value(struct i2c_client *client)
178*4882a593Smuzhiyun {
179*4882a593Smuzhiyun 	struct sensor_axis axis;
180*4882a593Smuzhiyun 	struct sensor_private_data *sensor =
181*4882a593Smuzhiyun 		(struct sensor_private_data *)i2c_get_clientdata(client);
182*4882a593Smuzhiyun 	struct sensor_platform_data *pdata = sensor->pdata;
183*4882a593Smuzhiyun 	unsigned char buffer[6] = {0};
184*4882a593Smuzhiyun 	int x = 0, y = 0, z = 0;
185*4882a593Smuzhiyun 	int ret = 0;
186*4882a593Smuzhiyun 	int tmp_x = 0, tmp_y = 0, tmp_z = 0;
187*4882a593Smuzhiyun 
188*4882a593Smuzhiyun 	if (sensor->ops->read_len < 6) {
189*4882a593Smuzhiyun 		dev_err(&client->dev, "%s:Read len is error,len= %d\n",
190*4882a593Smuzhiyun 			__func__, sensor->ops->read_len);
191*4882a593Smuzhiyun 		return -EINVAL;
192*4882a593Smuzhiyun 	}
193*4882a593Smuzhiyun 
194*4882a593Smuzhiyun 	*buffer = sensor->ops->read_reg;
195*4882a593Smuzhiyun 	sensor_rx_data(client, buffer, sensor->ops->read_len);
196*4882a593Smuzhiyun 	if (ret < 0) {
197*4882a593Smuzhiyun 		dev_err(&client->dev,
198*4882a593Smuzhiyun 			"da215s read data failed, ret = %d\n", ret);
199*4882a593Smuzhiyun 		return ret;
200*4882a593Smuzhiyun 	}
201*4882a593Smuzhiyun 
202*4882a593Smuzhiyun 	/* x,y,z axis is the 12-bit acceleration output */
203*4882a593Smuzhiyun 	x = sensor_convert_data(sensor->client, buffer[0], buffer[1]);
204*4882a593Smuzhiyun 	y = sensor_convert_data(sensor->client, buffer[2], buffer[3]);
205*4882a593Smuzhiyun 	z = sensor_convert_data(sensor->client, buffer[4], buffer[5]);
206*4882a593Smuzhiyun 
207*4882a593Smuzhiyun 	dev_dbg(&client->dev, "%s:x=%d, y=%d, z=%d\n",  __func__, x, y, z);
208*4882a593Smuzhiyun 	da215s_temp_calibrate(&x, &y, &z);
209*4882a593Smuzhiyun 
210*4882a593Smuzhiyun 	dev_dbg(&client->dev, "%s:x=%d, y=%d, z=%d\n",  __func__, x, y, z);
211*4882a593Smuzhiyun 
212*4882a593Smuzhiyun 	tmp_x = x * DA215S_GRAVITY_STEP;
213*4882a593Smuzhiyun 	tmp_y = y * DA215S_GRAVITY_STEP;
214*4882a593Smuzhiyun 	tmp_z = z * DA215S_GRAVITY_STEP;
215*4882a593Smuzhiyun 	dev_dbg(&client->dev, "%s:temp_x=%d, temp_y=%d, temp_z=%d\n",
216*4882a593Smuzhiyun 		__func__, tmp_x, tmp_y, tmp_z);
217*4882a593Smuzhiyun 
218*4882a593Smuzhiyun 	axis.x = (pdata->orientation[0]) * tmp_x + (pdata->orientation[1]) * tmp_y +
219*4882a593Smuzhiyun 		 (pdata->orientation[2]) * tmp_z;
220*4882a593Smuzhiyun 	axis.y = (pdata->orientation[3]) * tmp_x + (pdata->orientation[4]) * tmp_y +
221*4882a593Smuzhiyun 		 (pdata->orientation[5]) * tmp_z;
222*4882a593Smuzhiyun 	axis.z = (pdata->orientation[6]) * tmp_x + (pdata->orientation[7]) * tmp_y +
223*4882a593Smuzhiyun 		 (pdata->orientation[8]) * tmp_z;
224*4882a593Smuzhiyun 	dev_dbg(&client->dev, "<map:>axis = %d, %d, %d\n", axis.x, axis.y, axis.z);
225*4882a593Smuzhiyun 
226*4882a593Smuzhiyun 	gsensor_report_value(client, &axis);
227*4882a593Smuzhiyun 
228*4882a593Smuzhiyun 	mutex_lock(&(sensor->data_mutex));
229*4882a593Smuzhiyun 	sensor->axis = axis;
230*4882a593Smuzhiyun 	mutex_unlock(&(sensor->data_mutex));
231*4882a593Smuzhiyun 
232*4882a593Smuzhiyun 	if (sensor->pdata->irq_enable) {
233*4882a593Smuzhiyun 		ret = sensor_write_reg(client, INT_MAP1, 0);
234*4882a593Smuzhiyun 		if (ret) {
235*4882a593Smuzhiyun 			dev_err(&client->dev,
236*4882a593Smuzhiyun 				"%s:fail to clear DA215S_INT_register.\n",
237*4882a593Smuzhiyun 				__func__);
238*4882a593Smuzhiyun 			return ret;
239*4882a593Smuzhiyun 		}
240*4882a593Smuzhiyun 		ret = sensor_write_reg(client, INT_MAP2, 0);
241*4882a593Smuzhiyun 		if (ret) {
242*4882a593Smuzhiyun 			dev_err(&client->dev,
243*4882a593Smuzhiyun 				"%s:fail to clear DA215S_INT_register.\n",
244*4882a593Smuzhiyun 				__func__);
245*4882a593Smuzhiyun 			return ret;
246*4882a593Smuzhiyun 		}
247*4882a593Smuzhiyun 	}
248*4882a593Smuzhiyun 
249*4882a593Smuzhiyun 	return ret;
250*4882a593Smuzhiyun }
251*4882a593Smuzhiyun 
252*4882a593Smuzhiyun /******************************************************************************/
sensor_suspend(struct i2c_client * client)253*4882a593Smuzhiyun static int sensor_suspend(struct i2c_client *client)
254*4882a593Smuzhiyun {
255*4882a593Smuzhiyun 	int result = 0;
256*4882a593Smuzhiyun 
257*4882a593Smuzhiyun //	MI_FUN;
258*4882a593Smuzhiyun //	result = mir3da_set_enable(client, false);
259*4882a593Smuzhiyun //	if (result) {
260*4882a593Smuzhiyun //		MI_ERR("sensor_suspend disable  fail!!\n");
261*4882a593Smuzhiyun //		return result;
262*4882a593Smuzhiyun //	}
263*4882a593Smuzhiyun 
264*4882a593Smuzhiyun 	return result;
265*4882a593Smuzhiyun }
266*4882a593Smuzhiyun 
267*4882a593Smuzhiyun /******************************************************************************/
sensor_resume(struct i2c_client * client)268*4882a593Smuzhiyun static int sensor_resume(struct i2c_client *client)
269*4882a593Smuzhiyun {
270*4882a593Smuzhiyun 	int result = 0;
271*4882a593Smuzhiyun 
272*4882a593Smuzhiyun //	MI_FUN;
273*4882a593Smuzhiyun 
274*4882a593Smuzhiyun 	/*
275*4882a593Smuzhiyun 	 * result = mir3da_chip_resume(client);
276*4882a593Smuzhiyun 	 * if(result) {
277*4882a593Smuzhiyun 	 * MI_ERR("sensor_resume chip resume fail!!\n");
278*4882a593Smuzhiyun 	 * return result;
279*4882a593Smuzhiyun 	 * }
280*4882a593Smuzhiyun 	 */
281*4882a593Smuzhiyun //	result = mir3da_set_enable(client, true);
282*4882a593Smuzhiyun //	if (result) {
283*4882a593Smuzhiyun //		MI_ERR("sensor_resume enable  fail!!\n");
284*4882a593Smuzhiyun //		return result;
285*4882a593Smuzhiyun //	}
286*4882a593Smuzhiyun 
287*4882a593Smuzhiyun 	return result;
288*4882a593Smuzhiyun }
289*4882a593Smuzhiyun 
290*4882a593Smuzhiyun static struct sensor_operate gsensor_da215s_ops = {
291*4882a593Smuzhiyun 	.name		= "gs_da215s",
292*4882a593Smuzhiyun 	.type		= SENSOR_TYPE_ACCEL,
293*4882a593Smuzhiyun 	.id_i2c		= ACCEL_ID_DA215S,
294*4882a593Smuzhiyun 	.read_reg	= ACC_X_LSB,
295*4882a593Smuzhiyun 	.read_len	= 6,
296*4882a593Smuzhiyun 	.id_reg		= DA215S_CHIP_ID,
297*4882a593Smuzhiyun 	.id_data	= DA215S_CHIPID_DATA,
298*4882a593Smuzhiyun 	.precision	= DA215S_PRECISION,
299*4882a593Smuzhiyun 	.ctrl_reg	= DA215S_MODE_BW,
300*4882a593Smuzhiyun 	.int_status_reg	= INT_MAP1,
301*4882a593Smuzhiyun 	.range          = {-DA215S_DATA_RANGE, DA215S_DATA_RANGE},
302*4882a593Smuzhiyun 	.trig		= IRQF_TRIGGER_LOW | IRQF_ONESHOT,
303*4882a593Smuzhiyun 	.active		= sensor_active,
304*4882a593Smuzhiyun 	.init		= sensor_init,
305*4882a593Smuzhiyun 	.report		= sensor_report_value,
306*4882a593Smuzhiyun 	.suspend        = sensor_suspend,
307*4882a593Smuzhiyun 	.resume         = sensor_resume,
308*4882a593Smuzhiyun };
309*4882a593Smuzhiyun 
gsensor_da215s_probe(struct i2c_client * client,const struct i2c_device_id * devid)310*4882a593Smuzhiyun static int gsensor_da215s_probe(struct i2c_client *client,
311*4882a593Smuzhiyun 				const struct i2c_device_id *devid)
312*4882a593Smuzhiyun {
313*4882a593Smuzhiyun 	return sensor_register_device(client, NULL, devid, &gsensor_da215s_ops);
314*4882a593Smuzhiyun }
315*4882a593Smuzhiyun 
gsensor_da215s_remove(struct i2c_client * client)316*4882a593Smuzhiyun static int gsensor_da215s_remove(struct i2c_client *client)
317*4882a593Smuzhiyun {
318*4882a593Smuzhiyun 	return sensor_unregister_device(client, NULL, &gsensor_da215s_ops);
319*4882a593Smuzhiyun }
320*4882a593Smuzhiyun 
321*4882a593Smuzhiyun static const struct i2c_device_id gsensor_da215s_id[] = {
322*4882a593Smuzhiyun 	{"gs_da215s", ACCEL_ID_DA215S},
323*4882a593Smuzhiyun 	{}
324*4882a593Smuzhiyun };
325*4882a593Smuzhiyun 
326*4882a593Smuzhiyun static struct i2c_driver gsensor_da215s_driver = {
327*4882a593Smuzhiyun 	.probe = gsensor_da215s_probe,
328*4882a593Smuzhiyun 	.remove = gsensor_da215s_remove,
329*4882a593Smuzhiyun 	.shutdown = sensor_shutdown,
330*4882a593Smuzhiyun 	.id_table = gsensor_da215s_id,
331*4882a593Smuzhiyun 	.driver = {
332*4882a593Smuzhiyun 		.name = "gsensor_da215s",
333*4882a593Smuzhiyun 	#ifdef CONFIG_PM
334*4882a593Smuzhiyun 		.pm = &sensor_pm_ops,
335*4882a593Smuzhiyun 	#endif
336*4882a593Smuzhiyun 	},
337*4882a593Smuzhiyun };
338*4882a593Smuzhiyun 
339*4882a593Smuzhiyun module_i2c_driver(gsensor_da215s_driver);
340*4882a593Smuzhiyun 
341*4882a593Smuzhiyun MODULE_AUTHOR("Guo Wangqiang <kay.guo@rock-chips.com>");
342*4882a593Smuzhiyun MODULE_DESCRIPTION("da215s 3-Axis accelerometer driver");
343*4882a593Smuzhiyun MODULE_LICENSE("GPL");
344