Add rum(4) for newer USB Ralink devices. Obtained from OpenBSD.

Special thanks to Sepherosa Ziehau for helping debugging USB issues.
Hook up rum(4) for i386 config files.
This commit is contained in:
joerg 2006-10-31 22:21:16 +00:00
parent c00bfebf76
commit fc0bc19fc7
19 changed files with 3439 additions and 15 deletions

View File

@ -1,4 +1,4 @@
# $NetBSD: mi,v 1.665 2006/10/26 17:12:34 kleink Exp $
# $NetBSD: mi,v 1.666 2006/10/31 22:21:17 joerg Exp $
. base-sys-root
./altroot base-sys-root
./bin base-sys-root
@ -111,6 +111,9 @@
./libdata/firmware/ral/ral-rt2561 base-sys-root
./libdata/firmware/ral/ral-rt2561s base-sys-root
./libdata/firmware/ral/ral-rt2661 base-sys-root
./libdata/firmware/rum base-sys-root
./libdata/firmware/rum/rum-license base-sys-root
./libdata/firmware/rum/rum-rt2573 base-sys-root
./libexec base-sys-root
./mnt base-sys-root
./rescue base-sys-root

View File

@ -1,4 +1,4 @@
# $NetBSD: mi,v 1.946 2006/10/26 21:41:47 bjh21 Exp $
# $NetBSD: mi,v 1.947 2006/10/31 22:21:17 joerg Exp $
./etc/mtree/set.man man-sys-root
./usr/share/info/am-utils.info man-amd-info info
./usr/share/info/as.info man-computil-info bfd,info
@ -1217,6 +1217,7 @@
./usr/share/man/cat4/rtk.0 man-sys-catman .cat
./usr/share/man/cat4/rtpphy.0 man-obsolete obsolete
./usr/share/man/cat4/rtw.0 man-sys-catman .cat
./usr/share/man/cat4/rum.0 man-sys-catman .cat
./usr/share/man/cat4/satalink.0 man-sys-catman .cat
./usr/share/man/cat4/sb.0 man-sys-catman .cat
./usr/share/man/cat4/sbp.0 man-sys-catman .cat
@ -3609,6 +3610,7 @@
./usr/share/man/man4/rtk.4 man-sys-man .man
./usr/share/man/man4/rtpphy.4 man-obsolete obsolete
./usr/share/man/man4/rtw.4 man-sys-man .man
./usr/share/man/man4/rum.4 man-sys-man .man
./usr/share/man/man4/satalink.4 man-sys-man .man
./usr/share/man/man4/sb.4 man-sys-man .man
./usr/share/man/man4/sbp.4 man-sys-man .man

View File

@ -1,4 +1,4 @@
# $NetBSD: NetBSD.dist,v 1.325 2006/09/22 15:39:51 christos Exp $
# $NetBSD: NetBSD.dist,v 1.326 2006/10/31 22:21:17 joerg Exp $
# @(#)4.4BSD.dist 8.1 (Berkeley) 6/13/93
/set type=dir uname=root gname=wheel mode=0755
@ -52,6 +52,7 @@
./libdata
./libdata/firmware
./libdata/firmware/ral
./libdata/firmware/rum
./libexec
./mnt
./rescue

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.411 2006/10/26 21:37:08 bjh21 Exp $
# $NetBSD: Makefile,v 1.412 2006/10/31 22:21:18 joerg Exp $
# @(#)Makefile 8.1 (Berkeley) 6/18/93
MAN= aac.4 ac97.4 acardide.4 aceride.4 acphy.4 adc.4 adt7467c.4 adv.4 \
@ -34,7 +34,7 @@ MAN= aac.4 ac97.4 acardide.4 aceride.4 acphy.4 adc.4 adt7467c.4 adv.4 \
pcscp.4 pcweasel.4 pim.4 plip.4 pms.4 pnaphy.4 ppbus.4 ppp.4 \
pppoe.4 ptm.4 pty.4 puc.4 px.4 pxg.4 qe.4 qec.4 qsphy.4 \
raid.4 ral.4 ray.4 rcons.4 re.4 rgephy.4 rlphy.4 rnd.4 route.4 \
rs5c372rtc.4 rtk.4 rtw.4 \
rs5c372rtc.4 rtk.4 rtw.4 rum.4 \
satalink.4 sbus.4 scc.4 scsi.4 sd.4 se.4 sem.4 ses.4 sf.4 sfb.4 shb.4 \
shpcic.4 siop.4 sip.4 siside.4 sk.4 sl.4 slide.4 \
sm.4 spc.4 speaker.4 spif.4 sqphy.4 ss.4 \

324
share/man/man4/rum.4 Normal file
View File

