Re: [PATCH v4 1/1] input: add driver for Bosch Sensortec's BMA150 accelerometer

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Only detail thing I see is this trivial one:

> +static int bma150_open(struct bma150_data *bma150)
> +{
> +	int ret = bma150_set_mode(bma150->client, BMA150_MODE_NORMAL);
> +	msleep(2);
> +	return ret;

Does the msleep here need to be inside the mutex lock for the IRQ
case ?

Otherwise it looks good except that the lack of runtime pm means it'll
stop the rest of the bus heirarchy from suspending and breaks
suspend/resume on runtime_pm based systems. I think we still need runtime
pm taking the pm reference on the input open dropping it on the close and
that's about it ? That will be sufficient to let the i2c bus controller
also runtime suspend/resume.

Not so sure about the sysfs drop - but I think its probably the right
thing for upstream and any long term 'we need a fancy driver' would be
via IIO which would sort all the interface problems.

Alan
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux