NetBSD/share/man/man4/gpiolock.4

68 lines
1.9 KiB
Groff

.\" $NetBSD: gpiolock.4,v 1.4 2009/08/21 08:20:30 mbalmer Exp $
.\"
.\" Copyright (c) 2009 Marc Balmer <marc@msys.ch>
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
.Dd August 21, 2009
.Dt GPIOLOCK 4
.Os
.Sh NAME
.Nm gpiolock
.Nd support for multi-position keylocks attached to GPIO pins
.Sh SYNOPSIS
.Cd "gpiolock* at gpio? offset ? mask ?"
.Cd "gpiolock* at gpio?"
.Sh DESCRIPTION
The
.Nm
driver allows connecting of multi-position keylocks over GPIO pins.
The keylock driver registers with an in-kernel keylock supporting system
and provides
.Xr kauth 9
support through an experimental security model.
The keylock state can be queried using the hw.keylock sysctl variables.
Only locks with 2-4 positions are currently supported.
The pin number is specified in the kernel configuration with the
.Ar offset
locator.
The
.Ar mask
locator denotes the pins used for the lock (minimum 2, maximum 4 pins are used).
The
.Ar offset
and
.Ar mask
can also be specified when
.Nm
is attached at runtime using the
.Dv GPIOATTACH
.Xr ioctl 2
on the
.Xr gpio 4
device.
.Sh SEE ALSO
.Xr gpio 4 ,
.Xr intro 4
.Sh HISTORY
The
.Nm
driver first appeared in
.Nx 6.0 .
.Sh AUTHORS
.An -nosplit
The
.Nm
driver was written by
.An Marc Balmer Aq marc@msys.ch .