@ -0,0 +1,324 @@
.\" $OpenBSD: rum.4,v 1.17 2006/10/22 08:29:01 damien Exp $
.\" $NetBSD: rum.4,v 1.1 2006/10/31 22:21:18 joerg Exp $
.\"
.\" Copyright (c) 2005, 2006
.\" Damien Bergamini <damien.bergamini@free.fr>
.\"
.\" 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 February 19, 2006
.Os
.Dt RUM 4
.Sh NAME
.Nm rum
.Nd Ralink Technology USB IEEE 802.11a/b/g wireless network device
.Sh SYNOPSIS
.Cd "rum* at uhub? port ?"
.Sh DESCRIPTION
The
.Nm
driver supports USB 2.0 wireless adapters based on the Ralink RT2501USB
and RT2601USB chipsets.
.Pp
The RT2501USB chipset is the second generation of 802.11a/b/g adapters from
Ralink.
It consists of two integrated chips, an RT2571W MAC/BBP and an RT2528 or
RT5226 radio transceiver.
.Pp
The RT2601USB chipset consists of two integrated chips, an RT2671 MAC/BBP and
an RT2527 or RT5225 radio transceiver.
This chipset uses the MIMO (multiple-input multiple-output) technology with
multiple antennas to extend the operating range of the adapter and to achieve
higher throughput.
MIMO is the basis of the forthcoming IEEE 802.11n standard.
.Pp
These are the modes the
.Nm
driver can operate in:
.Bl -tag -width "IBSS-masterXX"
.It BSS mode
Also known as
.Em infrastructure
mode, this is used when associating with an access point, through
which all traffic passes.
This mode is the default.
.It IBSS mode
Also known as
.Em IEEE ad-hoc
mode or
.Em peer-to-peer
mode.
This is the standardized method of operating without an access point.
Stations associate with a service set.
However, actual connections between stations are peer-to-peer.
.It Host AP
In this mode the driver acts as an access point (base station)
for other cards.
.It monitor mode
In this mode the driver is able to receive packets without
associating with an access point.
This disables the internal receive filter and enables the card to
capture packets from networks which it wouldn't normally have access to,
or to scan for access points.
.El
.Pp
.Nm
supports software WEP.
Wired Equivalent Privacy (WEP) is the de facto encryption standard
for wireless networks.
It can be typically configured in one of three modes:
no encryption; 40-bit encryption; or 104-bit encryption.
Unfortunately, due to serious weaknesses in WEP protocol
it is strongly recommended that it not be used as the
sole mechanism to secure wireless communication.
WEP is not enabled by default.
.Sh CONFIGURATION
The
.Nm
driver can be configured at runtime with
.Xr ifconfig 8
or on boot with
.Xr hostname.if 5
using the following parameters:
.Bl -tag -width Ds
.It Cm bssid Ar bssid
Set the desired BSSID.
.It Fl bssid
Unset the desired BSSID.
The interface will automatically select a BSSID in this mode, which is
the default.
.It Cm chan Ar n
Set the channel (radio frequency) to be used by the driver based on
the given channel ID
.Ar n .
.It Fl chan
Unset the desired channel to be used by the driver.
The driver will automatically select a channel in this mode, which is
the default.
.It Cm media Ar media
The
.Nm
driver supports the following
.Ar media
types:
.Pp
.Bl -tag -width autoselect -compact
.It Cm autoselect
Enable autoselection of the media type and options.
.It Cm DS1
Set 802.11b DS 1Mbps operation.
.It Cm DS2
Set 802.11b DS 2Mbps operation.
.It Cm DS5
Set 802.11b DS 5.5Mbps operation.
.It Cm DS11
Set 802.11b DS 11Mbps operation.
.It Cm OFDM6
Set 802.11a/g OFDM 6Mbps operation.
.It Cm OFDM9
Set 802.11a/g OFDM 9Mbps operation.
.It Cm OFDM12
Set 802.11a/g OFDM 12Mbps operation.
.It Cm OFDM18
Set 802.11a/g OFDM 18Mbps operation.
.It Cm OFDM24
Set 802.11a/g OFDM 24Mbps operation.
.It Cm OFDM36
Set 802.11a/g OFDM 36Mbps operation.
.It Cm OFDM48
Set 802.11a/g OFDM 48Mbps operation.
.It Cm OFDM54
Set 802.11a/g OFDM 54Mbps operation.
.El
.It Cm mediaopt Ar opts
The
.Nm
driver supports the following media options:
.Pp
.Bl -tag -width monitor -compact
.It Cm hostap
Select Host AP operation.
.It Cm ibss
Select IBSS operation.
.It Cm monitor
Select monitor mode.
.El
.It Fl mediaopt Ar opts
Disable the specified media options on the driver and return it to the
default mode of operation (BSS).
.It Cm mode Ar mode
The
.Nm
driver supports the following modes:
.Pp
.Bl -tag -width 11b -compact
.It Cm 11a
Force 802.11a operation.
.It Cm 11b
Force 802.11b operation.
.It Cm 11g
Force 802.11g operation.
.El
.It Cm nwid Ar id
Set the network ID.
The
.Ar id
can either be any text string up to 32 characters in length,
or a series of hexadecimal digits up to 64 digits.
An empty
.Ar id
string allows the interface to connect to any available access points.
By default the
.Nm
driver uses an empty string.
Note that network ID is synonymous with Extended Service Set ID (ESSID).
.It Cm nwkey Ar key
Enable WEP encryption using the specified
.Ar key .
The
.Ar key
can either be a string, a series of hexadecimal digits (preceded by
.Sq 0x ) ,
or a set of keys of the form
.Dq n:k1,k2,k3,k4 ,
where
.Sq n
specifies which of the keys will be used for transmitted packets,
and the four keys,
.Dq k1
through
.Dq k4 ,
are configured as WEP keys.
If a set of keys is specified, a comma
.Pq Sq \&,
within the key must be escaped with a backslash.
Note that if multiple keys are used, their order must be the same within
the network.
.Nm
is capable of using both 40-bit (5 characters or 10 hexadecimal digits)
or 104-bit (13 characters or 26 hexadecimal digits) keys.
.It Fl nwkey
Disable WEP encryption.
This is the default mode of operation.
.El
.Sh FILES
The following firmware file is loaded when an interface is brought up:
.Pp
.Bl -tag -width Ds -offset indent -compact
.It /etc/firmware/rum-rt2573
.El
.Sh HARDWARE
The following adapters should work:
.Pp
.Bl -tag -width Ds -offset indent -compact
.It Airlink101 AWLL5025
.It ASUS WL-167g ver 2
.It Belkin F5D7050 ver 3
.It Belkin F5D9050 ver 3
.It CNet CWD-854 ver F
.It Conceptronic C54RU ver 2
.It "D-Link DWL-G122 rev C1"
.It D-Link WUA-1340
.It Edimax EW-7318USG
.It Gigabyte GN-WB01GS
.It Hawking HWUG1
.It Linksys WUSB54G rev C
.It Planex GW-USMM
.It Senao NUB-3701
.It Sitecom WL-113 ver 2
.It Sitecom WL-172
.It TP-LINK TL-WN321G
.El
.Sh EXAMPLES
The following
.Xr hostname.if 5
example configures rum0 to join whatever network is available on boot,
using WEP key
.Dq 0x1deadbeef1 ,
channel 11, obtaining an IP address using DHCP:
.Bd -literal -offset indent
dhcp NONE NONE NONE nwkey 0x1deadbeef1 chan 11
.Ed
.Pp
The following
.Xr hostname.if 5
example creates a host-based access point on boot:
.Bd -literal -offset indent
inet 192.168.1.1 255.255.255.0 NONE media autoselect \e
mediaopt hostap nwid my_net chan 11
.Ed
.Pp
Configure rum0 for WEP, using hex key
.Dq 0x1deadbeef1 :
.Bd -literal -offset indent
# ifconfig rum0 nwkey 0x1deadbeef1
.Ed
.Pp
Return rum0 to its default settings:
.Bd -literal -offset indent
# ifconfig rum0 -bssid -chan media autoselect \e
nwid "" -nwkey
.Ed
.Pp
Join an existing BSS network,
.Dq my_net :
.Bd -literal -offset indent
# ifconfig rum0 192.168.1.1 netmask 0xffffff00 nwid my_net
.Ed
.Sh DIAGNOSTICS
.Bl -diag
.It "rum%d: failed loadfirmware of file %s"
For some reason, the driver was unable to read the microcode file from the
filesystem.
The file might be missing or corrupted.
.It "rum%d: could not load 8051 microcode"
An error occurred while attempting to upload the microcode to the onboard 8051
microcontroller unit.
.It "rum%d: device timeout"
A frame dispatched to the hardware for transmission did not complete in time.
The driver will reset the hardware.
This should not happen.
.El
.Sh SEE ALSO
.Xr arp 4 ,
.Xr ifmedia 4 ,
.Xr intro 4 ,
.Xr netintro 4 ,
.Xr usb 4 ,
.Xr hostname.if 5 ,
.Xr hostapd 8 ,
.Xr ifconfig 8
.Pp
Ralink Technology:
.Pa http://www.ralinktech.com
.Sh HISTORY
The
.Nm
driver first appeared in
.Nx 4.0
and
.Ox 4.0 .
.Sh AUTHORS
The
.Nm
driver was written by
.An Niall O'Higgins Aq niallo@openbsd.org
and
.An Damien Bergamini Aq damien@openbsd.org .
.Sh CAVEATS
The
.Nm
driver supports automatic control of the transmit speed in BSS mode only.
Therefore the use of a
.Nm
adapter in Host AP mode is discouraged.

View File

@ -1,4 +1,4 @@
# $NetBSD: ALL,v 1.69 2006/10/25 13:56:15 jmmv Exp $
# $NetBSD: ALL,v 1.70 2006/10/31 22:21:16 joerg Exp $
# From NetBSD: GENERIC,v 1.787 2006/10/01 18:37:54 bouyer Exp
#
# ALL machine description file
@ -17,7 +17,7 @@ include "arch/i386/conf/std.i386"
options INCLUDE_CONFIG_FILE # embed config file in kernel binary
#ident "ALL-$Revision: 1.69 $"
#ident "ALL-$Revision: 1.70 $"
maxusers 32 # estimated number of users
@ -1050,6 +1050,7 @@ url* at uhub? port ? # Realtek RTL8150L based adapters
# USB 802.11 adapters
atu* at uhub? port ? # Atmel AT76C50XX based adapters
ral* at uhub? port ? # Ralink Technology RT25x0 802.11a/b/g
rum* at uhub? port ? # Ralink Technology RT2501/RT2601 802.11a/b/g
# Prolific PL2301/PL2302 host-to-host adapter
upl* at uhub? port ?

View File

@ -1,4 +1,4 @@
# $NetBSD: GENERIC,v 1.792 2006/10/27 17:37:44 perry Exp $
# $NetBSD: GENERIC,v 1.793 2006/10/31 22:21:16 joerg Exp $
#
# GENERIC machine description file
#
@ -22,7 +22,7 @@ include "arch/i386/conf/std.i386"
options INCLUDE_CONFIG_FILE # embed config file in kernel binary
#ident "GENERIC-$Revision: 1.792 $"
#ident "GENERIC-$Revision: 1.793 $"
maxusers 32 # estimated number of users
@ -1068,6 +1068,7 @@ url* at uhub? port ? # Realtek RTL8150L based adapters
# USB 802.11 adapters
atu* at uhub? port ? # Atmel AT76C50XX based adapters
ral* at uhub? port ? # Ralink Technology RT25x0 802.11a/b/g
rum* at uhub? port ? # Ralink Technology RT2501/RT2601 802.11a/b/g
# Prolific PL2301/PL2302 host-to-host adapter
upl* at uhub? port ?

View File

