]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Rewrite gpioiic(4) to use the gpio_pin_* API, and to conform to the modern
authorian <ian@FreeBSD.org>
Sun, 1 Dec 2019 23:05:20 +0000 (23:05 +0000)
committerian <ian@FreeBSD.org>
Sun, 1 Dec 2019 23:05:20 +0000 (23:05 +0000)
commit2c28b775d8a89aed989398729d57691bad477211
treed17494e56a536dc294746bd3ae3d7f2e99aa2776
parent12b1f38c7c527c0a66e6384ef530588aac46bbd1
Rewrite gpioiic(4) to use the gpio_pin_* API, and to conform to the modern
FDT bindings document for gpio-i2c devices.

Using the gpio_pin_* functions to acquire/release/manipulate gpio pins
removes the constraint that both gpio pins must belong to the same gpio
controller/bank, and that the gpioiic instance must be a child of gpiobus.
Removing those constraints allows the driver to be fully compatible with
the modern dts bindings for a gpio bitbanged i2c bus.

For hinted attachment, the two gpio pins still must be on the same gpiobus,
and the device instance must be a child of that bus.  This preserves
compatibility for existing installations that have use gpioiic(4) with hints.
share/man/man4/gpioiic.4
sys/dev/gpio/gpioiic.c