PERFORCE change 50156 for review
Robert Watson
rwatson at FreeBSD.org
Thu Apr 1 18:04:57 PST 2004
http://perforce.freebsd.org/chv.cgi?CH=50156
Change 50156 by rwatson at rwatson_paprika on 2004/04/01 18:04:29
Integrate netperf_socket:
- Proc locking fixes for alpha.
- ps_argsopen removed.
- twa 3ware driver.
- ACPI rearrangement.
- if_ath, if_wi fixes.
- USB fixes.
- geom_apple naming consistency in XML output.
- Loop back of slisunitfree() from rwatson_netperf.
- Must always check UDP checksums with IPv6.
Affected files ...
.. //depot/projects/netperf_socket/sys/alpha/alpha/machdep.c#4 integrate
.. //depot/projects/netperf_socket/sys/compat/linprocfs/linprocfs.c#3 integrate
.. //depot/projects/netperf_socket/sys/conf/files#12 integrate
.. //depot/projects/netperf_socket/sys/conf/files.i386#12 integrate
.. //depot/projects/netperf_socket/sys/conf/majors#3 integrate
.. //depot/projects/netperf_socket/sys/dev/acpica/acpi.c#11 integrate
.. //depot/projects/netperf_socket/sys/dev/acpica/acpivar.h#6 integrate
.. //depot/projects/netperf_socket/sys/dev/ath/if_ath.c#4 integrate
.. //depot/projects/netperf_socket/sys/dev/ath/if_athvar.h#2 integrate
.. //depot/projects/netperf_socket/sys/dev/usb/usb_subr.c#4 integrate
.. //depot/projects/netperf_socket/sys/dev/wi/if_wi.c#4 integrate
.. //depot/projects/netperf_socket/sys/dev/wi/if_wivar.h#2 integrate
.. //depot/projects/netperf_socket/sys/fs/procfs/procfs_status.c#2 integrate
.. //depot/projects/netperf_socket/sys/geom/geom_apple.c#3 integrate
.. //depot/projects/netperf_socket/sys/i386/conf/GENERIC.hints#3 integrate
.. //depot/projects/netperf_socket/sys/kern/kern_exec.c#6 integrate
.. //depot/projects/netperf_socket/sys/kern/kern_proc.c#4 integrate
.. //depot/projects/netperf_socket/sys/kern/kern_thr.c#3 integrate
.. //depot/projects/netperf_socket/sys/kern/subr_bus.c#4 integrate
.. //depot/projects/netperf_socket/sys/kern/sys_process.c#5 integrate
.. //depot/projects/netperf_socket/sys/net/if_sl.c#2 integrate
.. //depot/projects/netperf_socket/sys/netinet6/udp6_usrreq.c#4 integrate
.. //depot/projects/netperf_socket/sys/pc98/conf/NOTES#6 integrate
.. //depot/projects/netperf_socket/sys/pci/if_ste.c#8 integrate
.. //depot/projects/netperf_socket/sys/powerpc/powermac/grackle.c#3 integrate
.. //depot/projects/netperf_socket/sys/sys/proc.h#4 integrate
Differences ...
==== //depot/projects/netperf_socket/sys/alpha/alpha/machdep.c#4 (text+ko) ====
@@ -88,7 +88,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/alpha/alpha/machdep.c,v 1.218 2004/03/01 19:19:15 kensmith Exp $");
+__FBSDID("$FreeBSD: src/sys/alpha/alpha/machdep.c,v 1.219 2004/04/01 20:56:43 jhb Exp $");
#include "opt_compat.h"
#include "opt_ddb.h"
@@ -1914,10 +1914,9 @@
if (td->td_md.md_flags & (MDTD_STEP1|MDTD_STEP2))
panic("ptrace_single_step: step breakpoints not removed");
- PROC_UNLOCK(td->td_proc);
error = ptrace_read_int(td, pc, &ins.bits);
if (error)
- goto err;
+ return (error);
switch (ins.branch_format.opcode) {
@@ -1957,20 +1956,18 @@
td->td_md.md_sstep[0].addr = addr[0];
error = ptrace_set_bpt(td, &td->td_md.md_sstep[0]);
if (error)
- goto err;
+ return (error);
if (count == 2) {
td->td_md.md_sstep[1].addr = addr[1];
error = ptrace_set_bpt(td, &td->td_md.md_sstep[1]);
if (error) {
ptrace_clear_bpt(td, &td->td_md.md_sstep[0]);
- goto err;
+ return (error);
}
td->td_md.md_flags |= MDTD_STEP2;
} else
td->td_md.md_flags |= MDTD_STEP1;
-err:
- PROC_LOCK(td->td_proc);
return (error);
}
==== //depot/projects/netperf_socket/sys/compat/linprocfs/linprocfs.c#3 (text+ko) ====
@@ -40,7 +40,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/linprocfs/linprocfs.c,v 1.82 2004/02/09 20:33:42 des Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/linprocfs/linprocfs.c,v 1.83 2004/04/01 00:04:22 pjd Exp $");
#include <sys/param.h>
#include <sys/queue.h>
@@ -771,7 +771,7 @@
*/
PROC_LOCK(p);
- if (p->p_args && (ps_argsopen || !p_cansee(td, p))) {
+ if (p->p_args && p_cansee(td, p) == 0) {
sbuf_bcpy(sb, p->p_args->ar_args, p->p_args->ar_length);
PROC_UNLOCK(p);
} else if (p != td->td_proc) {
==== //depot/projects/netperf_socket/sys/conf/files#12 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/files,v 1.877 2004/03/20 02:14:02 marcel Exp $
+# $FreeBSD: src/sys/conf/files,v 1.880 2004/04/01 17:55:50 des Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -668,6 +668,7 @@
dev/sound/midi/sequencer.c optional seq midi
dev/sound/midi/timer.c optional seq midi
dev/sound/pci/als4000.c optional pcm pci
+#dev/sound/pci/au88x0.c optional pcm pci
dev/sound/pci/cmi.c optional pcm pci
dev/sound/pci/cs4281.c optional pcm pci
dev/sound/pci/csa.c optional csa pci
@@ -730,6 +731,11 @@
dev/syscons/warp/warp_saver.c optional warp_saver
dev/tdfx/tdfx_pci.c optional tdfx pci
dev/trm/trm.c optional trm
+dev/twa/twa.c optional twa
+dev/twa/twa_cam.c optional twa
+dev/twa/twa_freebsd.c optional twa
+dev/twa/twa_fwimg.c optional twa
+dev/twa/twa_globals.c optional twa
dev/twe/twe.c optional twe
dev/twe/twe_freebsd.c optional twe
dev/tx/if_tx.c optional tx
==== //depot/projects/netperf_socket/sys/conf/files.i386#12 (text+ko) ====
@@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
-# $FreeBSD: src/sys/conf/files.i386,v 1.482 2004/03/30 03:45:59 vkashyap Exp $
+# $FreeBSD: src/sys/conf/files.i386,v 1.483 2004/04/01 10:02:50 des Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -170,11 +170,6 @@
dev/syscons/scvtb.c optional sc
dev/syscons/syscons.c optional sc
dev/syscons/sysmouse.c optional sc
-dev/twa/twa.c optional twa
-dev/twa/twa_cam.c optional twa
-dev/twa/twa_freebsd.c optional twa
-dev/twa/twa_fwimg.c optional twa
-dev/twa/twa_globals.c optional twa
dev/uart/uart_cpu_i386.c optional uart
geom/geom_bsd.c standard
geom/geom_bsd_enc.c standard
==== //depot/projects/netperf_socket/sys/conf/majors#3 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/majors,v 1.197 2004/02/23 08:55:12 phk Exp $
+# $FreeBSD: src/sys/conf/majors,v 1.198 2004/04/01 10:00:04 des Exp $
#
# This list is semi-obsoleted by DEVFS, but for now it still contains
# the current allocation of device major numbers.
@@ -90,7 +90,6 @@
183 *smapi SMAPI BIOS interface <mdodd>
185 ce Cronyx Tau-32 E1 adapter <rik at cronyx.ru>
186 sx Specialix I/O8+ driver <frank at exit.com>
-187 twa 3ware Apache ATA RAID (controller)
252 ?? entries from 200-252 are reserved for local use
254 internal Used internally by the kernel
255 bad_choice -1 is 255 which has magic meanings internally
==== //depot/projects/netperf_socket/sys/dev/acpica/acpi.c#11 (text+ko) ====
@@ -26,7 +26,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/dev/acpica/acpi.c,v 1.133 2004/03/31 17:35:28 njl Exp $
+ * $FreeBSD: src/sys/dev/acpica/acpi.c,v 1.134 2004/04/01 04:21:33 njl Exp $
*/
#include "opt_acpi.h"
@@ -809,82 +809,6 @@
return (0);
}
-ACPI_HANDLE
-acpi_get_handle(device_t dev)
-{
- uintptr_t up;
- ACPI_HANDLE h;
-
- if (BUS_READ_IVAR(device_get_parent(dev), dev, ACPI_IVAR_HANDLE, &up))
- return(NULL);
- h = (ACPI_HANDLE)up;
- return (h);
-}
-
-int
-acpi_set_handle(device_t dev, ACPI_HANDLE h)
-{
- uintptr_t up;
-
- up = (uintptr_t)h;
- return (BUS_WRITE_IVAR(device_get_parent(dev), dev, ACPI_IVAR_HANDLE, up));
-}
-
-int
-acpi_get_magic(device_t dev)
-{
- uintptr_t up;
- int m;
-
- if (BUS_READ_IVAR(device_get_parent(dev), dev, ACPI_IVAR_MAGIC, &up))
- return(0);
- m = (int)up;
- return (m);
-}
-
-int
-acpi_set_magic(device_t dev, int m)
-{
- uintptr_t up;
-
- up = (uintptr_t)m;
- return (BUS_WRITE_IVAR(device_get_parent(dev), dev, ACPI_IVAR_MAGIC, up));
-}
-
-void *
-acpi_get_private(device_t dev)
-{
- uintptr_t up;
- void *p;
-
- if (BUS_READ_IVAR(device_get_parent(dev), dev, ACPI_IVAR_PRIVATE, &up))
- return (NULL);
- p = (void *)up;
- return (p);
-}
-
-int
-acpi_set_private(device_t dev, void *p)
-{
- uintptr_t up;
-
- up = (uintptr_t)p;
- return (BUS_WRITE_IVAR(device_get_parent(dev), dev, ACPI_IVAR_PRIVATE, up));
-}
-
-ACPI_OBJECT_TYPE
-acpi_get_type(device_t dev)
-{
- ACPI_HANDLE h;
- ACPI_OBJECT_TYPE t;
-
- if ((h = acpi_get_handle(dev)) == NULL)
- return (ACPI_TYPE_NOT_FOUND);
- if (AcpiGetType(h, &t) != AE_OK)
- return (ACPI_TYPE_NOT_FOUND);
- return (t);
-}
-
/*
* Handle child resource allocation/removal
*/
==== //depot/projects/netperf_socket/sys/dev/acpica/acpivar.h#6 (text+ko) ====
@@ -25,7 +25,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/dev/acpica/acpivar.h,v 1.58 2004/03/31 17:23:46 njl Exp $
+ * $FreeBSD: src/sys/dev/acpica/acpivar.h,v 1.59 2004/04/01 04:21:33 njl Exp $
*/
#include "bus_if.h"
@@ -142,15 +142,75 @@
#define ACPI_IVAR_MAGIC 0x101
#define ACPI_IVAR_PRIVATE 0x102
-extern ACPI_HANDLE acpi_get_handle(device_t dev);
-extern int acpi_set_handle(device_t dev, ACPI_HANDLE h);
-extern int acpi_get_magic(device_t dev);
-extern int acpi_set_magic(device_t dev, int m);
-extern void * acpi_get_private(device_t dev);
-extern int acpi_set_private(device_t dev, void *p);
-extern ACPI_OBJECT_TYPE acpi_get_type(device_t dev);
-struct resource * acpi_bus_alloc_gas(device_t dev, int *rid,
- ACPI_GENERIC_ADDRESS *gas);
+static __inline ACPI_HANDLE
+acpi_get_handle(device_t dev)
+{
+ uintptr_t up;
+
+ if (BUS_READ_IVAR(device_get_parent(dev), dev, ACPI_IVAR_HANDLE, &up))
+ return (NULL);
+ return ((ACPI_HANDLE)up);
+}
+
+static __inline int
+acpi_set_handle(device_t dev, ACPI_HANDLE h)
+{
+ uintptr_t up;
+
+ up = (uintptr_t)h;
+ return (BUS_WRITE_IVAR(device_get_parent(dev), dev, ACPI_IVAR_HANDLE, up));
+}
+
+static __inline int
+acpi_get_magic(device_t dev)
+{
+ uintptr_t up;
+
+ if (BUS_READ_IVAR(device_get_parent(dev), dev, ACPI_IVAR_MAGIC, &up))
+ return(0);
+ return ((int)up);
+}
+
+static __inline int
+acpi_set_magic(device_t dev, int m)
+{
+ uintptr_t up;
+
+ up = (uintptr_t)m;
+ return (BUS_WRITE_IVAR(device_get_parent(dev), dev, ACPI_IVAR_MAGIC, up));
+}
+
+static __inline void *
+acpi_get_private(device_t dev)
+{
+ uintptr_t up;
+
+ if (BUS_READ_IVAR(device_get_parent(dev), dev, ACPI_IVAR_PRIVATE, &up))
+ return (NULL);
+ return ((void *)up);
+}
+
+static __inline int
+acpi_set_private(device_t dev, void *p)
+{
+ uintptr_t up;
+
+ up = (uintptr_t)p;
+ return (BUS_WRITE_IVAR(device_get_parent(dev), dev, ACPI_IVAR_PRIVATE, up));
+}
+
+static __inline ACPI_OBJECT_TYPE
+acpi_get_type(device_t dev)
+{
+ ACPI_HANDLE h;
+ ACPI_OBJECT_TYPE t;
+
+ if ((h = acpi_get_handle(dev)) == NULL)
+ return (ACPI_TYPE_NOT_FOUND);
+ if (AcpiGetType(h, &t) != AE_OK)
+ return (ACPI_TYPE_NOT_FOUND);
+ return (t);
+}
#ifdef ACPI_DEBUGGER
extern void acpi_EnterDebugger(void);
@@ -196,6 +256,8 @@
extern ACPI_STATUS acpi_Disable(struct acpi_softc *sc);
extern void acpi_UserNotify(const char *subsystem, ACPI_HANDLE h,
uint8_t notify);
+struct resource * acpi_bus_alloc_gas(device_t dev, int *rid,
+ ACPI_GENERIC_ADDRESS *gas);
struct acpi_parse_resource_set {
void (*set_init)(device_t dev, void *arg, void **context);
==== //depot/projects/netperf_socket/sys/dev/ath/if_ath.c#4 (text+ko) ====
@@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.46 2004/03/20 19:57:46 mdodd Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.47 2004/04/01 00:38:45 sam Exp $");
/*
* Driver for the Atheros Wireless LAN controller.
@@ -339,15 +339,20 @@
&sc->sc_drvbpf);
/*
* Initialize constant fields.
+ * XXX make header lengths a multiple of 32-bits so subsequent
+ * headers are properly aligned; this is a kludge to keep
+ * certain applications happy.
*
* NB: the channel is setup each time we transition to the
* RUN state to avoid filling it in for each frame.
*/
- sc->sc_tx_th.wt_ihdr.it_len = sizeof(sc->sc_tx_th);
- sc->sc_tx_th.wt_ihdr.it_present = ATH_TX_RADIOTAP_PRESENT;
+ sc->sc_tx_th_len = roundup(sizeof(sc->sc_tx_th), sizeof(u_int32_t));
+ sc->sc_tx_th.wt_ihdr.it_len = htole16(sc->sc_tx_th_len);
+ sc->sc_tx_th.wt_ihdr.it_present = htole32(ATH_TX_RADIOTAP_PRESENT);
- sc->sc_rx_th.wr_ihdr.it_len = sizeof(sc->sc_rx_th);
- sc->sc_rx_th.wr_ihdr.it_present = ATH_RX_RADIOTAP_PRESENT;
+ sc->sc_rx_th_len = roundup(sizeof(sc->sc_rx_th), sizeof(u_int32_t));
+ sc->sc_rx_th.wr_ihdr.it_len = htole16(sc->sc_rx_th_len);
+ sc->sc_rx_th.wr_ihdr.it_present = htole32(ATH_RX_RADIOTAP_PRESENT);
return 0;
bad:
@@ -1726,7 +1731,7 @@
/* XXX TSF */
bpf_mtap2(sc->sc_drvbpf,
- &sc->sc_rx_th, sizeof(sc->sc_rx_th), m);
+ &sc->sc_rx_th, sc->sc_rx_th_len, m);
}
m_adj(m, -IEEE80211_CRC_LEN);
@@ -2070,7 +2075,7 @@
sc->sc_tx_th.wt_antenna = antenna;
bpf_mtap2(sc->sc_drvbpf,
- &sc->sc_tx_th, sizeof(sc->sc_tx_th), m0);
+ &sc->sc_tx_th, sc->sc_tx_th_len, m0);
}
/*
==== //depot/projects/netperf_socket/sys/dev/ath/if_athvar.h#2 (text+ko) ====
@@ -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.10 2003/11/29 01:23:59 sam Exp $
+ * $FreeBSD: src/sys/dev/ath/if_athvar.h,v 1.11 2004/04/01 00:38:45 sam Exp $
*/
/*
@@ -115,10 +115,12 @@
struct ath_tx_radiotap_header th;
u_int8_t pad[64];
} u_tx_rt;
+ int sc_tx_th_len;
union {
struct ath_rx_radiotap_header th;
u_int8_t pad[64];
} u_rx_rt;
+ int sc_rx_th_len;
struct ath_desc *sc_desc; /* TX/RX descriptors */
bus_dma_segment_t sc_dseg;
==== //depot/projects/netperf_socket/sys/dev/usb/usb_subr.c#4 (text+ko) ====
@@ -7,7 +7,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/usb/usb_subr.c,v 1.62 2004/03/20 07:31:11 julian Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/usb/usb_subr.c,v 1.63 2004/04/01 18:55:28 julian Exp $");
/*
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -1045,8 +1045,19 @@
up->device = dev;
/* Set the address. Do this early; some devices need that. */
- err = usbd_set_address(dev, addr);
+ /* Try a few times in case the device is slow (i.e. outside specs.) */
DPRINTFN(5,("usbd_new_device: setting device address=%d\n", addr));
+ for (i = 0; i < 15; i++) {
+ err = usbd_set_address(dev, addr);
+ if (!err)
+ break;
+ usbd_delay_ms(dev, 200);
+ if ((i & 3) == 3) {
+ DPRINTFN(-1,("usb_new_device: set address %d "
+ "failed - trying a port reset\n", addr));
+ usbd_reset_port(up->parent, port, &ps);
+ }
+ }
if (err) {
DPRINTFN(-1,("usb_new_device: set address %d failed\n", addr));
err = USBD_SET_ADDR_FAILED;
@@ -1059,16 +1070,8 @@
bus->devices[addr] = dev;
dd = &dev->ddesc;
- /* Try a few times in case the device is slow (i.e. outside specs.) */
- for (i = 0; i < 15; i++) {
- /* Get the first 8 bytes of the device descriptor. */
- err = usbd_get_desc(dev, UDESC_DEVICE, 0, USB_MAX_IPACKET, dd);
- if (!err)
- break;
- usbd_delay_ms(dev, 200);
- if ((i & 3) == 3)
- usbd_reset_port(up->parent, port, &ps);
- }
+ /* Get the first 8 bytes of the device descriptor. */
+ err = usbd_get_desc(dev, UDESC_DEVICE, 0, USB_MAX_IPACKET, dd);
if (err) {
DPRINTFN(-1, ("usbd_new_device: addr=%d, getting first desc "
"failed\n", addr));
==== //depot/projects/netperf_socket/sys/dev/wi/if_wi.c#4 (text+ko) ====
@@ -62,7 +62,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/wi/if_wi.c,v 1.164 2004/03/20 19:57:47 mdodd Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/wi/if_wi.c,v 1.166 2004/04/01 00:38:45 sam Exp $");
#define WI_HERMES_AUTOINC_WAR /* Work around data write autoinc bug. */
#define WI_HERMES_STATS_WAR /* Work around stats counter bug. */
@@ -482,15 +482,20 @@
&sc->sc_drvbpf);
/*
* Initialize constant fields.
+ * XXX make header lengths a multiple of 32-bits so subsequent
+ * headers are properly aligned; this is a kludge to keep
+ * certain applications happy.
*
* NB: the channel is setup each time we transition to the
* RUN state to avoid filling it in for each frame.
*/
- sc->sc_tx_th.wt_ihdr.it_len = sizeof(sc->sc_tx_th);
- sc->sc_tx_th.wt_ihdr.it_present = WI_TX_RADIOTAP_PRESENT;
+ sc->sc_tx_th_len = roundup(sizeof(sc->sc_tx_th), sizeof(u_int32_t));
+ sc->sc_tx_th.wt_ihdr.it_len = htole16(sc->sc_tx_th_len);
+ sc->sc_tx_th.wt_ihdr.it_present = htole32(WI_TX_RADIOTAP_PRESENT);
- sc->sc_rx_th.wr_ihdr.it_len = sizeof(sc->sc_rx_th);
- sc->sc_rx_th.wr_ihdr.it_present = WI_RX_RADIOTAP_PRESENT;
+ sc->sc_rx_th_len = roundup(sizeof(sc->sc_rx_th), sizeof(u_int32_t));
+ sc->sc_rx_th.wr_ihdr.it_len = htole16(sc->sc_rx_th_len);
+ sc->sc_rx_th.wr_ihdr.it_present = htole32(WI_RX_RADIOTAP_PRESENT);
#endif
return (0);
}
@@ -939,18 +944,18 @@
}
frmhdr.wi_tx_ctl |= htole16(WI_TXCNTL_NOCRYPT);
}
- m_copydata(m0, 0, sizeof(struct ieee80211_frame),
- (caddr_t)&frmhdr.wi_whdr);
- m_adj(m0, sizeof(struct ieee80211_frame));
- frmhdr.wi_dat_len = htole16(m0->m_pkthdr.len);
#if NBPFILTER > 0
if (sc->sc_drvbpf) {
sc->sc_tx_th.wt_rate =
ni->ni_rates.rs_rates[ni->ni_txrate];
bpf_mtap2(sc->sc_drvbpf,
- &sc->sc_tx_th, sizeof(sc->sc_tx_th), m0);
+ &sc->sc_tx_th, sc->sc_tx_th_len, m0);
}
#endif
+ m_copydata(m0, 0, sizeof(struct ieee80211_frame),
+ (caddr_t)&frmhdr.wi_whdr);
+ m_adj(m0, sizeof(struct ieee80211_frame));
+ frmhdr.wi_dat_len = htole16(m0->m_pkthdr.len);
if (IFF_DUMPPKTS(ifp))
wi_dump_pkt(&frmhdr, NULL, -1);
fid = sc->sc_txd[cur].d_fid;
@@ -1495,7 +1500,7 @@
if (frmhdr.wi_status & WI_STAT_PCF)
sc->sc_rx_th.wr_flags |= IEEE80211_RADIOTAP_F_CFP;
bpf_mtap2(sc->sc_drvbpf,
- &sc->sc_rx_th, sizeof(sc->sc_rx_th), m);
+ &sc->sc_rx_th, sc->sc_rx_th_len, m);
}
#endif
wh = mtod(m, struct ieee80211_frame *);
==== //depot/projects/netperf_socket/sys/dev/wi/if_wivar.h#2 (text+ko) ====
@@ -31,7 +31,7 @@
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
* THE POSSIBILITY OF SUCH DAMAGE.
*
- * $FreeBSD: src/sys/dev/wi/if_wivar.h,v 1.21 2003/12/09 07:41:07 imp Exp $
+ * $FreeBSD: src/sys/dev/wi/if_wivar.h,v 1.22 2004/04/01 00:38:45 sam Exp $
*/
#if 0
@@ -168,10 +168,12 @@
struct wi_tx_radiotap_header th;
u_int8_t pad[64];
} u_tx_rt;
+ int sc_tx_th_len;
union {
struct wi_rx_radiotap_header th;
u_int8_t pad[64];
} u_rx_rt;
+ int sc_rx_th_len;
};
#define sc_if sc_ic.ic_if
#define sc_tx_th u_tx_rt.th
==== //depot/projects/netperf_socket/sys/fs/procfs/procfs_status.c#2 (text+ko) ====
@@ -38,7 +38,7 @@
*
* From:
* $Id: procfs_status.c,v 3.1 1993/12/15 09:40:17 jsp Exp $
- * $FreeBSD: src/sys/fs/procfs/procfs_status.c,v 1.50 2003/12/07 17:40:00 des Exp $
+ * $FreeBSD: src/sys/fs/procfs/procfs_status.c,v 1.51 2004/04/01 00:04:23 pjd Exp $
*/
#include <sys/param.h>
@@ -191,7 +191,7 @@
*/
PROC_LOCK(p);
- if (p->p_args && (ps_argsopen || !p_cansee(td, p))) {
+ if (p->p_args && p_cansee(td, p) == 0) {
sbuf_bcpy(sb, p->p_args->ar_args, p->p_args->ar_length);
PROC_UNLOCK(p);
return (0);
==== //depot/projects/netperf_socket/sys/geom/geom_apple.c#3 (text+ko) ====
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/geom/geom_apple.c,v 1.13 2004/02/12 22:42:11 phk Exp $");
+__FBSDID("$FreeBSD: src/sys/geom/geom_apple.c,v 1.14 2004/04/01 01:33:37 grehan Exp $");
#include <sys/param.h>
#include <sys/endian.h>
@@ -116,11 +116,13 @@
mp = gsp->softc;
g_slice_dumpconf(sb, indent, gp, cp, pp);
if (pp != NULL) {
- if (indent == NULL)
- sbuf_printf(sb, " n %s ty %s",
- mp->apmpart[pp->index].am_name,
+ if (indent == NULL) {
+ sbuf_printf(sb, " ty %s",
mp->apmpart[pp->index].am_type);
- else {
+ if (*mp->apmpart[pp->index].am_name)
+ sbuf_printf(sb, " sn %s",
+ mp->apmpart[pp->index].am_name);
+ } else {
sbuf_printf(sb, "%s<name>%s</name>\n", indent,
mp->apmpart[pp->index].am_name);
sbuf_printf(sb, "%s<type>%s</type>\n", indent,
==== //depot/projects/netperf_socket/sys/i386/conf/GENERIC.hints#3 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/i386/conf/GENERIC.hints,v 1.12 2004/03/14 22:38:18 imp Exp $
+# $FreeBSD: src/sys/i386/conf/GENERIC.hints,v 1.13 2004/04/01 21:48:31 alfred Exp $
hint.fdc.0.at="isa"
hint.fdc.0.port="0x3F0"
hint.fdc.0.irq="6"
@@ -25,7 +25,6 @@
hint.atkbdc.0.port="0x060"
hint.atkbd.0.at="atkbdc"
hint.atkbd.0.irq="1"
-hint.atkbd.0.flags="0x1"
hint.psm.0.at="atkbdc"
hint.psm.0.irq="12"
hint.vga.0.at="isa"
==== //depot/projects/netperf_socket/sys/kern/kern_exec.c#6 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/kern_exec.c,v 1.240 2004/03/14 02:06:27 peter Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/kern_exec.c,v 1.241 2004/04/01 00:10:44 pjd Exp $");
#include "opt_ktrace.h"
#include "opt_mac.h"
@@ -95,9 +95,6 @@
SYSCTL_ULONG(_kern, OID_AUTO, ps_arg_cache_limit, CTLFLAG_RW,
&ps_arg_cache_limit, 0, "");
-int ps_argsopen = 1;
-SYSCTL_INT(_kern, OID_AUTO, ps_argsopen, CTLFLAG_RW, &ps_argsopen, 0, "");
-
static int
sysctl_kern_ps_strings(SYSCTL_HANDLER_ARGS)
{
==== //depot/projects/netperf_socket/sys/kern/kern_proc.c#4 (text+ko) ====
@@ -31,11 +31,11 @@
* SUCH DAMAGE.
*
* @(#)kern_proc.c 8.7 (Berkeley) 2/14/95
- * $FreeBSD: src/sys/kern/kern_proc.c,v 1.200 2004/03/17 13:19:43 pjd Exp $
+ * $FreeBSD: src/sys/kern/kern_proc.c,v 1.201 2004/04/01 00:08:20 pjd Exp $
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/kern_proc.c,v 1.200 2004/03/17 13:19:43 pjd Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/kern_proc.c,v 1.201 2004/04/01 00:08:20 pjd Exp $");
#include "opt_ktrace.h"
#include "opt_kstack_pages.h"
@@ -1111,11 +1111,6 @@
return (error);
}
- if (!ps_argsopen) {
- PROC_UNLOCK(p);
- return (EPERM);
- }
-
if (req->newptr && curproc != p) {
PROC_UNLOCK(p);
return (EPERM);
==== //depot/projects/netperf_socket/sys/kern/kern_thr.c#3 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/kern_thr.c,v 1.15 2004/03/27 14:30:43 mtm Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/kern_thr.c,v 1.16 2004/04/02 01:01:34 julian Exp $");
#include <sys/param.h>
#include <sys/kernel.h>
@@ -81,11 +81,8 @@
/* Clean up cpu resources. */
cpu_thread_exit(td);
- /* XXX make thread_unlink() */
- TAILQ_REMOVE(&p->p_threads, td, td_plist);
- p->p_numthreads--;
- TAILQ_REMOVE(&kg->kg_threads, td, td_kglist);
- kg->kg_numthreads--;
+ /* Unlink the thread from the process and kseg.
+ thread_unlink(td);
ke->ke_state = KES_UNQUEUED;
ke->ke_thread = NULL;
==== //depot/projects/netperf_socket/sys/kern/subr_bus.c#4 (text+ko) ====
@@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/subr_bus.c,v 1.143 2004/03/24 16:49:37 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/subr_bus.c,v 1.144 2004/04/01 07:18:42 scottl Exp $");
#include "opt_bus.h"
@@ -2148,7 +2148,7 @@
error = BUS_SETUP_INTR(dev->parent, dev, r, flags,
handler, arg, cookiep);
if (error == 0) {
- if (!(flags & INTR_MPSAFE))
+ if (!(flags & (INTR_MPSAFE | INTR_FAST)))
device_printf(dev, "[GIANT-LOCKED]\n");
if (bootverbose && (flags & INTR_MPSAFE))
device_printf(dev, "[MPSAFE]\n");
==== //depot/projects/netperf_socket/sys/kern/sys_process.c#5 (text+ko) ====
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/kern/sys_process.c,v 1.119 2004/03/24 23:35:04 alc Exp $");
+__FBSDID("$FreeBSD: src/sys/kern/sys_process.c,v 1.120 2004/04/01 20:56:44 jhb Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -154,18 +154,21 @@
vm_prot_t reqprot;
int error, writing;
- GIANT_REQUIRED;
-
+ mtx_lock(&Giant);
/*
* if the vmspace is in the midst of being deallocated or the
* process is exiting, don't try to grab anything. The page table
* usage in that process can be messed up.
*/
vm = p->p_vmspace;
- if ((p->p_flag & P_WEXIT))
+ if ((p->p_flag & P_WEXIT)) {
+ mtx_unlock(&Giant);
return (EFAULT);
- if (vm->vm_refcnt < 1)
+ }
+ if (vm->vm_refcnt < 1) {
+ mtx_unlock(&Giant);
return (EFAULT);
+ }
++vm->vm_refcnt;
/*
* The map we want...
@@ -274,6 +277,7 @@
} while (error == 0 && uio->uio_resid > 0);
vmspace_free(vm);
+ mtx_unlock(&Giant);
return (error);
}
@@ -602,9 +606,7 @@
uio.uio_segflg = UIO_SYSSPACE; /* i.e.: the uap */
uio.uio_rw = write ? UIO_WRITE : UIO_READ;
uio.uio_td = td;
- mtx_lock(&Giant);
error = proc_rwmem(p, &uio);
- mtx_unlock(&Giant);
if (uio.uio_resid != 0) {
/*
* XXX proc_rwmem() doesn't currently return ENOSPC,
@@ -645,9 +647,7 @@
default:
return (EINVAL);
}
- mtx_lock(&Giant);
error = proc_rwmem(p, &uio);
- mtx_unlock(&Giant);
piod->piod_len -= uio.uio_resid;
return (error);
==== //depot/projects/netperf_socket/sys/net/if_sl.c#2 (text+ko) ====
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if_sl.c 8.6 (Berkeley) 2/1/94
- * $FreeBSD: src/sys/net/if_sl.c,v 1.111 2003/10/31 18:32:08 brooks Exp $
+ * $FreeBSD: src/sys/net/if_sl.c,v 1.113 2004/04/01 23:54:49 rwatson Exp $
*/
/*
@@ -224,6 +224,18 @@
static size_t st_unit_max = 0;
static int
+slisunitfree(int unit)
+{
+ struct sl_softc *nc;
+
+ LIST_FOREACH(nc, &sl_list, sl_next) {
+ if (nc->sc_if.if_dunit == unit)
+ return (0);
+ }
+ return (1);
+}
+
+static int
slisstatic(unit)
int unit;
{
@@ -260,7 +272,7 @@
static struct sl_softc *
slcreate()
{
- struct sl_softc *sc, *nc;
+ struct sl_softc *sc;
int unit;
struct mbuf *m;
@@ -310,10 +322,8 @@
for (unit=0; ; unit++) {
if (slisstatic(unit))
continue;
- LIST_FOREACH(nc, &sl_list, sl_next) {
- if (nc->sc_if.if_dunit == unit)
- continue;
- }
+ if (!slisunitfree(unit))
+ continue;
break;
}
if_initname(&sc->sc_if, "sl", unit);
@@ -443,7 +453,7 @@
int flag;
struct thread *td;
{
- struct sl_softc *sc = (struct sl_softc *)tp->t_sc, *nc;
+ struct sl_softc *sc = (struct sl_softc *)tp->t_sc;
int s, unit, wasup;
s = splimp();
@@ -459,11 +469,9 @@
return (ENXIO);
}
if (sc->sc_if.if_dunit != unit) {
- LIST_FOREACH(nc, &sl_list, sl_next) {
- if (nc->sc_if.if_dunit == *(u_int *)data) {
- splx(s);
- return (ENXIO);
- }
+ if (!slisunitfree(unit)) {
+ splx(s);
+ return (ENXIO);
}
wasup = sc->sc_if.if_flags & IFF_UP;
==== //depot/projects/netperf_socket/sys/netinet6/udp6_usrreq.c#4 (text+ko) ====
@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/netinet6/udp6_usrreq.c,v 1.46 2004/03/27 21:05:46 pjd Exp $ */
+/* $FreeBSD: src/sys/netinet6/udp6_usrreq.c,v 1.47 2004/04/01 13:48:23 suz Exp $ */
/* $KAME: udp6_usrreq.c,v 1.27 2001/05/21 05:45:10 jinmei Exp $ */
/*
@@ -168,9 +168,11 @@
/*
* Checksum extended UDP header and data.
*/
- if (uh->uh_sum == 0)
+ if (uh->uh_sum == 0) {
udpstat.udps_nosum++;
- else if (in6_cksum(m, IPPROTO_UDP, off, ulen) != 0) {
+ goto bad;
+ }
+ if (in6_cksum(m, IPPROTO_UDP, off, ulen) != 0) {
udpstat.udps_badsum++;
goto bad;
}
==== //depot/projects/netperf_socket/sys/pc98/conf/NOTES#6 (text+ko) ====
@@ -4,7 +4,7 @@
# This file contains machine dependent kernel configuration notes. For
# machine independent notes, look in /sys/conf/NOTES.
#
-# $FreeBSD: src/sys/pc98/conf/NOTES,v 1.30 2004/03/28 12:06:29 nyan Exp $
+# $FreeBSD: src/sys/pc98/conf/NOTES,v 1.31 2004/04/01 14:23:41 nyan Exp $
#
#
@@ -775,6 +775,7 @@
nodevice mlx # Mylex DAC960
nodevice amr # AMI MegaRAID
nodevice twe # 3ware ATA RAID
+nodevice twa # 3ware 9000 series PATA/SATA RAID
nodevice ataraid
nodevice cm
nodevice cs
@@ -808,6 +809,8 @@
nooption DPT_LOST_IRQ
nooption DPT_RESET_HBA
nooption DPT_TIMEOUT_FACTOR
+nooption TWA_DEBUG
+nooption TWA_FLASH_FIRMWARE
nooption AAC_DEBUG
nooption ACPI_MAX_THREADS
==== //depot/projects/netperf_socket/sys/pci/if_ste.c#8 (text+ko) ====
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/pci/if_ste.c,v 1.66 2004/03/31 21:10:01 ru Exp $");
+__FBSDID("$FreeBSD: src/sys/pci/if_ste.c,v 1.67 2004/04/01 12:55:38 ru Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -163,8 +163,10 @@
DRIVER_MODULE(ste, pci, ste_driver, ste_devclass, 0, 0);
DRIVER_MODULE(miibus, ste, miibus_driver, miibus_devclass, 0, 0);
+SYSCTL_NODE(_hw, OID_AUTO, ste, CTLFLAG_RD, 0, "if_ste parameters");
+
static int ste_rxsyncs;
-SYSCTL_INT(_hw, OID_AUTO, ste_rxsyncs, CTLFLAG_RW, &ste_rxsyncs, 0, "");
+SYSCTL_INT(_hw_ste, OID_AUTO, rxsyncs, CTLFLAG_RW, &ste_rxsyncs, 0, "");
#define STE_SETBIT4(sc, reg, x) \
CSR_WRITE_4(sc, reg, CSR_READ_4(sc, reg) | (x))
==== //depot/projects/netperf_socket/sys/powerpc/powermac/grackle.c#3 (text+ko) ====
@@ -24,7 +24,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
>>> TRUNCATED FOR MAIL (1000 lines) <<<
More information about the p4-projects
mailing list