@ -1,4 +1,4 @@
# $NetBSD: GENERIC_LAPTOP,v 1.210 2006/10/25 13:56:15 jmmv Exp $
# $NetBSD: GENERIC_LAPTOP,v 1.211 2006/10/31 22:21:17 joerg Exp $
# From: NetBSD: GENERIC,v 1.414 2001/07/30 19:59:05 ad Exp
#
# GENERIC_LAPTOP -- GENERIC with cardbus and some USB devices enabled
@ -8,7 +8,7 @@ include "arch/i386/conf/std.i386"
options INCLUDE_CONFIG_FILE # embed config file in kernel binary
#ident "GENERIC-$Revision: 1.210 $"
#ident "GENERIC-$Revision: 1.211 $"
maxusers 32 # estimated number of users
@ -736,6 +736,7 @@ url* at uhub? port ? # Realtek RTL8150L based adapters
# USB 802.11 adapters
atu* at uhub? port ? # Atmel AT76C50XX based adapters
ral* at uhub? port ? # Ralink Technology RT25x0 802.11a/b/g
rum* at uhub? port ? # Ralink Technology RT2501/RT2601 802.11a/b/g
# Prolific PL2301/PL2302 host-to-host adapter
upl* at uhub? port ?

View File

@ -1,4 +1,4 @@
# $NetBSD: XEN2_DOM0,v 1.13 2006/10/21 14:10:33 bouyer Exp $
# $NetBSD: XEN2_DOM0,v 1.14 2006/10/31 22:21:17 joerg Exp $
include "arch/xen/conf/std.xen"
@ -540,6 +540,7 @@ url* at uhub? port ? # Realtek RTL8150L based adapters
# USB 802.11 adapters
atu* at uhub? port ? # Atmel AT76C50XX based adapters
ral* at uhub? port ? # Ralink Technology RT25x0 802.11a/b/g
rum* at uhub? port ? # Ralink Technology RT2501/RT2601 802.11a/b/g
# Prolific PL2301/PL2302 host-to-host adapter
upl* at uhub? port ?

View File

@ -1,5 +1,5 @@
# $NetBSD: Makefile,v 1.5 2006/06/07 23:30:17 rpaulo Exp $
# $NetBSD: Makefile,v 1.6 2006/10/31 22:21:17 joerg Exp $
SUBDIR+= ral
SUBDIR+= ral rum
.include <bsd.subdir.mk>

View File

@ -0,0 +1,14 @@
# $NetBSD: Makefile,v 1.1 2006/10/31 22:21:17 joerg Exp $
NOMAN= # defined
FILES= rum-rt2573 rum-license
# XXX
includes:
clean:
cleandir:
.include <bsd.files.mk>

View File

@ -0,0 +1,57 @@
/* $NetBSD: build.c,v 1.1 2006/10/31 22:21:17 joerg Exp $ */
/* $OpenBSD: build.c,v 1.1 2006/01/09 20:03:40 damien Exp $ */
/*-
* Copyright (c) 2006
* Damien Bergamini <damien.bergamini@free.fr>
*
* 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.
*/
#include <sys/types.h>
#include <err.h>
#include <fcntl.h>
#include <stdio.h>
#include <unistd.h>
#include "microcode.h"
static void
output(const char *name, const uint8_t *ucode, int size)
{
ssize_t rlen;
int fd;
printf("creating %s length %d\n", name, size);
fd = open(name, O_WRONLY | O_CREAT | O_TRUNC, 0644);
if (fd == -1)
err(1, "%s", name);
rlen = write(fd, ucode, size);
if (rlen == -1)
err(1, "%s", name);
if (rlen != size)
errx(1, "%s: short write", name);
close(fd);
}
int
main(void)
{
output("rum-rt2573", rt2573, sizeof rt2573);
return 0;
}

View File

