diff options
author | 2008-11-24 12:12:12 +0000 | |
---|---|---|
committer | 2008-11-24 12:12:12 +0000 | |
commit | fca40c6ae55b733e12d27c61dbb07f5f5e90bc66 (patch) | |
tree | c36a5c0e6feea24f555552c5edbfe8701af37973 /sys/dev/gpio/files.gpio | |
parent | Seed the random pool with the dmesg buffer at randomattach(). (diff) | |
download | wireguard-openbsd-fca40c6ae55b733e12d27c61dbb07f5f5e90bc66.tar.xz wireguard-openbsd-fca40c6ae55b733e12d27c61dbb07f5f5e90bc66.zip |
- Add two new ioctls to gpio(4), GPIOATTACH and GPIODETACH, to allow to attach
and detach devices on a gpiobus at runtime. The offset and mask locators
in kernel config files can still be used for static configuration, so this
does not break existing custome kernel configs.
- Have gpioow(4) unmap the pins it used from the gpiobus during detach
Changes to gpioctl(8) will be a separate committ.
ok uwe
Diffstat (limited to 'sys/dev/gpio/files.gpio')
-rw-r--r-- | sys/dev/gpio/files.gpio | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/dev/gpio/files.gpio b/sys/dev/gpio/files.gpio index 79fd80d3a03..796dbc02e43 100644 --- a/sys/dev/gpio/files.gpio +++ b/sys/dev/gpio/files.gpio @@ -1,11 +1,16 @@ -# $OpenBSD: files.gpio,v 1.6 2006/03/04 16:27:03 grange Exp $ +# $OpenBSD: files.gpio,v 1.7 2008/11/24 12:12:12 mbalmer Exp $ -define gpio {offset, mask} +define gpio {[offset = -1], [mask = 0]} device gpio: gpio attach gpio at gpiobus file dev/gpio/gpio.c gpio needs-flag +# GPIO simulator +device gpiosim: gpiobus +attach gpiosim at root +file dev/gpio/gpiosim.c gpiosim needs-flag + # I2C bus bit-banging device gpioiic: i2cbus, i2c_bitbang attach gpioiic at gpio |