PERFORCE change 50236 for review
Peter Wemm
peter at FreeBSD.org
Fri Apr 2 21:33:05 PST 2004
http://perforce.freebsd.org/chv.cgi?CH=50236
Change 50236 by peter at peter_overcee on 2004/04/02 21:33:02
IFC @50231
Affected files ...
.. //depot/projects/hammer/etc/defaults/rc.conf#24 integrate
.. //depot/projects/hammer/etc/newsyslog.conf#8 integrate
.. //depot/projects/hammer/etc/rc.d/Makefile#21 integrate
.. //depot/projects/hammer/etc/rc.d/hostname#6 integrate
.. //depot/projects/hammer/etc/rc.d/network#3 integrate
.. //depot/projects/hammer/etc/rc.d/pf#2 integrate
.. //depot/projects/hammer/etc/rc.d/pflog#1 branch
.. //depot/projects/hammer/lib/libalias/alias.c#7 integrate
.. //depot/projects/hammer/release/doc/en_US.ISO8859-1/hardware/common/dev.sgml#48 integrate
.. //depot/projects/hammer/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#63 integrate
.. //depot/projects/hammer/share/man/man5/rc.conf.5#24 integrate
.. //depot/projects/hammer/sys/conf/NOTES#41 integrate
.. //depot/projects/hammer/sys/dev/ath/if_ath.c#19 integrate
.. //depot/projects/hammer/sys/dev/ath/if_ath_pci.c#8 integrate
.. //depot/projects/hammer/sys/dev/ath/if_athioctl.h#5 integrate
.. //depot/projects/hammer/sys/dev/ath/if_athvar.h#9 integrate
.. //depot/projects/hammer/sys/dev/kbd/kbd.c#8 integrate
.. //depot/projects/hammer/sys/dev/syscons/syscons.c#15 integrate
.. //depot/projects/hammer/sys/dev/twa/twa.c#2 integrate
.. //depot/projects/hammer/sys/dev/twa/twa_freebsd.c#2 integrate
.. //depot/projects/hammer/sys/dev/twa/twa_includes.h#2 integrate
.. //depot/projects/hammer/sys/dev/uart/uart_cpu_sparc64.c#7 integrate
.. //depot/projects/hammer/sys/dev/uart/uart_dev_ns8250.c#3 integrate
.. //depot/projects/hammer/sys/dev/uart/uart_kbd_sun.c#2 integrate
.. //depot/projects/hammer/sys/i386/conf/NOTES#37 integrate
.. //depot/projects/hammer/sys/kern/kern_thr.c#14 integrate
.. //depot/projects/hammer/sys/net/if_sl.c#8 integrate
.. //depot/projects/hammer/sys/net80211/ieee80211.c#9 integrate
.. //depot/projects/hammer/sys/net80211/ieee80211_input.c#9 integrate
.. //depot/projects/hammer/sys/net80211/ieee80211_node.c#12 integrate
.. //depot/projects/hammer/sys/net80211/ieee80211_node.h#7 integrate
.. //depot/projects/hammer/sys/net80211/ieee80211_output.c#7 integrate
.. //depot/projects/hammer/sys/net80211/ieee80211_proto.c#8 integrate
.. //depot/projects/hammer/sys/net80211/ieee80211_var.h#10 integrate
.. //depot/projects/hammer/sys/pci/if_rl.c#31 integrate
.. //depot/projects/hammer/sys/pci/if_ste.c#21 integrate
.. //depot/projects/hammer/sys/pci/if_stereg.h#6 integrate
Differences ...
==== //depot/projects/hammer/etc/defaults/rc.conf#24 (text+ko) ====
@@ -13,7 +13,7 @@
#
# All arguments must be in double or single quotes.
#
-# $FreeBSD: src/etc/defaults/rc.conf,v 1.202 2004/03/23 23:22:34 brooks Exp $
+# $FreeBSD: src/etc/defaults/rc.conf,v 1.203 2004/04/02 19:25:27 mlaier Exp $
##############################################################
### Important initial Boot-time options ####################
@@ -107,6 +107,10 @@
pf_rules="/etc/pf.conf" # rules definition file for pf
pf_program="/sbin/pfctl" # where the pfctl program lives
pf_flags="" # additional flags for pfctl
+pflog_enable="NO" # Set to YES to enable packet filter logging
+pflog_logfile="/var/log/pflog" # where pflogd shoule store the logfile
+pflog_program="/sbin/pflogd" # where the pflogd program lives
+pflog_flags="" # additional flags for pflogd
tcp_extensions="YES" # Set to NO to turn off RFC1323 extensions.
log_in_vain="0" # >=1 to log connects to ports w/o listeners.
tcp_keepalive="YES" # Enable stale TCP connection timeout (or NO).
==== //depot/projects/hammer/etc/newsyslog.conf#8 (text+ko) ====
@@ -1,5 +1,5 @@
# configuration file for newsyslog
-# $FreeBSD: src/etc/newsyslog.conf,v 1.47 2003/08/07 21:04:40 fjoe Exp $
+# $FreeBSD: src/etc/newsyslog.conf,v 1.48 2004/04/02 19:25:27 mlaier Exp $
#
# Entries which do not specify the '/pid_file' field will cause the
# syslogd process to be signalled when that log file is rotated. This
@@ -36,3 +36,5 @@
/var/log/weekly.log 640 5 1 $W6D0 JN
/var/log/wtmp 644 3 * @01T05 B
/var/log/xferlog 600 7 100 * J
+# pflogd sample entry
+#/var/log/pflog 600 3 100 * JB /var/run/pflogd.pid
==== //depot/projects/hammer/etc/rc.d/Makefile#21 (text+ko) ====
@@ -1,5 +1,5 @@
# $NetBSD: Makefile,v 1.16 2001/01/14 15:37:22 minoura Exp $
-# $FreeBSD: src/etc/rc.d/Makefile,v 1.37 2004/03/24 21:54:44 mlaier Exp $
+# $FreeBSD: src/etc/rc.d/Makefile,v 1.38 2004/04/02 19:25:27 mlaier Exp $
FILES= DAEMON LOGIN NETWORKING SERVERS \
abi accounting addswap adjkerntz amd \
@@ -25,7 +25,7 @@
network_ipv6 nfsclient nfsd \
nfslocking nfsserver nisdomain ntpd ntpdate \
othermta \
- pccard pcvt pf power_profile ppp-user pppoed pwcheck \
+ pccard pcvt pf pflog power_profile ppp-user pppoed pwcheck \
quota \
random rarpd rcconf.sh resolv root \
route6d routed routing rpcbind rtadvd rwho \
==== //depot/projects/hammer/etc/rc.d/hostname#6 (text+ko) ====
@@ -23,7 +23,7 @@
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
# SUCH DAMAGE.
#
-# $FreeBSD: src/etc/rc.d/hostname,v 1.6 2004/03/23 23:22:34 brooks Exp $
+# $FreeBSD: src/etc/rc.d/hostname,v 1.7 2004/04/02 12:18:40 krion Exp $
#
# PROVIDE: hostname
@@ -47,7 +47,7 @@
if [ `$SYSCTL_N security.jail.set_hostname_allowed` -eq 0 ]; then
return
fi
- elif [ -n "`hostname -s`" ]; then
+ elif [ -n "`/bin/hostname -s`" ]; then
return
else
# If we're not in a jail and rc.conf doesn't specify a
@@ -59,7 +59,7 @@
fi
fi
- hostname ${hostname}
+ /bin/hostname ${hostname}
echo "Setting hostname: `hostname`."
}
==== //depot/projects/hammer/etc/rc.d/network#3 (text+ko) ====
@@ -1,7 +1,7 @@
#!/bin/sh
#
# $NetBSD: network,v 1.29 2001/01/11 17:56:16 itojun Exp $
-# $FreeBSD: src/etc/rc.d/network,v 1.3 2002/08/12 10:04:32 schweikh Exp $
+# $FreeBSD: src/etc/rc.d/network,v 1.4 2004/04/02 12:18:40 krion Exp $
# PROVIDE: network
# REQUIRE: ipfilter ipsec mountcritlocal root tty sysctl
@@ -26,13 +26,13 @@
fi
if [ -n "$hostname" ]; then
echo "Hostname: $hostname"
- hostname $hostname
+ /bin/hostname $hostname
else
# Don't warn about it if we're going to run
# DHCP later, as we will probably get the
# hostname at that time.
#
- if ! checkyesno dhclient && [ -z "`hostname`" ]; then
+ if ! checkyesno dhclient && [ -z "`/bin/hostname`" ]; then
warn "\$hostname not set."
fi
fi
==== //depot/projects/hammer/etc/rc.d/pf#2 (text+ko) ====
@@ -1,10 +1,10 @@
#!/bin/sh
#
-# $FreeBSD: src/etc/rc.d/pf,v 1.1 2004/03/23 22:30:15 mlaier Exp $
+# $FreeBSD: src/etc/rc.d/pf,v 1.2 2004/04/02 19:25:27 mlaier Exp $
#
# PROVIDE: pf
-# REQUIRE: root beforenetlkm mountcritlocal netif
+# REQUIRE: root beforenetlkm mountcritlocal netif pflog
# BEFORE: DAEMON LOGIN
# KEYWORD: FreeBSD nojail
==== //depot/projects/hammer/lib/libalias/alias.c#7 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/lib/libalias/alias.c,v 1.41 2004/03/31 21:32:58 des Exp $");
+__FBSDID("$FreeBSD: src/lib/libalias/alias.c,v 1.42 2004/04/02 17:57:57 deischen Exp $");
/*
Alias.c provides supervisory control for the functions of the
@@ -884,6 +884,7 @@
/* Restore original IP address */
accumulate = twowords(&pip->ip_dst);
+ pip->ip_dst = original_address;
accumulate -= twowords(&pip->ip_dst);
/* If this is a transparent proxy packet, then modify the source
==== //depot/projects/hammer/release/doc/en_US.ISO8859-1/hardware/common/dev.sgml#48 (text+ko) ====
@@ -29,7 +29,7 @@
<sect1 id="support">
<sect1info>
- <pubdate>$FreeBSD: src/release/doc/en_US.ISO8859-1/hardware/common/dev.sgml,v 1.214 2004/03/15 00:11:27 bmah Exp $</pubdate>
+ <pubdate>$FreeBSD: src/release/doc/en_US.ISO8859-1/hardware/common/dev.sgml,v 1.215 2004/04/02 17:19:59 rik Exp $</pubdate>
</sect1info>
<title>Supported Devices</title>
@@ -908,6 +908,18 @@
<para arch="i386">Cronyx-Sigma synchronous / asynchronous serial
adapters (&man.cx.4; driver)</para>
+ <para arch="i386">Cronyx-Tau synchronous serial adapters for ISA bus
+ (&man.ctau.4; driver)
+ <itemizedlist>
+ <listitem>
+ <para>Cronyx Tau (RS-232/V.35) and Cronyx Tau/R (RS-530/RS-449)</para>
+ </listitem>
+ <listitem>
+ <para>Cronyx Tau/E1 (fractional E1) and Cronyx Tau/G703 (unframed E1)</para>
+ </listitem>
+ </itemizedlist>
+ </para>
+
<para arch="i386">Granch SBNI12 point-to-point communications
adapters (&man.sbni.4; driver)
</para>
==== //depot/projects/hammer/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#63 (text+ko) ====
@@ -3,7 +3,7 @@
<corpauthor>The FreeBSD Project</corpauthor>
- <pubdate>$FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.704 2004/03/24 18:03:55 hrs Exp $</pubdate>
+ <pubdate>$FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml,v 1.705 2004/04/02 17:35:53 rik Exp $</pubdate>
<copyright>
<year>2000</year>
@@ -169,6 +169,11 @@
<sect2 id="kernel">
<title>Kernel Changes</title>
+ <para arch="i386">The &man.ctau.4; driver has been added for Cronyx-Tau
+ synchronous serial adapters. This driver was known for a long time as "ct"
+ in its previous life outside FreeBSD source tree. Note: only driver name
+ has changed. Network interface still has "ct" name.</para>
+
<para arch="i386">The &man.acpi.toshiba.4; driver has been added
to use Toshiba's Hardware Control Interface to manipulate
certain hardware features on Toshiba laptops.</para>
==== //depot/projects/hammer/share/man/man5/rc.conf.5#24 (text+ko) ====
@@ -22,7 +22,7 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $FreeBSD: src/share/man/man5/rc.conf.5,v 1.211 2004/03/30 15:11:16 des Exp $
+.\" $FreeBSD: src/share/man/man5/rc.conf.5,v 1.212 2004/04/02 19:25:26 mlaier Exp $
.\"
.Dd March 30, 2004
.Dt RC.CONF 5
@@ -718,6 +718,44 @@
these flags are passed to the
.Xr pfctl 8
program when loading the ruleset.
+.It Va pflog_enable
+.Pq Vt bool
+Set to
+.Dq Li NO
+by default.
+Setting this to
+.Dq Li YES
+enables
+.Xr pflogd 8
+which logs packtes from the
+.Xr pf 4
+packet filter.
+.It Va pflog_logfile
+.Pq Vt str
+If
+.Va pflog_enable
+is set to
+.Dq Li YES
+this controls where
+.Xr pflogd 8
+stores the logfile.
+(default
+.Pa /var/log/pflog ) .
+Check
+.Pa /etc/newsyslog.conf
+to enable logfile rotation for this.
+.It Va pflog_program
+.Pq Vt str
+Path to
+.Xr pflogd 8
+(default
+.Pa /sbin/pflogd ) .
+.It Va pflog_flags
+.Pq Vt str
+Empty by default.
+This variable contains additional flags passed to the
+.Xr pflogd 8
+program.
.It Va tcp_extensions
.Pq Vt bool
Set to
@@ -2910,6 +2948,7 @@
.Xr udp 4 ,
.Xr exports 5 ,
.Xr motd 5 ,
+.Xr newsyslog.conf 5 ,
.Xr accton 8 ,
.Xr amd 8 ,
.Xr apm 8 ,
==== //depot/projects/hammer/sys/conf/NOTES#41 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/NOTES,v 1.1211 2004/03/31 18:46:13 vkashyap Exp $
+# $FreeBSD: src/sys/conf/NOTES,v 1.1212 2004/04/02 18:50:56 vkashyap Exp $
#
# NOTES -- Lines that can be cut/pasted into kernel and hints configs.
#
@@ -1388,14 +1388,6 @@
device twe # 3ware ATA RAID
#
-# 3ware 9000 series PATA/SATA RAID controller driver and options.
-# The driver is implemented as a SIM, and so, needs the CAM infrastructure.
-#
-options TWA_DEBUG # 0-10; 10 prints the most messages.
-options TWA_FLASH_FIRMWARE # firmware image bundled when defined.
-device twa # 3ware 9000 series PATA/SATA RAID
-
-#
# The 'ATA' driver supports all ATA and ATAPI devices, including PC Card
# devices. You only need one "device ata" for it to find all
# PCI and PC Card ATA/ATAPI devices on modern machines.
==== //depot/projects/hammer/sys/dev/ath/if_ath.c#19 (text+ko) ====
@@ -1,5 +1,5 @@
/*-
- * Copyright (c) 2002, 2003 Sam Leffler, Errno Consulting
+ * Copyright (c) 2002-2004 Sam Leffler, Errno Consulting
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.47 2004/04/01 00:38:45 sam Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.53 2004/04/03 00:06:23 sam Exp $");
/*
* Driver for the Atheros Wireless LAN controller.
@@ -270,7 +270,6 @@
TASK_INIT(&sc->sc_txtask, 0, ath_tx_proc, sc);
TASK_INIT(&sc->sc_rxtask, 0, ath_rx_proc, sc);
- TASK_INIT(&sc->sc_swbatask, 0, ath_beacon_proc, sc);
TASK_INIT(&sc->sc_rxorntask, 0, ath_rxorn_proc, sc);
TASK_INIT(&sc->sc_fataltask, 0, ath_fatal_proc, sc);
TASK_INIT(&sc->sc_bmisstask, 0, ath_bmiss_proc, sc);
@@ -288,7 +287,7 @@
);
if (sc->sc_txhalq == (u_int) -1) {
if_printf(ifp, "unable to setup a data xmit queue!\n");
- goto bad;
+ goto bad2;
}
sc->sc_bhalq = ath_hal_setuptxqueue(ah,
HAL_TX_QUEUE_BEACON,
@@ -296,7 +295,7 @@
);
if (sc->sc_bhalq == (u_int) -1) {
if_printf(ifp, "unable to setup a beacon xmit queue!\n");
- goto bad;
+ goto bad2;
}
ifp->if_softc = sc;
@@ -317,7 +316,7 @@
| IEEE80211_C_HOSTAP /* hostap mode */
| IEEE80211_C_MONITOR /* monitor mode */
| IEEE80211_C_SHPREAMBLE /* short preamble supported */
- | IEEE80211_C_RCVMGT; /* recv management frames */
+ ;
/* get mac address from hardware */
ath_hal_getmac(ah, ic->ic_myaddr);
@@ -326,7 +325,9 @@
ieee80211_ifattach(ifp);
/* override default methods */
ic->ic_node_alloc = ath_node_alloc;
+ sc->sc_node_free = ic->ic_node_free;
ic->ic_node_free = ath_node_free;
+ sc->sc_node_copy = ic->ic_node_copy;
ic->ic_node_copy = ath_node_copy;
ic->ic_node_getrssi = ath_node_getrssi;
sc->sc_newstate = ic->ic_newstate;
@@ -355,6 +356,8 @@
sc->sc_rx_th.wr_ihdr.it_present = htole32(ATH_RX_RADIOTAP_PRESENT);
return 0;
+bad2:
+ ath_desc_free(sc);
bad:
if (ah)
ath_hal_detach(ah);
@@ -432,6 +435,8 @@
DPRINTF(ATH_DEBUG_ANY, ("%s: invalid; ignored\n", __func__));
return;
}
+ if (!ath_hal_intrpend(ah)) /* shared irq, not for us */
+ return;
if ((ifp->if_flags & (IFF_RUNNING|IFF_UP)) != (IFF_RUNNING|IFF_UP)) {
DPRINTF(ATH_DEBUG_ANY, ("%s: if_flags 0x%x\n",
__func__, ifp->if_flags));
@@ -476,8 +481,14 @@
taskqueue_enqueue(taskqueue_swi, &sc->sc_rxtask);
if (status & HAL_INT_TX)
taskqueue_enqueue(taskqueue_swi, &sc->sc_txtask);
- if (status & HAL_INT_SWBA)
- taskqueue_enqueue(taskqueue_swi, &sc->sc_swbatask);
+ if (status & HAL_INT_SWBA) {
+ /*
+ * Handle beacon transmission directly; deferring
+ * this is too slow to meet timing constraints
+ * under load.
+ */
+ ath_beacon_proc(sc, 0);
+ }
if (status & HAL_INT_BMISS) {
sc->sc_stats.ast_bmiss++;
taskqueue_enqueue(taskqueue_swi, &sc->sc_bmisstask);
@@ -1507,14 +1518,18 @@
if (bf->bf_node == ni)
bf->bf_node = NULL;
}
- free(ni, M_DEVBUF);
+ (*sc->sc_node_free)(ic, ni);
}
static void
ath_node_copy(struct ieee80211com *ic,
struct ieee80211_node *dst, const struct ieee80211_node *src)
{
- *(struct ath_node *)dst = *(const struct ath_node *)src;
+ struct ath_softc *sc = ic->ic_if.if_softc;
+
+ memcpy(&dst[1], &src[1],
+ sizeof(struct ath_node) - sizeof(struct ieee80211_node));
+ (*sc->sc_node_copy)(ic, dst, src);
}
==== //depot/projects/hammer/sys/dev/ath/if_ath_pci.c#8 (text+ko) ====
@@ -1,5 +1,5 @@
/*-
- * Copyright (c) 2002, 2003 Sam Leffler, Errno Consulting
+ * Copyright (c) 2002-2004 Sam Leffler, Errno Consulting
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath_pci.c,v 1.7 2004/03/17 17:50:27 njl Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath_pci.c,v 1.8 2004/04/02 23:57:10 sam Exp $");
/*
* PCI/Cardbus front-end for the Atheros Wireless LAN controller driver.
==== //depot/projects/hammer/sys/dev/ath/if_athioctl.h#5 (text+ko) ====
@@ -1,5 +1,5 @@
/*-
- * Copyright (c) 2002, 2003 Sam Leffler, Errno Consulting
+ * Copyright (c) 2002-2004 Sam Leffler, Errno Consulting
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -33,7 +33,7 @@
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
* THE POSSIBILITY OF SUCH DAMAGES.
*
- * $FreeBSD: src/sys/dev/ath/if_athioctl.h,v 1.5 2003/12/28 07:00:32 sam Exp $
+ * $FreeBSD: src/sys/dev/ath/if_athioctl.h,v 1.7 2004/04/02 23:57:10 sam Exp $
*/
/*
@@ -70,6 +70,8 @@
u_int32_t ast_tx_rts; /* tx frames with rts enabled */
u_int32_t ast_tx_cts; /* tx frames with cts enabled */
u_int32_t ast_tx_shortpre;/* tx frames with short preamble */
+ u_int32_t ast_tx_altrate; /* tx frames with alternate rate */
+ u_int32_t ast_tx_protect; /* tx frames with protection */
u_int32_t ast_rx_nombuf; /* rx setup failed 'cuz no mbuf */
u_int32_t ast_rx_busdma; /* rx setup failed for dma resrcs */
u_int32_t ast_rx_orn; /* rx failed 'cuz of desc overrun */
@@ -79,6 +81,7 @@
u_int32_t ast_rx_phyerr; /* rx failed 'cuz of PHY err */
u_int32_t ast_rx_phy[32]; /* rx PHY error per-code counts */
u_int32_t ast_rx_tooshort;/* rx discarded 'cuz frame too short */
+ u_int32_t ast_rx_toobig; /* rx discarded 'cuz frame too large */
u_int32_t ast_rx_ctl; /* rx discarded 'cuz ctl frame */
u_int32_t ast_be_nombuf; /* beacon setup failed 'cuz no mbuf */
u_int32_t ast_per_cal; /* periodic calibration calls */
==== //depot/projects/hammer/sys/dev/ath/if_athvar.h#9 (text+ko) ====
@@ -1,5 +1,5 @@
/*-
- * Copyright (c) 2002, 2003 Sam Leffler, Errno Consulting
+ * Copyright (c) 2002-2004 Sam Leffler, Errno Consulting
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -33,7 +33,7 @@
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
* THE POSSIBILITY OF SUCH DAMAGES.
*
- * $FreeBSD: src/sys/dev/ath/if_athvar.h,v 1.11 2004/04/01 00:38:45 sam Exp $
+ * $FreeBSD: src/sys/dev/ath/if_athvar.h,v 1.14 2004/04/03 03:33:02 sam Exp $
*/
/*
@@ -93,6 +93,11 @@
struct ieee80211com sc_ic; /* IEEE 802.11 common */
int (*sc_newstate)(struct ieee80211com *,
enum ieee80211_state, int);
+ void (*sc_node_free)(struct ieee80211com *,
+ struct ieee80211_node *);
+ void (*sc_node_copy)(struct ieee80211com *,
+ struct ieee80211_node *,
+ const struct ieee80211_node *);
device_t sc_dev;
bus_space_tag_t sc_st; /* bus space tag */
bus_space_handle_t sc_sh; /* bus space handle */
@@ -147,7 +152,6 @@
u_int sc_bhalq; /* HAL q for outgoing beacons */
struct ath_buf *sc_bcbuf; /* beacon buffer */
struct ath_buf *sc_bufptr; /* allocated buffer ptr */
- struct task sc_swbatask; /* swba int processing */
struct task sc_bmisstask; /* bmiss int processing */
struct callout sc_cal_ch; /* callout handle for cals */
==== //depot/projects/hammer/sys/dev/kbd/kbd.c#8 (text+ko) ====
@@ -26,7 +26,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/kbd/kbd.c,v 1.39 2004/02/21 21:10:43 phk Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/kbd/kbd.c,v 1.41 2004/04/02 16:41:16 des Exp $");
#include "opt_kbd.h"
@@ -56,7 +56,7 @@
} genkbd_softc_t;
static SLIST_HEAD(, keyboard_driver) keyboard_drivers =
- SLIST_HEAD_INITIALIZER(keyboard_drivers);
+ SLIST_HEAD_INITIALIZER(keyboard_drivers);
SET_DECLARE(kbddriver_set, const keyboard_driver_t);
@@ -94,14 +94,14 @@
new_kbd = malloc(sizeof(*new_kbd)*newsize, M_DEVBUF, M_NOWAIT|M_ZERO);
if (new_kbd == NULL) {
splx(s);
- return ENOMEM;
+ return (ENOMEM);
}
new_kbdsw = malloc(sizeof(*new_kbdsw)*newsize, M_DEVBUF,
M_NOWAIT|M_ZERO);
if (new_kbdsw == NULL) {
free(new_kbd, M_DEVBUF);
splx(s);
- return ENOMEM;
+ return (ENOMEM);
}
bcopy(keyboard, new_kbd, sizeof(*keyboard)*keyboards);
bcopy(kbdsw, new_kbdsw, sizeof(*kbdsw)*keyboards);
@@ -117,7 +117,7 @@
if (bootverbose)
printf("kbd: new array size %d\n", keyboards);
- return 0;
+ return (0);
}
/*
@@ -166,9 +166,9 @@
kbd_add_driver(keyboard_driver_t *driver)
{
if (SLIST_NEXT(driver, link))
- return EINVAL;
+ return (EINVAL);
SLIST_INSERT_HEAD(&keyboard_drivers, driver, link);
- return 0;
+ return (0);
}
int
@@ -176,7 +176,7 @@
{
SLIST_REMOVE(&keyboard_drivers, driver, keyboard_driver, link);
SLIST_NEXT(driver, link) = NULL;
- return 0;
+ return (0);
}
/* register a keyboard and associate it with a function table */
@@ -193,7 +193,7 @@
}
if (index >= keyboards) {
if (kbd_realloc_array())
- return -1;
+ return (-1);
}
kbd->kb_index = index;
@@ -208,7 +208,7 @@
if (strcmp(p->name, kbd->kb_name) == 0) {
keyboard[index] = kbd;
kbdsw[index] = p->kbdsw;
- return index;
+ return (index);
}
}
SET_FOREACH(list, kbddriver_set) {
@@ -216,11 +216,11 @@
if (strcmp(p->name, kbd->kb_name) == 0) {
keyboard[index] = kbd;
kbdsw[index] = p->kbdsw;
- return index;
+ return (index);
}
}
- return -1;
+ return (-1);
}
int
@@ -230,21 +230,21 @@
int s;
if ((kbd->kb_index < 0) || (kbd->kb_index >= keyboards))
- return ENOENT;
+ return (ENOENT);
if (keyboard[kbd->kb_index] != kbd)
- return ENOENT;
+ return (ENOENT);
s = spltty();
if (KBD_IS_BUSY(kbd)) {
error = (*kbd->kb_callback.kc_func)(kbd, KBDIO_UNLOADING,
- kbd->kb_callback.kc_arg);
+ kbd->kb_callback.kc_arg);
if (error) {
splx(s);
- return error;
+ return (error);
}
if (KBD_IS_BUSY(kbd)) {
splx(s);
- return EBUSY;
+ return (EBUSY);
}
}
KBD_INVALID(kbd);
@@ -252,7 +252,7 @@
kbdsw[kbd->kb_index] = NULL;
splx(s);
- return 0;
+ return (0);
}
/* find a funciton table by the driver name */
@@ -264,15 +264,15 @@
SLIST_FOREACH(p, &keyboard_drivers, link) {
if (strcmp(p->name, driver) == 0)
- return p->kbdsw;
+ return (p->kbdsw);
}
SET_FOREACH(list, kbddriver_set) {
p = *list;
if (strcmp(p->name, driver) == 0)
- return p->kbdsw;
+ return (p->kbdsw);
}
- return NULL;
+ return (NULL);
}
/*
@@ -297,9 +297,9 @@
continue;
if ((unit != -1) && (keyboard[i]->kb_unit != unit))
continue;
- return i;
+ return (i);
}
- return -1;
+ return (-1);
}
/* allocate a keyboard */
@@ -311,14 +311,14 @@
int s;
if (func == NULL)
- return -1;
+ return (-1);
s = spltty();
index = kbd_find_keyboard(driver, unit);
if (index >= 0) {
if (KBD_IS_BUSY(keyboard[index])) {
splx(s);
- return -1;
+ return (-1);
}
keyboard[index]->kb_token = id;
KBD_BUSY(keyboard[index]);
@@ -327,7 +327,7 @@
(*kbdsw[index]->clear_state)(keyboard[index]);
}
splx(s);
- return index;
+ return (index);
}
int
@@ -350,7 +350,7 @@
error = 0;
}
splx(s);
- return error;
+ return (error);
}
int
@@ -373,7 +373,7 @@
error = 0;
}
splx(s);
- return error;
+ return (error);
}
/* get a keyboard structure */
@@ -381,12 +381,12 @@
*kbd_get_keyboard(int index)
{
if ((index < 0) || (index >= keyboards))
- return NULL;
+ return (NULL);
if (keyboard[index] == NULL)
- return NULL;
+ return (NULL);
if (!KBD_IS_VALID(keyboard[index]))
- return NULL;
- return keyboard[index];
+ return (NULL);
+ return (keyboard[index]);
}
/*
@@ -411,7 +411,7 @@
(*p->configure)(flags);
}
- return 0;
+ return (0);
}
#ifdef KBD_INSTALL_CDEV
@@ -449,17 +449,17 @@
{
if (kbd->kb_index >= keyboards)
- return EINVAL;
+ return (EINVAL);
if (keyboard[kbd->kb_index] != kbd)
- return EINVAL;
+ return (EINVAL);
- kbd->kb_dev = make_dev(&kbd_cdevsw, kbd->kb_index, UID_ROOT, GID_WHEEL, 0600,
- "%s%r", kbd->kb_name, kbd->kb_unit);
+ kbd->kb_dev = make_dev(&kbd_cdevsw, kbd->kb_index, UID_ROOT, GID_WHEEL,
+ 0600, "%s%r", kbd->kb_name, kbd->kb_unit);
make_dev_alias(kbd->kb_dev, "kbd%r", kbd->kb_index);
kbd->kb_dev->si_drv1 = malloc(sizeof(genkbd_softc_t), M_DEVBUF,
- M_WAITOK | M_ZERO);
+ M_WAITOK | M_ZERO);
printf("kbd%d at %s%d\n", kbd->kb_index, kbd->kb_name, kbd->kb_unit);
- return 0;
+ return (0);
}
int
@@ -467,14 +467,14 @@
{
if (kbd->kb_index >= keyboards)
- return EINVAL;
+ return (EINVAL);
if (keyboard[kbd->kb_index] != kbd)
- return EINVAL;
+ return (EINVAL);
free(kbd->kb_dev->si_drv1, M_DEVBUF);
destroy_dev(kbd->kb_dev);
- return 0;
+ return (0);
}
/*
@@ -501,13 +501,13 @@
kbd = kbd_get_keyboard(KBD_INDEX(dev));
if ((sc == NULL) || (kbd == NULL) || !KBD_IS_VALID(kbd)) {
splx(s);
- return ENXIO;
+ return (ENXIO);
}
i = kbd_allocate(kbd->kb_name, kbd->kb_unit, sc,
- genkbd_event, (void *)sc);
+ genkbd_event, (void *)sc);
if (i < 0) {
splx(s);
- return EBUSY;
+ return (EBUSY);
}
/* assert(i == kbd->kb_index) */
/* assert(kbd == kbd_get_keyboard(i)) */
@@ -523,7 +523,7 @@
clist_alloc_cblocks(&sc->gkb_q, KB_QSIZE, KB_QSIZE/2); /* XXX */
splx(s);
- return 0;
+ return (0);
}
static int
@@ -549,7 +549,7 @@
#endif
}
splx(s);
- return 0;
+ return (0);
}
static int
@@ -568,24 +568,24 @@
kbd = kbd_get_keyboard(KBD_INDEX(dev));
if ((sc == NULL) || (kbd == NULL) || !KBD_IS_VALID(kbd)) {
splx(s);
- return ENXIO;
+ return (ENXIO);
}
while (sc->gkb_q.c_cc == 0) {
if (flag & IO_NDELAY) {
splx(s);
- return EWOULDBLOCK;
+ return (EWOULDBLOCK);
}
sc->gkb_flags |= KB_ASLEEP;
error = tsleep(sc, PZERO | PCATCH, "kbdrea", 0);
kbd = kbd_get_keyboard(KBD_INDEX(dev));
if ((kbd == NULL) || !KBD_IS_VALID(kbd)) {
splx(s);
- return ENXIO; /* our keyboard has gone... */
+ return (ENXIO); /* our keyboard has gone... */
}
if (error) {
sc->gkb_flags &= ~KB_ASLEEP;
splx(s);
- return error;
+ return (error);
}
}
splx(s);
@@ -602,7 +602,7 @@
break;
}
- return error;
+ return (error);
}
static int
@@ -612,8 +612,8 @@
kbd = kbd_get_keyboard(KBD_INDEX(dev));
if ((kbd == NULL) || !KBD_IS_VALID(kbd))
- return ENXIO;
- return ENODEV;
+ return (ENXIO);
+ return (ENODEV);
}
static int
@@ -624,11 +624,11 @@
kbd = kbd_get_keyboard(KBD_INDEX(dev));
if ((kbd == NULL) || !KBD_IS_VALID(kbd))
- return ENXIO;
+ return (ENXIO);
error = (*kbdsw[kbd->kb_index]->ioctl)(kbd, cmd, arg);
if (error == ENOIOCTL)
error = ENODEV;
- return error;
+ return (error);
}
static int
@@ -652,7 +652,7 @@
selrecord(td, &sc->gkb_rsel);
}
splx(s);
- return revents;
+ return (revents);
}
static int
@@ -678,9 +678,9 @@
wakeup(sc);
}
selwakeuppri(&sc->gkb_rsel, PZERO);
- return 0;
+ return (0);
default:
- return EINVAL;
+ return (EINVAL);
}
/* obtain the current key input mode */
@@ -733,7 +733,7 @@
break;
case FKEY | SPCLKEY: /* a function key, return string */
cp = (*kbdsw[kbd->kb_index]->get_fkeystr)(kbd,
- KEYCHAR(c), &len);
+ KEYCHAR(c), &len);
if (cp != NULL) {
while (len-- > 0)
putc(*cp++, &sc->gkb_q);
@@ -751,7 +751,7 @@
selwakeuppri(&sc->gkb_rsel, PZERO);
}
- return 0;
+ return (0);
}
#endif /* KBD_INSTALL_CDEV */
@@ -786,7 +786,7 @@
case KDGKBINFO: /* get keyboard information */
((keyboard_info_t *)arg)->kb_index = kbd->kb_index;
i = imin(strlen(kbd->kb_name) + 1,
- sizeof(((keyboard_info_t *)arg)->kb_name));
+ sizeof(((keyboard_info_t *)arg)->kb_name));
bcopy(kbd->kb_name, ((keyboard_info_t *)arg)->kb_name, i);
((keyboard_info_t *)arg)->kb_unit = kbd->kb_unit;
((keyboard_info_t *)arg)->kb_type = kbd->kb_type;
@@ -800,7 +800,7 @@
case KDGETREPEAT: /* get keyboard repeat rate */
((int *)arg)[0] = kbd->kb_delay1;
- ((int *)arg)[1] = kbd->kb_delay2;
+ ((int *)arg)[1] = kbd->kb_delay2;
break;
case GIO_KEYMAP: /* get keyboard translation table */
@@ -812,46 +812,46 @@
curthread);
if (error != 0) {
splx(s);
- return error;
+ return (error);
}
bzero(kbd->kb_accentmap, sizeof(*kbd->kb_accentmap));
bcopy(arg, kbd->kb_keymap, sizeof(*kbd->kb_keymap));
break;
#else
>>> TRUNCATED FOR MAIL (1000 lines) <<<
More information about the p4-projects
mailing list