@ -0,0 +1,213 @@
/* $OpenBSD: microcode.h,v 1.1 2006/08/17 08:32:30 damien Exp $ */
/*-
* Copyright (c) 2005-2006, Ralink Technology, Corp.
* Paul Lin <paul_lin@ralinktech.com.tw>
*
* 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.
*/
/*
* This file contains the loadable 8051 microcode for the Ralink RT2573
* chipset.
*/
static const uint8_t rt2573[] = {
0x02, 0x13, 0x25, 0x12, 0x10, 0xd9, 0x02, 0x12, 0x58, 0x02, 0x13,
0x58, 0x02, 0x13, 0x5a, 0xc0, 0xd0, 0x75, 0xd0, 0x18, 0x12, 0x13,
0x5c, 0xd0, 0xd0, 0x22, 0x02, 0x14, 0x5c, 0x02, 0x14, 0xe7, 0xed,
0x4c, 0x70, 0x44, 0x90, 0x01, 0xa8, 0x74, 0x80, 0xf0, 0xef, 0x30,
0xe5, 0x07, 0xe4, 0x90, 0x00, 0x0f, 0xf0, 0x80, 0x2c, 0xe5, 0x40,
0x24, 0xc0, 0x60, 0x13, 0x24, 0xc0, 0x60, 0x16, 0x24, 0xc0, 0x60,
0x19, 0x24, 0xc0, 0x70, 0x1a, 0xe4, 0x90, 0x00, 0x0b, 0xf0, 0x80,
0x13, 0xe4, 0x90, 0x00, 0x13, 0xf0, 0x80, 0x0c, 0xe4, 0x90, 0x00,
0x1b, 0xf0, 0x80, 0x05, 0xe4, 0x90, 0x00, 0x23, 0xf0, 0xe4, 0x90,
0x01, 0xa8, 0xf0, 0xd3, 0x22, 0x90, 0x02, 0x02, 0xed, 0xf0, 0x90,
0x02, 0x01, 0xef, 0xf0, 0xd3, 0x22, 0xef, 0x24, 0xc0, 0x60, 0x1f,
0x24, 0xc0, 0x60, 0x2e, 0x24, 0xc0, 0x60, 0x3d, 0x24, 0xc0, 0x70,
0x53, 0x90, 0x00, 0x0b, 0xe0, 0x30, 0xe1, 0x02, 0xc3, 0x22, 0x90,
0x00, 0x09, 0xe0, 0xfe, 0x90, 0x00, 0x08, 0x80, 0x37, 0x90, 0x00,
0x13, 0xe0, 0x30, 0xe1, 0x02, 0xc3, 0x22, 0x90, 0x00, 0x11, 0xe0,
0xfe, 0x90, 0x00, 0x10, 0x80, 0x24, 0x90, 0x00, 0x1b, 0xe0, 0x30,
0xe1, 0x02, 0xc3, 0x22, 0x90, 0x00, 0x19, 0xe0, 0xfe, 0x90, 0x00,
0x18, 0x80, 0x11, 0x90, 0x00, 0x23, 0xe0, 0x30, 0xe1, 0x02, 0xc3,
0x22, 0x90, 0x00, 0x21, 0xe0, 0xfe, 0x90, 0x00, 0x20, 0xe0, 0xfd,
0xee, 0xf5, 0x37, 0xed, 0xf5, 0x38, 0xd3, 0x22, 0x30, 0x09, 0x20,
0x20, 0x04, 0x0b, 0x90, 0x02, 0x08, 0xe0, 0x54, 0x0f, 0x70, 0x03,
0x02, 0x12, 0x57, 0xc2, 0x09, 0x90, 0x02, 0x00, 0xe0, 0x44, 0x04,
0xf0, 0x74, 0x04, 0x12, 0x0c, 0x3a, 0xc2, 0x04, 0xc2, 0x07, 0x90,
0x02, 0x01, 0xe0, 0x30, 0xe0, 0x03, 0x00, 0x80, 0xf6, 0x90, 0x03,
0x26, 0xe0, 0x20, 0xe2, 0x03, 0x02, 0x12, 0x57, 0x90, 0x02, 0x08,
0xe0, 0x70, 0x1b, 0x20, 0x07, 0x03, 0x02, 0x12, 0x57, 0x90, 0x03,
0x12, 0xe0, 0x64, 0x22, 0x60, 0x03, 0x02, 0x12, 0x57, 0xd2, 0x09,
0xc2, 0x07, 0x74, 0x02, 0x12, 0x0c, 0x3a, 0x22, 0x90, 0x02, 0x03,
0xe0, 0x30, 0xe4, 0x47, 0x20, 0x06, 0x44, 0xe5, 0x3c, 0x60, 0x34,
0xe5, 0x40, 0x24, 0xc0, 0x60, 0x14, 0x24, 0xc0, 0x60, 0x18, 0x24,
0xc0, 0x60, 0x1c, 0x24, 0xc0, 0x70, 0x22, 0x90, 0x00, 0x0b, 0xe0,
0x30, 0xe1, 0x1b, 0x22, 0x90, 0x00, 0x13, 0xe0, 0x30, 0xe1, 0x13,
0x22, 0x90, 0x00, 0x1b, 0xe0, 0x30, 0xe1, 0x0b, 0x22, 0x90, 0x00,
0x23, 0xe0, 0x30, 0xe1, 0x03, 0x02, 0x12, 0x57, 0x90, 0x02, 0x03,
0x74, 0x01, 0xf0, 0x00, 0xe0, 0x54, 0xc0, 0xf5, 0x40, 0xe5, 0x40,
0x24, 0xc0, 0x60, 0x20, 0x24, 0xc0, 0x60, 0x30, 0x24, 0xc0, 0x60,
0x40, 0x24, 0xc0, 0x70, 0x56, 0x90, 0x00, 0x0b, 0xe0, 0x30, 0xe1,
0x03, 0x02, 0x12, 0x57, 0x90, 0x00, 0x09, 0xe0, 0xfe, 0x90, 0x00,
0x08, 0x80, 0x3a, 0x90, 0x00, 0x13, 0xe0, 0x30, 0xe1, 0x03, 0x02,
0x12, 0x57, 0x90, 0x00, 0x11, 0xe0, 0xfe, 0x90, 0x00, 0x10, 0x80,
0x26, 0x90, 0x00, 0x1b, 0xe0, 0x30, 0xe1, 0x03, 0x02, 0x12, 0x57,
0x90, 0x00, 0x19, 0xe0, 0xfe, 0x90, 0x00, 0x18, 0x80, 0x12, 0x90,
0x00, 0x23, 0xe0, 0x30, 0xe1, 0x03, 0x02, 0x12, 0x57, 0x90, 0x00,
0x21, 0xe0, 0xfe, 0x90, 0x00, 0x20, 0xe0, 0xfd, 0xee, 0xf5, 0x37,
0xed, 0xf5, 0x38, 0x90, 0x03, 0x27, 0x74, 0x82, 0xf0, 0x90, 0x02,
0x01, 0xe5, 0x40, 0xf0, 0x90, 0x02, 0x06, 0xe0, 0xf5, 0x3c, 0xc3,
0xe5, 0x38, 0x95, 0x3a, 0xe5, 0x37, 0x95, 0x39, 0x50, 0x21, 0xe5,
0x40, 0x44, 0x05, 0xff, 0xe5, 0x37, 0xa2, 0xe7, 0x13, 0xfc, 0xe5,
0x38, 0x13, 0xfd, 0x12, 0x10, 0x20, 0xe5, 0x3c, 0x30, 0xe2, 0x04,
0xd2, 0x06, 0x80, 0x02, 0xc2, 0x06, 0x53, 0x3c, 0x01, 0x22, 0x30,
0x0b, 0x07, 0xe4, 0x90, 0x02, 0x02, 0xf0, 0x80, 0x06, 0x90, 0x02,
0x02, 0x74, 0x20, 0xf0, 0xe5, 0x40, 0x44, 0x01, 0x90, 0x02, 0x01,
0xf0, 0x90, 0x02, 0x01, 0xe0, 0x30, 0xe0, 0x03, 0x00, 0x80, 0xf6,
0x90, 0x03, 0x27, 0x74, 0x02, 0xf0, 0xaf, 0x40, 0x12, 0x10, 0x74,
0x40, 0xa5, 0x00, 0x80, 0xf6, 0x22, 0x90, 0x7f, 0xf8, 0xe0, 0xb4,
0x02, 0x03, 0x12, 0x16, 0x38, 0x90, 0x02, 0x01, 0xe0, 0x30, 0xe0,
0x03, 0x00, 0x80, 0xf6, 0x90, 0x03, 0x26, 0xe0, 0x20, 0xe1, 0x07,
0xe5, 0x3b, 0x70, 0x03, 0x02, 0x13, 0x24, 0xe5, 0x3b, 0x70, 0x15,
0x90, 0x03, 0x24, 0xe0, 0x75, 0xf0, 0x40, 0xa4, 0xf5, 0x36, 0x85,
0xf0, 0x35, 0x75, 0x24, 0x83, 0x75, 0x3b, 0x01, 0x80, 0x03, 0x75,
0x24, 0x03, 0xd3, 0xe5, 0x36, 0x95, 0x3a, 0xe5, 0x35, 0x95, 0x39,
0x40, 0x36, 0x90, 0x02, 0x01, 0xe0, 0x30, 0xe0, 0x03, 0x00, 0x80,
0xf6, 0x90, 0x03, 0x27, 0xe5, 0x24, 0xf0, 0x90, 0x00, 0x0f, 0xe0,
0x30, 0xe1, 0x04, 0x30, 0x0e, 0xf6, 0x22, 0x30, 0x0b, 0x07, 0xe4,
0x90, 0x02, 0x02, 0xf0, 0x80, 0x06, 0x90, 0x02, 0x02, 0x74, 0x20,
0xf0, 0x90, 0x02, 0x01, 0x74, 0x21, 0xf0, 0x75, 0x24, 0x03, 0x80,
0x3d, 0xe5, 0x35, 0xa2, 0xe7, 0x13, 0xfe, 0xe5, 0x36, 0x13, 0xfd,
0xac, 0x06, 0x90, 0x02, 0x01, 0xe0, 0x30, 0xe0, 0x03, 0x00, 0x80,
0xf6, 0x90, 0x03, 0x27, 0xe5, 0x24, 0xf0, 0x90, 0x00, 0x0f, 0xe0,
0x30, 0xe1, 0x04, 0x30, 0x0e, 0xf6, 0x22, 0x7f, 0x25, 0x12, 0x10,
0x20, 0xe5, 0x36, 0xb5, 0x3a, 0x08, 0xe5, 0x35, 0xb5, 0x39, 0x03,
0x00, 0x80, 0x04, 0xe4, 0xf5, 0x3b, 0x22, 0xc3, 0xe5, 0x36, 0x95,
0x3a, 0xf5, 0x36, 0xe5, 0x35, 0x95, 0x39, 0xf5, 0x35, 0x02, 0x12,
0x96, 0x22, 0x75, 0xa8, 0x0f, 0x90, 0x03, 0x06, 0x74, 0x01, 0xf0,
0x90, 0x03, 0x07, 0xf0, 0x90, 0x03, 0x08, 0x04, 0xf0, 0x90, 0x03,
0x09, 0x74, 0x6c, 0xf0, 0x90, 0x03, 0x0a, 0x74, 0xff, 0xf0, 0x90,
0x03, 0x02, 0x74, 0x1f, 0xf0, 0x90, 0x03, 0x00, 0x74, 0x04, 0xf0,
0x90, 0x03, 0x25, 0x74, 0x31, 0xf0, 0xd2, 0xaf, 0x22, 0x00, 0x22,
0x00, 0x22, 0x90, 0x03, 0x05, 0xe0, 0x30, 0xe0, 0x0b, 0xe0, 0x44,
0x01, 0xf0, 0x30, 0x09, 0x02, 0xd2, 0x04, 0xc2, 0x07, 0x22, 0x8d,
0x24, 0xa9, 0x07, 0x90, 0x7f, 0xfc, 0xe0, 0x75, 0x25, 0x00, 0xf5,
0x26, 0xa3, 0xe0, 0x75, 0x27, 0x00, 0xf5, 0x28, 0xa3, 0xe0, 0xff,
0xa3, 0xe0, 0xfd, 0xe9, 0x30, 0xe5, 0x14, 0x54, 0xc0, 0x60, 0x05,
0x43, 0x05, 0x03, 0x80, 0x03, 0x53, 0x05, 0xfc, 0xef, 0x54, 0x3f,
0x44, 0x40, 0xff, 0x80, 0x06, 0x53, 0x07, 0x3f, 0x53, 0x05, 0xf0,
0xe5, 0x24, 0x30, 0xe0, 0x05, 0x43, 0x05, 0x10, 0x80, 0x03, 0x53,
0x05, 0xef, 0x90, 0x7f, 0xfc, 0xe5, 0x26, 0xf0, 0xa3, 0xe5, 0x28,
0xf0, 0xa3, 0xef, 0xf0, 0xa3, 0xed, 0xf0, 0x22, 0x8f, 0x24, 0xa9,
0x05, 0x90, 0x7f, 0xfc, 0xe0, 0x75, 0x25, 0x00, 0xf5, 0x26, 0xa3,
0xe0, 0x75, 0x27, 0x00, 0xf5, 0x28, 0xa3, 0xe0, 0xff, 0xa3, 0xe0,
0xfd, 0xe5, 0x24, 0x30, 0xe5, 0x0b, 0x43, 0x05, 0x0f, 0xef, 0x54,
0x3f, 0x44, 0x40, 0xff, 0x80, 0x06, 0x53, 0x05, 0xf0, 0x53, 0x07,
0x3f, 0xe9, 0x30, 0xe0, 0x05, 0x43, 0x05, 0x10, 0x80, 0x03, 0x53,
0x05, 0xef, 0x90, 0x7f, 0xfc, 0xe5, 0x26, 0xf0, 0xa3, 0xe5, 0x28,
0xf0, 0xa3, 0xef, 0xf0, 0xa3, 0xed, 0xf0, 0x22, 0x90, 0x7f, 0xfc,
0xe0, 0xf9, 0xa3, 0xe0, 0xfe, 0xa3, 0xe0, 0xfc, 0xa3, 0xe0, 0xfb,
0xef, 0x30, 0xe5, 0x0b, 0x43, 0x03, 0x0f, 0xec, 0x54, 0x3f, 0x44,
0x40, 0xfc, 0x80, 0x06, 0x53, 0x03, 0xf0, 0x53, 0x04, 0x3f, 0xed,
0x30, 0xe0, 0x07, 0xef, 0x54, 0xc0, 0x60, 0x07, 0x80, 0x0a, 0xef,
0x54, 0xc0, 0x60, 0x05, 0x43, 0x03, 0x10, 0x80, 0x03, 0x53, 0x03,
0xef, 0x90, 0x7f, 0xfc, 0xe9, 0xf0, 0xa3, 0xee, 0xf0, 0xa3, 0xec,
0xf0, 0xa3, 0xeb, 0xf0, 0x22, 0xe5, 0x4b, 0xfd, 0x54, 0x1f, 0x90,
0x7f, 0xf8, 0xf0, 0xe5, 0x4a, 0xf5, 0x09, 0x90, 0x30, 0x38, 0xe0,
0x90, 0x7f, 0xfc, 0xf0, 0x90, 0x30, 0x39, 0xe0, 0x90, 0x7f, 0xfd,
0xf0, 0x90, 0x30, 0x3a, 0xe0, 0x90, 0x7f, 0xfe, 0xf0, 0x90, 0x30,
0x3b, 0xe0, 0x90, 0x7f, 0xff, 0xf0, 0xed, 0x30, 0xe5, 0x0c, 0x54,
0xc0, 0x60, 0x0d, 0x90, 0x7f, 0xf0, 0xe5, 0x47, 0xf0, 0x80, 0x05,
0xe4, 0x90, 0x7f, 0xf0, 0xf0, 0x90, 0x7f, 0xf8, 0xe0, 0x14, 0x60,
0x08, 0x24, 0xfe, 0x60, 0x0d, 0x24, 0x03, 0x80, 0x12, 0xaf, 0x05,
0xad, 0x09, 0x12, 0x13, 0xc5, 0x80, 0x10, 0xaf, 0x05, 0xad, 0x09,
0x12, 0x14, 0x12, 0x80, 0x07, 0xaf, 0x05, 0xad, 0x09, 0x12, 0x13,
0x6f, 0x90, 0x7f, 0xfc, 0xe0, 0x90, 0x30, 0x38, 0xf0, 0x90, 0x7f,
0xfd, 0xe0, 0x90, 0x30, 0x39, 0xf0, 0x90, 0x7f, 0xfe, 0xe0, 0x90,
0x30, 0x3a, 0xf0, 0x90, 0x7f, 0xff, 0xe0, 0x90, 0x30, 0x3b, 0xf0,
0x22, 0xe5, 0x4b, 0x64, 0x01, 0x60, 0x03, 0x02, 0x15, 0x71, 0xf5,
0x4b, 0xe5, 0x44, 0x45, 0x43, 0x70, 0x03, 0x02, 0x15, 0xa0, 0x12,
0x0c, 0x14, 0x12, 0x0b, 0x86, 0x50, 0xfb, 0x90, 0x00, 0x00, 0xe0,
0xf5, 0x25, 0x12, 0x15, 0xb4, 0xc2, 0x92, 0xe4, 0xf5, 0x24, 0xe5,
0x24, 0xc3, 0x95, 0x25, 0x50, 0x49, 0x7e, 0x00, 0x7f, 0x4c, 0x74,
0x40, 0x25, 0x24, 0xf5, 0x82, 0xe4, 0x34, 0x01, 0xad, 0x82, 0xfc,
0x75, 0x2b, 0x02, 0x7b, 0x10, 0x12, 0x07, 0x1e, 0xc2, 0x93, 0x12,
0x15, 0xa1, 0x7d, 0xa0, 0x12, 0x15, 0xd0, 0xe5, 0x24, 0x54, 0x0f,
0x24, 0x4c, 0xf8, 0xe6, 0xfd, 0xaf, 0x4b, 0xae, 0x4a, 0x12, 0x15,
0xd8, 0x05, 0x4b, 0xe5, 0x4b, 0x70, 0x02, 0x05, 0x4a, 0x12, 0x0a,
0x5f, 0x05, 0x24, 0xe5, 0x24, 0x54, 0x0f, 0x70, 0xd5, 0xd2, 0x93,
0x80, 0xb0, 0xc3, 0xe5, 0x44, 0x95, 0x25, 0xf5, 0x44, 0xe5, 0x43,
0x94, 0x00, 0xf5, 0x43, 0x02, 0x14, 0xf2, 0x12, 0x15, 0xb4, 0xc2,
0x93, 0xc2, 0x92, 0x12, 0x15, 0xa1, 0x7d, 0x80, 0x12, 0x15, 0xd0,
0x7d, 0xaa, 0x74, 0x55, 0xff, 0xfe, 0x12, 0x15, 0xd8, 0x7d, 0x55,
0x7f, 0xaa, 0x7e, 0x2a, 0x12, 0x15, 0xd8, 0x7d, 0x30, 0xaf, 0x4b,
0xae, 0x4a, 0x12, 0x15, 0xd8, 0x12, 0x0a, 0x5f, 0xd2, 0x93, 0x22,
0x7d, 0xaa, 0x74, 0x55, 0xff, 0xfe, 0x12, 0x15, 0xd8, 0x7d, 0x55,
0x7f, 0xaa, 0x7e, 0x2a, 0x12, 0x15, 0xd8, 0x22, 0xad, 0x47, 0x7f,
0x34, 0x7e, 0x30, 0x12, 0x15, 0xd8, 0x7d, 0xff, 0x7f, 0x35, 0x7e,
0x30, 0x12, 0x15, 0xd8, 0xe4, 0xfd, 0x7f, 0x37, 0x7e, 0x30, 0x12,
0x15, 0xd8, 0x22, 0x74, 0x55, 0xff, 0xfe, 0x12, 0x15, 0xd8, 0x22,
0x8f, 0x82, 0x8e, 0x83, 0xed, 0xf0, 0x22, 0xe4, 0xfc, 0x90, 0x7f,
0xf0, 0xe0, 0xaf, 0x09, 0x14, 0x60, 0x14, 0x14, 0x60, 0x15, 0x14,
0x60, 0x16, 0x14, 0x60, 0x17, 0x14, 0x60, 0x18, 0x24, 0x05, 0x70,
0x16, 0xe4, 0xfc, 0x80, 0x12, 0x7c, 0x01, 0x80, 0x0e, 0x7c, 0x03,
0x80, 0x0a, 0x7c, 0x07, 0x80, 0x06, 0x7c, 0x0f, 0x80, 0x02, 0x7c,
0x1f, 0xec, 0x6f, 0xf4, 0x54, 0x1f, 0xfc, 0x90, 0x30, 0x34, 0xe0,
0x54, 0xe0, 0x4c, 0xfd, 0xa3, 0xe0, 0xfc, 0x43, 0x04, 0x1f, 0x7f,
0x34, 0x7e, 0x30, 0x12, 0x15, 0xd8, 0xad, 0x04, 0x0f, 0x12, 0x15,
0xd8, 0xe4, 0xfd, 0x7f, 0x37, 0x02, 0x15, 0xd8, 0x02, 0x15, 0xdf,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x07,
0x29, 0xe9
};

