[Soekris] upcoming changes to gpioctl behavior in openbsd ?
Stuart Henderson
stu at spacehopper.org
Fri Jan 23 20:48:57 UTC 2009
On 2009-01-23, Lars Noodén <lars at umich.edu> wrote:
> A while back Marc Balmer wrote:
>
> Beware that the GPIO subsystem has seen substantial
> changes recently. In -current, and thus upcoming
> releases, GPIO pins can only be configured at
> securelevel 0.
>
> Where is a description of the upcoming changes, for those who would like
> to plan?
>
> Regards
> -Lars
It's probably simplest to just read the new version of the manual
pages:
http://www.openbsd.org/cgi-bin/man.cgi?query=gpioctl&manpath=OpenBSD+Current&arch=i386
http://www.openbsd.org/cgi-bin/man.cgi?query=gpio&manpath=OpenBSD+Current&arch=i386
Basically you must configure the pins for the type of operation you
require (in, out, inout <etc>) by adding gpioctl commands in rc.securelevel.
Once configured, a pin is available for use after the securelevel has been
raised.
On some machines, some GPIO pins could destroy your hardware, this
gives some extra protection against accidental or deliberate misuse.
$ grep gpio /usr/src/usr.bin/mg/theo.c
More information about the Soekris-tech
mailing list