summaryrefslogtreecommitdiff
path: root/share
diff options
context:
space:
mode:
authorMichael Shalayeff <mickey@cvs.openbsd.org>2002-01-04 16:02:39 +0000
committerMichael Shalayeff <mickey@cvs.openbsd.org>2002-01-04 16:02:39 +0000
commite05bb384334fdf37a597f0b0f85d7a206bd06ebe (patch)
tree3c64abe8eb06fb5087b8c3038ceb9c9493e853b8 /share
parenta3bb70a708c8dded283b192db311d41b42803fac (diff)
update from Vladimir Popov <jumbo@narod.ru> and some from me
Diffstat (limited to 'share')
-rw-r--r--share/man/man9/radio.967
1 files changed, 51 insertions, 16 deletions
diff --git a/share/man/man9/radio.9 b/share/man/man9/radio.9
index 0cbff96836d..e77556df121 100644
--- a/share/man/man9/radio.9
+++ b/share/man/man9/radio.9
@@ -1,5 +1,6 @@
-.\" $OpenBSD: radio.9,v 1.2 2001/10/08 08:52:50 mpech Exp $
-.\"
+.\" $OpenBSD: radio.9,v 1.3 2002/01/04 16:02:38 mickey Exp $
+.\" $RuOBSD: radio.9,v 1.3 2001/10/26 05:38:44 form Exp $
+.\"
.\" Copyright (c) Maxim Tsyplakov <tm@oganer.net>
.\" All rights reserved.
.\"
@@ -13,13 +14,13 @@
.\" documentation and/or other materials provided with the distribution.
.\"
.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
-.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
-.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
-.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
.\" BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
.\" USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
-.\" ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+.\" ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.\"
@@ -38,12 +39,16 @@ The interface between these is the
structure.
.Bd -literal
struct radio_hw_if {
- int *open(dev_t, int, int, struct proc *);
- void *close(dev_t, int, int, struct proc *);
- int *ioctl(dev_t, u_long, caddr_t, int, struct proc *);
+ int (*open)(void *, int, int, struct proc *);
+ int (*close)(void *, int, int, struct proc *);
+ int (*get_info)(void *, struct radio_info *);
+ int (*set_info)(void *, struct radio_info *);
+ int (*search)(void *, int);
};
+
.Ed
.Pp
+
The high level radio driver attaches to the low level driver
when the latter calls
.Va radio_attach_mi .
@@ -62,28 +67,58 @@ struct is as shown above.
The
.Va hdlp
argument is a handle to some low level data structure.
-It is reserved field for future usage, and actually not used in any
-low-level driver functions.
+It is sent as the first argument to all the functions in
.Va radio_hw_if
when the high level driver calls them.
.Va dev
is the device struct for the hardware device.
.Pp
+
The fields of
.Va radio_hw_if
are described in some more detail below.
+
.Bd -literal
-int open (dev_t dev, int flags, int fmt, struct proc *p);
+int open (void *, int flags, int fmt, struct proc *p);
+ Optional.
Is called when the radio device is opened.
Returns 0 on success, otherwise an error code.
-int close (dev_t dev, int flags, int fmt, struct proc *p);
+int close (void *, int flags, int fmt, struct proc *p);
+ Optional.
Is called when the radio device is closed.
Returns 0 on success, otherwise an error code.
-int ioctl (dev_t dev, u_long cmd, caddr_t data, int flags, struct proc *p);
- Is ioctl requests handler function.
+int get_info (void *, struct radio_info *);
+ Fill the radio_info struct.
Returns 0 on success, otherwise an error code.
-.Ed
+
+int set_info (void *, struct radio_info *);
+ Set values from the radio_info struct.
+ Returns 0 on success, otherwise an error code.
+
+int search (void *, int);
+ Returns 0 on success, otherwise an error code.
+
.Sh SEE ALSO
+.Xr az 4
+.Xr mr 4
.Xr radio 4
+.Xr rt 4
+.Xr rtii 4
+.Xr sf2r 4
+.Xr sf4r 4
+.Sh AUTHORS
+The
+.Nm
+driver was written by
+.An Vladimir Popov Aq jumbo@narod.ru
+and
+.An Maxim Tsyplakov Aq tm@oganer.net .
+The man page was written by
+.An Maxim Tsyplakov Aq tm@oganer.net .
+.Sh HISTORY
+The
+.Nm
+device driver appeared in
+.Ox 3.0 .