View File

@ -0,0 +1,18 @@
Copyright (c) 2005-2006, Ralink Technology Corp.
Paul Lin <paul_lin@ralinktech.com.tw>
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.
The following files are under the above license:
rum-rt2573

Binary file not shown.

View File

@ -1,4 +1,4 @@
# $NetBSD: files.usb,v 1.71 2006/10/24 21:03:30 drochner Exp $
# $NetBSD: files.usb,v 1.72 2006/10/31 22:21:17 joerg Exp $
#
# Config file and device description for machine-independent USB code.
# Included by ports that need it. Ports that use it must provide
@ -259,6 +259,10 @@ file dev/usb/if_atu.c atu
attach ral at usbdevif with ural
file dev/usb/if_ural.c ural
device rum: ether, ifnet, arp, wlan
attach rum at usbdevif
file dev/usb/if_rum.c rum
# Topfield digital PVRs
device utoppy
attach utoppy at usbdevif

2241
sys/dev/usb/if_rum.c Normal file

File diff suppressed because it is too large Load Diff

390
sys/dev/usb/if_rumreg.h Normal file
View File

@ -0,0 +1,390 @@
/* $OpenBSD: if_rumreg.h,v 1.12 2006/08/09 08:21:08 damien Exp $ */
/*-
* Copyright (c) 2005, 2006 Damien Bergamini <damien.bergamini@free.fr>
* Copyright (c) 2006 Niall O'Higgins <niallo@openbsd.org>
*
* 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.
*/
#define RT2573_TX_DESC_SIZE (sizeof (struct rum_tx_desc))
#define RT2573_RX_DESC_SIZE (sizeof (struct rum_rx_desc))
#define RT2573_CONFIG_NO 1
#define RT2573_IFACE_INDEX 0
#define RT2573_MCU_CNTL 0x01
#define RT2573_WRITE_MAC 0x02
#define RT2573_READ_MAC 0x03
#define RT2573_WRITE_MULTI_MAC 0x06
#define RT2573_READ_MULTI_MAC 0x07
#define RT2573_READ_EEPROM 0x09
#define RT2573_WRITE_LED 0x0a
/*
* Control and status registers.
*/
#define RT2573_AIFSN_CSR 0x0400
#define RT2573_CWMIN_CSR 0x0404
#define RT2573_CWMAX_CSR 0x0408
#define RT2573_MCU_CODE_BASE 0x0800
#define RT2573_HW_BEACON_BASE0 0x2400
#define RT2573_MAC_CSR0 0x3000
#define RT2573_MAC_CSR1 0x3004
#define RT2573_MAC_CSR2 0x3008
#define RT2573_MAC_CSR3 0x300c
#define RT2573_MAC_CSR4 0x3010
#define RT2573_MAC_CSR5 0x3014
#define RT2573_MAC_CSR6 0x3018
#define RT2573_MAC_CSR7 0x301c
#define RT2573_MAC_CSR8 0x3020
#define RT2573_MAC_CSR9 0x3024
#define RT2573_MAC_CSR10 0x3028
#define RT2573_MAC_CSR11 0x302c
#define RT2573_MAC_CSR12 0x3030
#define RT2573_MAC_CSR13 0x3034
#define RT2573_MAC_CSR14 0x3038
#define RT2573_MAC_CSR15 0x303c
#define RT2573_TXRX_CSR0 0x3040
#define RT2573_TXRX_CSR1 0x3044
#define RT2573_TXRX_CSR2 0x3048
#define RT2573_TXRX_CSR3 0x304c
#define RT2573_TXRX_CSR4 0x3050
#define RT2573_TXRX_CSR5 0x3054
#define RT2573_TXRX_CSR6 0x3058
#define RT2573_TXRX_CSR7 0x305c
#define RT2573_TXRX_CSR8 0x3060
#define RT2573_TXRX_CSR9 0x3064
#define RT2573_TXRX_CSR10 0x3068
#define RT2573_TXRX_CSR11 0x306c
#define RT2573_TXRX_CSR12 0x3070
#define RT2573_TXRX_CSR13 0x3074
#define RT2573_TXRX_CSR14 0x3078
#define RT2573_TXRX_CSR15 0x307c
#define RT2573_PHY_CSR0 0x3080
#define RT2573_PHY_CSR1 0x3084
#define RT2573_PHY_CSR2 0x3088
#define RT2573_PHY_CSR3 0x308c
#define RT2573_PHY_CSR4 0x3090
#define RT2573_PHY_CSR5 0x3094
#define RT2573_PHY_CSR6 0x3098
#define RT2573_PHY_CSR7 0x309c
#define RT2573_SEC_CSR0 0x30a0
#define RT2573_SEC_CSR1 0x30a4
#define RT2573_SEC_CSR2 0x30a8
#define RT2573_SEC_CSR3 0x30ac
#define RT2573_SEC_CSR4 0x30b0
#define RT2573_SEC_CSR5 0x30b4
#define RT2573_STA_CSR0 0x30c0
#define RT2573_STA_CSR1 0x30c4
#define RT2573_STA_CSR2 0x30c8
#define RT2573_STA_CSR3 0x30cc
#define RT2573_STA_CSR4 0x30d0
#define RT2573_STA_CSR5 0x30d4
/* possible flags for register RT2573_MAC_CSR1 */
#define RT2573_RESET_ASIC (1 << 0)
#define RT2573_RESET_BBP (1 << 1)
#define RT2573_HOST_READY (1 << 2)
/* possible flags for register MAC_CSR5 */
#define RT2573_ONE_BSSID 3
/* possible flags for register TXRX_CSR0 */
/* Tx filter flags are in the low 16 bits */
#define RT2573_AUTO_TX_SEQ (1 << 15)
/* Rx filter flags are in the high 16 bits */
#define RT2573_DISABLE_RX (1 << 16)
#define RT2573_DROP_CRC_ERROR (1 << 17)
#define RT2573_DROP_PHY_ERROR (1 << 18)
#define RT2573_DROP_CTL (1 << 19)
#define RT2573_DROP_NOT_TO_ME (1 << 20)
#define RT2573_DROP_TODS (1 << 21)
#define RT2573_DROP_VER_ERROR (1 << 22)
#define RT2573_DROP_MULTICAST (1 << 23)
#define RT2573_DROP_BROADCAST (1 << 24)
#define RT2573_DROP_ACKCTS (1 << 25)
/* possible flags for register TXRX_CSR4 */
#define RT2573_SHORT_PREAMBLE (1 << 18)
#define RT2573_MRR_ENABLED (1 << 19)
#define RT2573_MRR_CCK_FALLBACK (1 << 22)
/* possible flags for register TXRX_CSR9 */
#define RT2573_TSF_TICKING (1 << 16)
#define RT2573_TSF_MODE(x) (((x) & 0x3) << 17)
/* TBTT stands for Target Beacon Transmission Time */
#define RT2573_ENABLE_TBTT (1 << 19)
#define RT2573_GENERATE_BEACON (1 << 20)
/* possible flags for register PHY_CSR0 */
#define RT2573_PA_PE_2GHZ (1 << 16)
#define RT2573_PA_PE_5GHZ (1 << 17)
/* possible flags for register PHY_CSR3 */
#define RT2573_BBP_READ (1 << 15)
#define RT2573_BBP_BUSY (1 << 16)
/* possible flags for register PHY_CSR4 */
#define RT2573_RF_20BIT (20 << 24)
#define RT2573_RF_BUSY (1 << 31)
/* LED values */
#define RT2573_LED_RADIO (1 << 8)
#define RT2573_LED_G (1 << 9)
#define RT2573_LED_A (1 << 10)
#define RT2573_LED_ON 0x1e1e
#define RT2573_LED_OFF 0x0
#define RT2573_MCU_RUN (1 << 3)
#define RT2573_SMART_MODE (1 << 0)
#define RT2573_BBPR94_DEFAULT 6
#define RT2573_BBP_WRITE (1 << 15)
/* dual-band RF */
#define RT2573_RF_5226 1
#define RT2573_RF_5225 3
/* single-band RF */
#define RT2573_RF_2528 2
#define RT2573_RF_2527 4
#define RT2573_BBP_VERSION 0
struct rum_tx_desc {
uint32_t flags;
#define RT2573_TX_BURST (1 << 0)
#define RT2573_TX_VALID (1 << 1)
#define RT2573_TX_MORE_FRAG (1 << 2)
#define RT2573_TX_ACK (1 << 3)
#define RT2573_TX_TIMESTAMP (1 << 4)
#define RT2573_TX_OFDM (1 << 5)
#define RT2573_TX_IFS_SIFS (1 << 6)
#define RT2573_TX_LONG_RETRY (1 << 7)
uint16_t wme;
#define RT2573_QID(v) (v)
#define RT2573_AIFSN(v) ((v) << 4)
#define RT2573_LOGCWMIN(v) ((v) << 8)
#define RT2573_LOGCWMAX(v) ((v) << 12)
uint16_t xflags;
#define RT2573_TX_HWSEQ (1 << 12)
uint8_t plcp_signal;
uint8_t plcp_service;
#define RT2573_PLCP_LENGEXT 0x80
uint8_t plcp_length_lo;
uint8_t plcp_length_hi;
uint32_t iv;
uint32_t eiv;
uint8_t offset;
uint8_t qid;
uint8_t txpower;
#define RT2573_DEFAULT_TXPOWER 0
uint8_t reserved;
} __packed;
struct rum_rx_desc {
uint32_t flags;
#define RT2573_RX_BUSY (1 << 0)
#define RT2573_RX_DROP (1 << 1)
#define RT2573_RX_CRC_ERROR (1 << 6)
#define RT2573_RX_OFDM (1 << 7)
uint8_t rate;
uint8_t rssi;
uint8_t reserved1;
uint8_t offset;
uint32_t iv;
uint32_t eiv;
uint32_t reserved2[2];
} __packed;
#define RT2573_RF1 0
#define RT2573_RF2 2
#define RT2573_RF3 1
#define RT2573_RF4 3
#define RT2573_EEPROM_MACBBP 0x0000
#define RT2573_EEPROM_ADDRESS 0x0004
#define RT2573_EEPROM_ANTENNA 0x0020
#define RT2573_EEPROM_CONFIG2 0x0022
#define RT2573_EEPROM_BBP_BASE 0x0026
#define RT2573_EEPROM_TXPOWER 0x0046
#define RT2573_EEPROM_FREQ_OFFSET 0x005e
#define RT2573_EEPROM_RSSI_2GHZ_OFFSET 0x009a
#define RT2573_EEPROM_RSSI_5GHZ_OFFSET 0x009c
/*
* Default values for MAC registers; values taken from the reference driver.
*/
#define RT2573_DEF_MAC \
{ RT2573_TXRX_CSR0, 0x025fb032 }, \
{ RT2573_TXRX_CSR1, 0x9eaa9eaf }, \
{ RT2573_TXRX_CSR2, 0x8a8b8c8d }, \
{ RT2573_TXRX_CSR3, 0x00858687 }, \
{ RT2573_TXRX_CSR7, 0x2e31353b }, \
{ RT2573_TXRX_CSR8, 0x2a2a2a2c }, \
{ RT2573_TXRX_CSR15, 0x0000000f }, \
{ RT2573_MAC_CSR6, 0x00000fff }, \
{ RT2573_MAC_CSR8, 0x016c030a }, \
{ RT2573_MAC_CSR10, 0x00000718 }, \
{ RT2573_MAC_CSR12, 0x00000004 }, \
{ RT2573_MAC_CSR13, 0x00007f00 }, \
{ RT2573_SEC_CSR0, 0x00000000 }, \
{ RT2573_SEC_CSR1, 0x00000000 }, \
{ RT2573_SEC_CSR5, 0x00000000 }, \
{ RT2573_PHY_CSR1, 0x000023b0 }, \
{ RT2573_PHY_CSR5, 0x00040a06 }, \
{ RT2573_PHY_CSR6, 0x00080606 }, \
{ RT2573_PHY_CSR7, 0x00000408 }, \
{ RT2573_AIFSN_CSR, 0x00002273 }, \
{ RT2573_CWMIN_CSR, 0x00002344 }, \
{ RT2573_CWMAX_CSR, 0x000034aa }
/*
* Default values for BBP registers; values taken from the reference driver.
*/
#define RT2573_DEF_BBP \
{ 3, 0x80 }, \
{ 15, 0x30 }, \
{ 17, 0x20 }, \
{ 21, 0xc8 }, \
{ 22, 0x38 }, \
{ 23, 0x06 }, \
{ 24, 0xfe }, \
{ 25, 0x0a }, \
{ 26, 0x0d }, \
{ 32, 0x0b }, \
{ 34, 0x12 }, \
{ 37, 0x07 }, \
{ 39, 0xf8 }, \
{ 41, 0x60 }, \
{ 53, 0x10 }, \
{ 54, 0x18 }, \
{ 60, 0x10 }, \
{ 61, 0x04 }, \
{ 62, 0x04 }, \
{ 75, 0xfe }, \
{ 86, 0xfe }, \
{ 88, 0xfe }, \
{ 90, 0x0f }, \
{ 99, 0x00 }, \
{ 102, 0x16 }, \
{ 107, 0x04 }
/*
* Default settings for RF registers; values taken from the reference driver.
*/
#define RT2573_RF5226 \
{ 1, 0x00b03, 0x001e1, 0x1a014, 0x30282 }, \
{ 2, 0x00b03, 0x001e1, 0x1a014, 0x30287 }, \
{ 3, 0x00b03, 0x001e2, 0x1a014, 0x30282 }, \
{ 4, 0x00b03, 0x001e2, 0x1a014, 0x30287 }, \
{ 5, 0x00b03, 0x001e3, 0x1a014, 0x30282 }, \
{ 6, 0x00b03, 0x001e3, 0x1a014, 0x30287 }, \
{ 7, 0x00b03, 0x001e4, 0x1a014, 0x30282 }, \
{ 8, 0x00b03, 0x001e4, 0x1a014, 0x30287 }, \
{ 9, 0x00b03, 0x001e5, 0x1a014, 0x30282 }, \
{ 10, 0x00b03, 0x001e5, 0x1a014, 0x30287 }, \
{ 11, 0x00b03, 0x001e6, 0x1a014, 0x30282 }, \
{ 12, 0x00b03, 0x001e6, 0x1a014, 0x30287 }, \
{ 13, 0x00b03, 0x001e7, 0x1a014, 0x30282 }, \
{ 14, 0x00b03, 0x001e8, 0x1a014, 0x30284 }, \
\
{ 34, 0x00b03, 0x20266, 0x36014, 0x30282 }, \
{ 38, 0x00b03, 0x20267, 0x36014, 0x30284 }, \
{ 42, 0x00b03, 0x20268, 0x36014, 0x30286 }, \
{ 46, 0x00b03, 0x20269, 0x36014, 0x30288 }, \
\
{ 36, 0x00b03, 0x00266, 0x26014, 0x30288 }, \
{ 40, 0x00b03, 0x00268, 0x26014, 0x30280 }, \
{ 44, 0x00b03, 0x00269, 0x26014, 0x30282 }, \
{ 48, 0x00b03, 0x0026a, 0x26014, 0x30284 }, \
{ 52, 0x00b03, 0x0026b, 0x26014, 0x30286 }, \
{ 56, 0x00b03, 0x0026c, 0x26014, 0x30288 }, \
{ 60, 0x00b03, 0x0026e, 0x26014, 0x30280 }, \
{ 64, 0x00b03, 0x0026f, 0x26014, 0x30282 }, \
\
{ 100, 0x00b03, 0x0028a, 0x2e014, 0x30280 }, \
{ 104, 0x00b03, 0x0028b, 0x2e014, 0x30282 }, \
{ 108, 0x00b03, 0x0028c, 0x2e014, 0x30284 }, \
{ 112, 0x00b03, 0x0028d, 0x2e014, 0x30286 }, \
{ 116, 0x00b03, 0x0028e, 0x2e014, 0x30288 }, \
{ 120, 0x00b03, 0x002a0, 0x2e014, 0x30280 }, \
{ 124, 0x00b03, 0x002a1, 0x2e014, 0x30282 }, \
{ 128, 0x00b03, 0x002a2, 0x2e014, 0x30284 }, \
{ 132, 0x00b03, 0x002a3, 0x2e014, 0x30286 }, \
{ 136, 0x00b03, 0x002a4, 0x2e014, 0x30288 }, \
{ 140, 0x00b03, 0x002a6, 0x2e014, 0x30280 }, \
\
{ 149, 0x00b03, 0x002a8, 0x2e014, 0x30287 }, \
{ 153, 0x00b03, 0x002a9, 0x2e014, 0x30289 }, \
{ 157, 0x00b03, 0x002ab, 0x2e014, 0x30281 }, \
{ 161, 0x00b03, 0x002ac, 0x2e014, 0x30283 }, \
{ 165, 0x00b03, 0x002ad, 0x2e014, 0x30285 }
#define RT2573_RF5225 \
{ 1, 0x00b33, 0x011e1, 0x1a014, 0x30282 }, \
{ 2, 0x00b33, 0x011e1, 0x1a014, 0x30287 }, \
{ 3, 0x00b33, 0x011e2, 0x1a014, 0x30282 }, \
{ 4, 0x00b33, 0x011e2, 0x1a014, 0x30287 }, \
{ 5, 0x00b33, 0x011e3, 0x1a014, 0x30282 }, \
{ 6, 0x00b33, 0x011e3, 0x1a014, 0x30287 }, \
{ 7, 0x00b33, 0x011e4, 0x1a014, 0x30282 }, \
{ 8, 0x00b33, 0x011e4, 0x1a014, 0x30287 }, \
{ 9, 0x00b33, 0x011e5, 0x1a014, 0x30282 }, \
{ 10, 0x00b33, 0x011e5, 0x1a014, 0x30287 }, \
{ 11, 0x00b33, 0x011e6, 0x1a014, 0x30282 }, \
{ 12, 0x00b33, 0x011e6, 0x1a014, 0x30287 }, \
{ 13, 0x00b33, 0x011e7, 0x1a014, 0x30282 }, \
{ 14, 0x00b33, 0x011e8, 0x1a014, 0x30284 }, \
\
{ 34, 0x00b33, 0x01266, 0x26014, 0x30282 }, \
{ 38, 0x00b33, 0x01267, 0x26014, 0x30284 }, \
{ 42, 0x00b33, 0x01268, 0x26014, 0x30286 }, \
{ 46, 0x00b33, 0x01269, 0x26014, 0x30288 }, \
\
{ 36, 0x00b33, 0x01266, 0x26014, 0x30288 }, \
{ 40, 0x00b33, 0x01268, 0x26014, 0x30280 }, \
{ 44, 0x00b33, 0x01269, 0x26014, 0x30282 }, \
{ 48, 0x00b33, 0x0126a, 0x26014, 0x30284 }, \
{ 52, 0x00b33, 0x0126b, 0x26014, 0x30286 }, \
{ 56, 0x00b33, 0x0126c, 0x26014, 0x30288 }, \
{ 60, 0x00b33, 0x0126e, 0x26014, 0x30280 }, \
{ 64, 0x00b33, 0x0126f, 0x26014, 0x30282 }, \
\
{ 100, 0x00b33, 0x0128a, 0x2e014, 0x30280 }, \
{ 104, 0x00b33, 0x0128b, 0x2e014, 0x30282 }, \
{ 108, 0x00b33, 0x0128c, 0x2e014, 0x30284 }, \
{ 112, 0x00b33, 0x0128d, 0x2e014, 0x30286 }, \
{ 116, 0x00b33, 0x0128e, 0x2e014, 0x30288 }, \
{ 120, 0x00b33, 0x012a0, 0x2e014, 0x30280 }, \
{ 124, 0x00b33, 0x012a1, 0x2e014, 0x30282 }, \
{ 128, 0x00b33, 0x012a2, 0x2e014, 0x30284 }, \
{ 132, 0x00b33, 0x012a3, 0x2e014, 0x30286 }, \
{ 136, 0x00b33, 0x012a4, 0x2e014, 0x30288 }, \
{ 140, 0x00b33, 0x012a6, 0x2e014, 0x30280 }, \
\
{ 149, 0x00b33, 0x012a8, 0x2e014, 0x30287 }, \
{ 153, 0x00b33, 0x012a9, 0x2e014, 0x30289 }, \
{ 157, 0x00b33, 0x012ab, 0x2e014, 0x30281 }, \
{ 161, 0x00b33, 0x012ac, 0x2e014, 0x30283 }, \
{ 165, 0x00b33, 0x012ad, 0x2e014, 0x30285 }

