OSDN Git Service

iio: ping: add parallax ping sensors
authorAndreas Klinger <ak@it-klinger.de>
Mon, 25 Nov 2019 08:05:02 +0000 (09:05 +0100)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sun, 1 Dec 2019 10:23:04 +0000 (10:23 +0000)
commit7bb501f49ddb96365ef8d4fe882e5ceaa36215e4
treec851ac3be292902048031903ff728fa4ca2a51b1
parentf3bcd06f574a0751ee40ec25b9aad6968877ae5f
iio: ping: add parallax ping sensors

Add support for parallax ping and laser ping sensors with just one pin
for trigger and echo signal.

This driver is based on srf04. In contrast to it it's necessary to
change direction of the pin and to request the irq just for the period
when the echo is rising and falling. Because this adds a lot of cases
there is this individual driver for handling this type of sensors.

Add a new configuration variable CONFIG_PING to Kconfig and Makefile.

Julia reported an issue with failing to unlock a mutex in some error
paths.

Signed-off-by: Andreas Klinger <ak@it-klinger.de>
Reported-by: kbuild test robot <lkp@intel.com>
Reported-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/proximity/Kconfig
drivers/iio/proximity/Makefile
drivers/iio/proximity/ping.c [new file with mode: 0644]