Dear Jonanthan,

        I submitted another version of driver for Invensense MPU6050 last week. It basically fixed everything you said in the comments. It also removed the inv_mpu_misc file, which is not useful while taking too much spaces. However, only one thing I am not sure what to do with your comments. In the trigger part, as the red part shown below, what that mean and what I am supposed to do to make a callback. Thanks.

Best Regards,

Ge GAO

> +static int inv_mpu_data_rdy_trigger_set_state(struct iio_trigger *trig,

> +                                             bool state)

> +{

> +     struct iio_dev *indio_dev = trig->private_data;

> +

> +     return set_inv_enable(indio_dev, state);

Combine the above into one line.

> +}

> +

> +static const struct iio_trigger_ops inv_mpu_trigger_ops = {

> +     .owner = THIS_MODULE,

> +     .set_trigger_state = &inv_mpu_data_rdy_trigger_set_state,

You need some callbacks to prevent this being attached to another

trigger...

> +};

> +

> +int inv_mpu_probe_trigger(struct iio_dev *indio_dev)

> +{

> +     int ret;

> +     struct inv_mpu_iio_s *st = iio_priv(indio_dev);

> +

> +     st->trig = iio_trigger_alloc("%s-dev%d",