153
sys/dev/usb/if_rumvar.h Normal file
View File

@ -0,0 +1,153 @@
/* $OpenBSD: if_rumvar.h,v 1.6 2006/08/18 15:11:12 damien Exp $ */
/*-
* Copyright (c) 2005, 2006 Damien Bergamini <damien.bergamini@free.fr>
* Copyright (c) 2006 Niall O'Higgins <niallo@openbsd.org>
*
* 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.
*/
#define RT2573_RX_LIST_COUNT 1
#define RT2573_TX_LIST_COUNT 1
struct rum_rx_radiotap_header {
struct ieee80211_radiotap_header wr_ihdr;
uint8_t wr_flags;
uint8_t wr_rate;
uint16_t wr_chan_freq;
uint16_t wr_chan_flags;
uint8_t wr_antenna;
uint8_t wr_antsignal;
} __packed;
#define RT2573_RX_RADIOTAP_PRESENT \
((1 << IEEE80211_RADIOTAP_FLAGS) | \
(1 << IEEE80211_RADIOTAP_RATE) | \
(1 << IEEE80211_RADIOTAP_CHANNEL) | \
(1 << IEEE80211_RADIOTAP_ANTENNA) | \
(1 << IEEE80211_RADIOTAP_DB_ANTSIGNAL))
struct rum_tx_radiotap_header {
struct ieee80211_radiotap_header wt_ihdr;
uint8_t wt_flags;
uint8_t wt_rate;
uint16_t wt_chan_freq;
uint16_t wt_chan_flags;
uint8_t wt_antenna;
} __packed;
#define RT2573_TX_RADIOTAP_PRESENT \
((1 << IEEE80211_RADIOTAP_FLAGS) | \
(1 << IEEE80211_RADIOTAP_RATE) | \
(1 << IEEE80211_RADIOTAP_CHANNEL) | \
(1 << IEEE80211_RADIOTAP_ANTENNA))
struct rum_softc;
struct rum_tx_data {
struct rum_softc *sc;
usbd_xfer_handle xfer;
uint8_t *buf;
struct mbuf *m;
struct ieee80211_node *ni;
};
struct rum_rx_data {
struct rum_softc *sc;
usbd_xfer_handle xfer;
uint8_t *buf;
struct mbuf *m;
};
struct rum_softc {
USBBASEDEVICE sc_dev;
struct ethercom sc_ec;
#define sc_if sc_ec.ec_if
struct ieee80211com sc_ic;
int (*sc_newstate)(struct ieee80211com *,
enum ieee80211_state, int);
usbd_device_handle sc_udev;
usbd_interface_handle sc_iface;
int sc_flags;
#define RT2573_FWLOADED (1 << 0)
struct ieee80211_channel *sc_curchan;
int sc_rx_no;
int sc_tx_no;
uint16_t macbbp_rev;
uint8_t rf_rev;
uint8_t rffreq;
usbd_xfer_handle amrr_xfer;
usbd_pipe_handle sc_rx_pipeh;
usbd_pipe_handle sc_tx_pipeh;
enum ieee80211_state sc_state;
struct usb_task sc_task;
struct ieee80211_amrr amrr;
struct ieee80211_amrr_node amn;
struct rum_rx_data rx_data[RT2573_RX_LIST_COUNT];
struct rum_tx_data tx_data[RT2573_TX_LIST_COUNT];
int tx_queued;
struct ieee80211_beacon_offsets sc_bo;
struct callout scan_ch;
struct callout amrr_ch;
int sc_tx_timer;
uint32_t sta[6];
uint32_t rf_regs[4];
uint8_t txpow[44];
struct {
uint8_t val;
uint8_t reg;
} __packed bbp_prom[16];
int hw_radio;
int rx_ant;
int tx_ant;
int nb_ant;
int ext_2ghz_lna;
int ext_5ghz_lna;
int rssi_2ghz_corr;
int rssi_5ghz_corr;
int sifs;
uint8_t bbp17;
#if NBPFILTER > 0
caddr_t sc_drvbpf;
union {
struct rum_rx_radiotap_header th;
uint8_t pad[64];
} sc_rxtapu;
#define sc_rxtap sc_rxtapu.th
int sc_rxtap_len;
union {
struct rum_tx_radiotap_header th;
uint8_t pad[64];
} sc_txtapu;
#define sc_txtap sc_txtapu.th
int sc_txtap_len;
#endif
};