Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 9 Dec 2002 13:44:50 -0800 (PST)
From:      John Baldwin <jhb@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 22109 for review
Message-ID:  <200212092144.gB9LioSd079511@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=22109

Change 22109 by jhb@jhb_laptop on 2002/12/09 13:44:50

	IFC @22108.

Affected files ...

.. //depot/projects/smpng/sys/boot/efi/include/efiapi.h#5 integrate
.. //depot/projects/smpng/sys/boot/efi/libefi/efi_console.c#2 integrate
.. //depot/projects/smpng/sys/boot/efi/loader/main.c#7 integrate
.. //depot/projects/smpng/sys/boot/libstand/libstand.3#2 integrate
.. //depot/projects/smpng/sys/compat/linux/linux_file.c#14 integrate
.. //depot/projects/smpng/sys/conf/NOTES#30 integrate
.. //depot/projects/smpng/sys/conf/ldscript.ia64#4 integrate
.. //depot/projects/smpng/sys/conf/newvers.sh#2 integrate
.. //depot/projects/smpng/sys/dev/aic7xxx/ahd_pci.c#5 integrate
.. //depot/projects/smpng/sys/dev/aic7xxx/aic79xx.reg#5 integrate
.. //depot/projects/smpng/sys/dev/aic7xxx/aic79xx.seq#5 integrate
.. //depot/projects/smpng/sys/dev/aic7xxx/aic79xx_osm.h#6 integrate
.. //depot/projects/smpng/sys/dev/aic7xxx/aic79xx_pci.c#5 integrate
.. //depot/projects/smpng/sys/dev/aic7xxx/aic7xxx_osm.h#7 integrate
.. //depot/projects/smpng/sys/dev/aic7xxx/aic7xxx_pci.c#7 integrate
.. //depot/projects/smpng/sys/dev/ata/ata-all.c#27 integrate
.. //depot/projects/smpng/sys/dev/ata/ata-card.c#5 integrate
.. //depot/projects/smpng/sys/dev/ata/ata-disk.c#23 integrate
.. //depot/projects/smpng/sys/dev/bktr/bktr_core.c#8 integrate
.. //depot/projects/smpng/sys/dev/bktr/bktr_os.c#9 integrate
.. //depot/projects/smpng/sys/dev/drm/drm_memory.h#2 integrate
.. //depot/projects/smpng/sys/dev/firewire/firewire.c#5 integrate
.. //depot/projects/smpng/sys/dev/firewire/fwohci.c#4 integrate
.. //depot/projects/smpng/sys/dev/firewire/fwohci_pci.c#5 integrate
.. //depot/projects/smpng/sys/dev/firewire/if_fwe.c#3 integrate
.. //depot/projects/smpng/sys/dev/firewire/sbp.c#5 integrate
.. //depot/projects/smpng/sys/dev/usb/ohci.c#19 integrate
.. //depot/projects/smpng/sys/fs/devfs/devfs.h#8 integrate
.. //depot/projects/smpng/sys/fs/devfs/devfs_devs.c#8 integrate
.. //depot/projects/smpng/sys/fs/devfs/devfs_vfsops.c#9 integrate
.. //depot/projects/smpng/sys/fs/devfs/devfs_vnops.c#23 integrate
.. //depot/projects/smpng/sys/i386/acpica/acpi_wakeup.c#13 integrate
.. //depot/projects/smpng/sys/i386/conf/GENERIC.hints#4 integrate
.. //depot/projects/smpng/sys/i386/isa/clock.c#20 integrate
.. //depot/projects/smpng/sys/ia64/conf/GENERIC#26 integrate
.. //depot/projects/smpng/sys/ia64/include/bootinfo.h#5 integrate
.. //depot/projects/smpng/sys/kern/kern_mac.c#12 integrate
.. //depot/projects/smpng/sys/kern/vfs_subr.c#39 integrate
.. //depot/projects/smpng/sys/modules/Makefile#40 integrate
.. //depot/projects/smpng/sys/net/if_gre.h#4 integrate
.. //depot/projects/smpng/sys/netinet/ip_gre.c#6 integrate
.. //depot/projects/smpng/sys/netsmb/smb_smb.c#6 integrate
.. //depot/projects/smpng/sys/nfsserver/nfs_serv.c#23 integrate
.. //depot/projects/smpng/sys/pc98/i386/machdep.c#47 integrate
.. //depot/projects/smpng/sys/security/mac_biba/mac_biba.c#10 integrate
.. //depot/projects/smpng/sys/security/mac_lomac/mac_lomac.c#2 integrate
.. //depot/projects/smpng/sys/security/mac_mls/mac_mls.c#10 integrate
.. //depot/projects/smpng/sys/security/mac_none/mac_none.c#7 integrate
.. //depot/projects/smpng/sys/security/mac_test/mac_test.c#7 integrate
.. //depot/projects/smpng/sys/sparc64/pci/psycho.c#14 integrate
.. //depot/projects/smpng/sys/sys/mac.h#11 integrate
.. //depot/projects/smpng/sys/sys/mac_policy.h#10 integrate
.. //depot/projects/smpng/sys/ufs/ffs/ffs_alloc.c#17 integrate

Differences ...

==== //depot/projects/smpng/sys/boot/efi/include/efiapi.h#5 (text+ko) ====

@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/boot/efi/include/efiapi.h,v 1.4 2002/05/19 03:17:20 marcel Exp $ */
+/* $FreeBSD: src/sys/boot/efi/include/efiapi.h,v 1.5 2002/12/08 20:47:44 marcel Exp $ */
 #ifndef _EFI_API_H
 #define _EFI_API_H
 
@@ -658,6 +658,9 @@
 #define SAL_SYSTEM_TABLE_GUID    \
     { 0xeb9d2d32, 0x2d88, 0x11d3, { 0x9a, 0x16, 0x0, 0x90, 0x27, 0x3f, 0xc1, 0x4d } }
 
+/* DIG64 Headless Console & Debug Port Table. */
+#define	HCDP_TABLE_GUID		\
+	{0xf951938d,0x620b,0x42ef,{0x82,0x79,0xa8,0x4b,0x79,0x61,0x78,0x98}}
 
 typedef struct _EFI_CONFIGURATION_TABLE {
     EFI_GUID                VendorGuid;

==== //depot/projects/smpng/sys/boot/efi/libefi/efi_console.c#2 (text+ko) ====

@@ -26,7 +26,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-  "$FreeBSD: src/sys/boot/efi/libefi/efi_console.c,v 1.2 2001/06/16 05:56:13 obrien Exp $";
+  "$FreeBSD: src/sys/boot/efi/libefi/efi_console.c,v 1.3 2002/12/08 19:46:11 marcel Exp $";
 #endif /* not lint */
 
 #include <efi.h>
@@ -69,17 +69,23 @@
 efi_cons_getchar()
 {
 	EFI_INPUT_KEY key;
+	EFI_STATUS status;
 	UINTN junk;
 
-	BS->WaitForEvent(1, &conin->WaitForKey, &junk);
-	conin->ReadKeyStroke(conin, &key);
-	return key.UnicodeChar;
+	/* Try to read a key stroke. We wait for one if none is pending. */
+	status = conin->ReadKeyStroke(conin, &key);
+	if (status == EFI_NOT_READY) {
+		BS->WaitForEvent(1, &conin->WaitForKey, &junk);
+		status = conin->ReadKeyStroke(conin, &key);
+	}
+	return (key.UnicodeChar);
 }
 
 int
 efi_cons_poll()
 {
-	return BS->CheckEvent(conin->WaitForKey) == EFI_SUCCESS;
+	/* This can clear the signaled state. */
+	return (BS->CheckEvent(conin->WaitForKey) == EFI_SUCCESS);
 }
 
 struct console efi_console = {

==== //depot/projects/smpng/sys/boot/efi/loader/main.c#7 (text+ko) ====

@@ -27,7 +27,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-  "$FreeBSD: src/sys/boot/efi/loader/main.c,v 1.12 2002/11/24 19:45:05 marcel Exp $";
+  "$FreeBSD: src/sys/boot/efi/loader/main.c,v 1.13 2002/12/08 20:04:00 marcel Exp $";
 #endif /* not lint */
 
 #include <stand.h>
@@ -174,12 +174,16 @@
 
 	currdev.d_type = currdev.d_dev->dv_type;
 
-#if 0
-	/* Create arc-specific variables */
-	bootfile = GetEnvironmentVariable(ARCENV_BOOTFILE);
-	if (bootfile)
-		setenv("bootfile", bootfile, 1);
-#endif
+	/*
+	 * Disable the watchdog timer. By default the boot manager sets
+	 * the timer to 5 minutes before invoking a boot option. If we
+	 * want to return to the boot manager, we have to disable the
+	 * watchdog timer and since we're an interactive program, we don't
+	 * want to wait until the user types "quit". The timer may have
+	 * fired by then. We don't care if this fails. It does not prevent
+	 * normal functioning in any way...
+	 */
+	BS->SetWatchdogTimer(0, 0, 0, NULL);
 
 	env_setenv("currdev", EV_VOLATILE, efi_fmtdev(&currdev),
 	    efi_setcurrdev, env_nounset);

==== //depot/projects/smpng/sys/boot/libstand/libstand.3#2 (text+ko) ====

@@ -22,7 +22,7 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.\" $FreeBSD: src/sys/boot/libstand/libstand.3,v 1.21 2002/06/02 10:05:55 schweikh Exp $
+.\" $FreeBSD: src/sys/boot/libstand/libstand.3,v 1.22 2002/12/05 08:50:00 ru Exp $
 .\"
 .Dd June 22, 1998
 .Dt LIBSTAND 3
@@ -224,7 +224,8 @@
 .Fa size
 characters into
 .Fa buf .
-Line terminating characters are stripped, and the buffer is always nul
+Line terminating characters are stripped, and the buffer is always
+.Dv NUL
 terminated.  Returns the number of characters in
 .Fa buf
 if successful, or -1 if a read error occurs.
@@ -429,7 +430,9 @@
 .Fn pager_output "char *lines"
 .Xc
 .Pp
-Sends the lines in the nul-terminated buffer at
+Sends the lines in the
+.Dv NUL Ns
+-terminated buffer at
 .Fa lines
 to the pager.  Newline characters are counted in order to determine the number
 of lines being output (wrapped lines are not accounted for).

==== //depot/projects/smpng/sys/compat/linux/linux_file.c#14 (text+ko) ====

@@ -25,7 +25,7 @@
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  *
- * $FreeBSD: src/sys/compat/linux/linux_file.c,v 1.71 2002/09/02 22:46:05 iedowse Exp $
+ * $FreeBSD: src/sys/compat/linux/linux_file.c,v 1.72 2002/12/08 18:30:44 iedowse Exp $
  */
 
 #include "opt_compat.h"
@@ -931,6 +931,8 @@
 static int
 fcntl_common(struct thread *td, struct linux_fcntl64_args *args)
 {
+	struct l_flock linux_flock;
+	struct flock bsd_flock;
 	struct file *fp;
 	long arg;
 	int error, result;
@@ -977,6 +979,37 @@
 			arg |= O_ASYNC;
 		return (kern_fcntl(td, args->fd, F_SETFL, arg));
 
+	case LINUX_F_GETLK:
+		error = copyin((caddr_t)args->arg, &linux_flock,
+		    sizeof(linux_flock));
+		if (error)
+			return (error);
+		linux_to_bsd_flock(&linux_flock, &bsd_flock);
+		error = kern_fcntl(td, args->fd, F_GETLK, (intptr_t)&bsd_flock);
+		if (error)
+			return (error);
+		bsd_to_linux_flock(&bsd_flock, &linux_flock);
+		return (copyout(&linux_flock, (caddr_t)args->arg,
+		    sizeof(linux_flock)));
+
+	case LINUX_F_SETLK:
+		error = copyin((caddr_t)args->arg, &linux_flock,
+		    sizeof(linux_flock));
+		if (error)
+			return (error);
+		linux_to_bsd_flock(&linux_flock, &bsd_flock);
+		return (kern_fcntl(td, args->fd, F_SETLK,
+		    (intptr_t)&bsd_flock));
+
+	case LINUX_F_SETLKW:
+		error = copyin((caddr_t)args->arg, &linux_flock,
+		    sizeof(linux_flock));
+		if (error)
+			return (error);
+		linux_to_bsd_flock(&linux_flock, &bsd_flock);
+		return (kern_fcntl(td, args->fd, F_SETLKW,
+		     (intptr_t)&bsd_flock));
+
 	case LINUX_F_GETOWN:
 		return (kern_fcntl(td, args->fd, F_GETOWN, 0));
 
@@ -1005,48 +1038,12 @@
 linux_fcntl(struct thread *td, struct linux_fcntl_args *args)
 {
 	struct linux_fcntl64_args args64;
-	struct l_flock linux_flock;
-	struct flock bsd_flock;
-	int error;
 
 #ifdef DEBUG
 	if (ldebug(fcntl))
 		printf(ARGS(fcntl, "%d, %08x, *"), args->fd, args->cmd);
 #endif
 
-	switch (args->cmd) {
-	case LINUX_F_GETLK:
-		error = copyin((caddr_t)args->arg, &linux_flock,
-		    sizeof(linux_flock));
-		if (error)
-			return (error);
-		linux_to_bsd_flock(&linux_flock, &bsd_flock);
-		error = kern_fcntl(td, args->fd, F_GETLK, (intptr_t)&bsd_flock);
-		if (error)
-			return (error);
-		bsd_to_linux_flock(&bsd_flock, &linux_flock);
-		return (copyout(&linux_flock, (caddr_t)args->arg,
-		    sizeof(linux_flock)));
-
-	case LINUX_F_SETLK:
-		error = copyin((caddr_t)args->arg, &linux_flock,
-		    sizeof(linux_flock));
-		if (error)
-			return (error);
-		linux_to_bsd_flock(&linux_flock, &bsd_flock);
-		return (kern_fcntl(td, args->fd, F_SETLK,
-		    (intptr_t)&bsd_flock));
-
-	case LINUX_F_SETLKW:
-		error = copyin((caddr_t)args->arg, &linux_flock,
-		    sizeof(linux_flock));
-		if (error)
-			return (error);
-		linux_to_bsd_flock(&linux_flock, &bsd_flock);
-		return (kern_fcntl(td, args->fd, F_SETLKW,
-		     (intptr_t)&bsd_flock));
-	}
-
 	args64.fd = args->fd;
 	args64.cmd = args->cmd;
 	args64.arg = args->arg;
@@ -1067,7 +1064,6 @@
 #endif
 
 	switch (args->cmd) {
-	case LINUX_F_GETLK:
 	case LINUX_F_GETLK64:
 		error = copyin((caddr_t)args->arg, &linux_flock,
 		    sizeof(linux_flock));
@@ -1081,7 +1077,6 @@
 		return (copyout(&linux_flock, (caddr_t)args->arg,
 		    sizeof(linux_flock)));
 
-	case LINUX_F_SETLK:
 	case LINUX_F_SETLK64:
 		error = copyin((caddr_t)args->arg, &linux_flock,
 		    sizeof(linux_flock));
@@ -1091,7 +1086,6 @@
 		return (kern_fcntl(td, args->fd, F_SETLK,
 		    (intptr_t)&bsd_flock));
 
-	case LINUX_F_SETLKW:
 	case LINUX_F_SETLKW64:
 		error = copyin((caddr_t)args->arg, &linux_flock,
 		    sizeof(linux_flock));

==== //depot/projects/smpng/sys/conf/NOTES#30 (text+ko) ====

@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/NOTES,v 1.1117 2002/11/26 17:32:39 rwatson Exp $
+# $FreeBSD: src/sys/conf/NOTES,v 1.1118 2002/12/09 03:38:03 rwatson Exp $
 #
 # NOTES -- Lines that can be cut/pasted into kernel and hints configs.
 #
@@ -737,6 +737,9 @@
 #
 # Enabling this will probably not give an overall speedup except for
 # special workloads.
+#
+# WARNING: Do not enable this, it is known to be broken, and will result
+# in system instability, as well as possible data loss.
 options 	ENABLE_VFS_IOOPT
 
 # Cryptographically secure random number generator; /dev/[u]random

==== //depot/projects/smpng/sys/conf/ldscript.ia64#4 (text+ko) ====

@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/conf/ldscript.ia64,v 1.6 2002/10/19 19:32:21 marcel Exp $ */
+/* $FreeBSD: src/sys/conf/ldscript.ia64,v 1.8 2002/12/05 18:35:44 obrien Exp $ */
 OUTPUT_FORMAT("elf64-ia64-little", "elf64-ia64-little", "elf64-ia64-little")
 OUTPUT_ARCH(ia64)
 ENTRY(__start)

==== //depot/projects/smpng/sys/conf/newvers.sh#2 (text+ko) ====

@@ -32,11 +32,11 @@
 # SUCH DAMAGE.
 #
 #	@(#)newvers.sh	8.1 (Berkeley) 4/20/94
-# $FreeBSD: src/sys/conf/newvers.sh,v 1.47 2001/03/02 16:52:13 ru Exp $
+# $FreeBSD: src/sys/conf/newvers.sh,v 1.48 2002/12/05 05:27:49 murray Exp $
 
 TYPE="FreeBSD"
 REVISION="5.0"
-BRANCH="CURRENT"
+BRANCH="RC"
 RELEASE="${REVISION}-${BRANCH}"
 VERSION="${TYPE} ${RELEASE}"
 

==== //depot/projects/smpng/sys/dev/aic7xxx/ahd_pci.c#5 (text+ko) ====

@@ -28,9 +28,9 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $Id: //depot/aic7xxx/freebsd/dev/aic7xxx/ahd_pci.c#9 $
+ * $Id: //depot/aic7xxx/freebsd/dev/aic7xxx/ahd_pci.c#10 $
  *
- * $FreeBSD: src/sys/dev/aic7xxx/ahd_pci.c,v 1.5 2002/12/01 07:52:35 scottl Exp $
+ * $FreeBSD: src/sys/dev/aic7xxx/ahd_pci.c,v 1.6 2002/12/04 22:51:29 scottl Exp $
  */
 
 #include <dev/aic7xxx/aic79xx_osm.h>
@@ -150,14 +150,26 @@
 	int	regs_type;
 	int	regs_id;
 	int	regs_id2;
+	int	allow_memio;
 
 	command = ahd_pci_read_config(ahd->dev_softc, PCIR_COMMAND, /*bytes*/1);
 	regs = NULL;
 	regs2 = NULL;
 	regs_type = 0;
 	regs_id = 0;
+
+	/* Retrieve the per-device 'allow_memio' hint */
+	if (resource_int_value(device_get_name(ahd->dev_softc),
+			       device_get_unit(ahd->dev_softc),
+			       "allow_memio", &allow_memio) != 0) {
+		if (bootverbose)
+			device_printf(ahd->dev_softc,
+				      "Defaulting to MEMIO on\n");
+	}
+
 	if ((command & PCIM_CMD_MEMEN) != 0
-	 && (ahd->bugs & AHD_PCIX_MMAPIO_BUG) == 0) {
+	 && (ahd->bugs & AHD_PCIX_MMAPIO_BUG) == 0
+	 && allow_memio != 0) {
 
 		regs_type = SYS_RES_MEMORY;
 		regs_id = AHD_PCI_MEMADDR;

==== //depot/projects/smpng/sys/dev/aic7xxx/aic79xx.reg#5 (text+ko) ====

@@ -37,9 +37,9 @@
  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGES.
  *
- * $FreeBSD: src/sys/dev/aic7xxx/aic79xx.reg,v 1.4 2002/12/01 08:13:37 scottl Exp $
+ * $FreeBSD: src/sys/dev/aic7xxx/aic79xx.reg,v 1.5 2002/12/04 22:51:29 scottl Exp $
  */
-VERSION = "$Id: //depot/aic7xxx/aic7xxx/aic79xx.reg#55 $"
+VERSION = "$Id: //depot/aic7xxx/aic7xxx/aic79xx.reg#56 $"
 
 /*
  * This file is processed by the aic7xxx_asm utility for use in assembling
@@ -190,6 +190,7 @@
 	field	CLRHWERRINT	0x80 /* Rev B or greater */
 	field	CLRBRKADRINT	0x40
 	field	CLRSWTMINT	0x20
+	field	CLRPCIINT	0x10
 	field	CLRSCSIINT	0x08
 	field	CLRSEQINT	0x04
 	field	CLRCMDINT	0x02
@@ -1168,7 +1169,7 @@
  * PCI Status for Target
  */
 register TARGPCISTAT {
-	address			0x0A6
+	address			0x0A7
 	access_mode	RW
 	modes		M_CFG
 	field	DPE		0x80

==== //depot/projects/smpng/sys/dev/aic7xxx/aic79xx.seq#5 (text+ko) ====

@@ -37,10 +37,10 @@
  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGES.
  *
- * $FreeBSD: src/sys/dev/aic7xxx/aic79xx.seq,v 1.4 2002/12/01 08:13:37 scottl Exp $
+ * $FreeBSD: src/sys/dev/aic7xxx/aic79xx.seq,v 1.5 2002/12/05 00:47:27 scottl Exp $
  */
 
-VERSION = "$Id: //depot/aic7xxx/aic7xxx/aic79xx.seq#72 $"
+VERSION = "$Id: //depot/aic7xxx/aic7xxx/aic79xx.seq#73 $"
 PATCH_ARG_LIST = "struct ahd_softc *ahd"
 PREFIX = "ahd_"
 
@@ -62,8 +62,9 @@
 		 * interrupt collision on the hardware
 		 * setting of HWERR.
 		 */
-		test	ERROR, 0xFF jz . + 2;
+		test	ERROR, 0xFF jz no_error_set;
 		SET_SEQINTCODE(SAW_HWERR)
+no_error_set:
 	}
 	SET_MODE(M_SCSI, M_SCSI)
 	test	SCSISEQ0, ENSELO|ENARBO jnz idle_loop_checkbus;
@@ -937,8 +938,9 @@
 	/*
 	 * See if we attempted to deliver a message but the target ingnored us.
 	 */
-	test	SCB_CONTROL, MK_MESSAGE jz . + 2;
+	test	SCB_CONTROL, MK_MESSAGE jz complete_nomsg;
 	SET_SEQINTCODE(MKMSG_FAILED)
+complete_nomsg:
 	call	queue_scb_completion;
 	jmp	await_busfree;
 

==== //depot/projects/smpng/sys/dev/aic7xxx/aic79xx_osm.h#6 (text+ko) ====

@@ -30,9 +30,9 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $Id: //depot/aic7xxx/freebsd/dev/aic7xxx/aic79xx_osm.h#18 $
+ * $Id: //depot/aic7xxx/freebsd/dev/aic7xxx/aic79xx_osm.h#19 $
  *
- * $FreeBSD: src/sys/dev/aic7xxx/aic79xx_osm.h,v 1.7 2002/12/01 07:50:56 scottl Exp $
+ * $FreeBSD: src/sys/dev/aic7xxx/aic79xx_osm.h,v 1.8 2002/12/04 22:51:29 scottl Exp $
  */
 
 #ifndef _AIC79XX_FREEBSD_H_
@@ -239,8 +239,9 @@
 static __inline void
 ahd_scb_timer_reset(struct scb *scb, u_int usec)
 {
-	callout_reset(scb->io_ctx->ccb_h.timeout_ch.callout,
-		      (usec * hz)/1000000, ahd_timeout, scb);
+	untimeout(ahd_timeout, (caddr_t)scb, scb->io_ctx->ccb_h.timeout_ch);
+	scb->io_ctx->ccb_h.timeout_ch =
+	    timeout(ahd_timeout, scb, (usec * hz)/1000000);
 }
 
 /*************************** Device Access ************************************/

==== //depot/projects/smpng/sys/dev/aic7xxx/aic79xx_pci.c#5 (text+ko) ====

@@ -38,9 +38,9 @@
  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGES.
  *
- * $Id: //depot/aic7xxx/aic7xxx/aic79xx_pci.c#54 $
+ * $Id: //depot/aic7xxx/aic7xxx/aic79xx_pci.c#60 $
  *
- * $FreeBSD: src/sys/dev/aic7xxx/aic79xx_pci.c,v 1.5 2002/12/01 07:59:01 scottl Exp $
+ * $FreeBSD: src/sys/dev/aic7xxx/aic79xx_pci.c,v 1.6 2002/12/04 22:51:29 scottl Exp $
  */
 
 #ifdef __linux__
@@ -175,8 +175,8 @@
 	},
 	/* Generic chip probes for devices we don't know 'exactly' */
 	{
-		ID_AIC7901A & ID_ALL_MASK,
-		ID_ALL_MASK,
+		ID_AIC7901A & ID_DEV_VENDOR_MASK,
+		ID_DEV_VENDOR_MASK,
 		"Adaptec AIC7901A Ultra320 SCSI adapter",
 		ahd_aic7901A_setup
 	},
@@ -378,7 +378,16 @@
 int
 ahd_pci_test_register_access(struct ahd_softc *ahd)
 {
-	int i;
+	ahd_mode_state	saved_modes;
+	int		error;
+	uint8_t		seqctl;
+
+	saved_modes = ahd_save_modes(ahd);
+	error = EIO;
+
+	/* Enable PCI error interrupt status */
+	seqctl = ahd_inb(ahd, SEQCTL0);
+	ahd_outb(ahd, SEQCTL0, seqctl & ~FAILDIS);
 
 	/*
 	 * First a simple test to see if any
@@ -389,7 +398,7 @@
 	 * use for this test.
 	 */
 	if (ahd_inb(ahd, HCNTRL) == 0xFF)
-		return (EIO);
+		goto fail;
 
 	/*
 	 * Next create a situation where write combining
@@ -398,19 +407,26 @@
 	 * either, so look for data corruption and/or flaged
 	 * PCI errors.
 	 */
-	for (i = 0; i < 16; i++)
-	       ahd_outb(ahd, SRAM_BASE + i, i);
+	ahd_outl(ahd, SRAM_BASE, 0x5aa555aa);
+	if (ahd_inl(ahd, SRAM_BASE) != 0x5aa555aa)
+		goto fail;
+
+	if ((ahd_inb(ahd, INTSTAT) & PCIINT) != 0) {
+		u_int targpcistat;
+
+		ahd_set_modes(ahd, AHD_MODE_CFG, AHD_MODE_CFG);
+		targpcistat = ahd_inb(ahd, TARGPCISTAT);
+		if ((targpcistat & STA) != 0)
+			goto fail;
+	}
 
-	for (i = 0; i < 16; i++)
-		if (ahd_inb(ahd, SRAM_BASE + i) != i)
-			return (EIO);
+	error = 0;
 
+fail:
 	if ((ahd_inb(ahd, INTSTAT) & PCIINT) != 0) {
-		ahd_mode_state	saved_modes;
-		u_int		targpcistat;
-		u_int		pci_status1;
+		u_int targpcistat;
+		u_int pci_status1;
 
-		saved_modes = ahd_save_modes(ahd);
 		ahd_set_modes(ahd, AHD_MODE_CFG, AHD_MODE_CFG);
 		targpcistat = ahd_inb(ahd, TARGPCISTAT);
 
@@ -420,13 +436,12 @@
 						  PCIR_STATUS + 1, /*bytes*/1);
 		ahd_pci_write_config(ahd->dev_softc, PCIR_STATUS + 1,
 				     pci_status1, /*bytes*/1);
-		ahd_restore_modes(ahd, saved_modes);
-
-		if ((targpcistat & STA) != 0)
-			return (EIO);
+		ahd_outb(ahd, CLRINT, CLRPCIINT);
 	}
 
-	return (0);
+	ahd_restore_modes(ahd, saved_modes);
+	ahd_outb(ahd, SEQCTL0, seqctl);
+	return (error);
 }
 
 /*
@@ -731,7 +746,7 @@
 
 				s = pci_status_strings[bit];
 				if (i == 7/*TARG*/ && bit == 3)
-					s = "%s: Signal Target Abort\n";
+					s = "%s: Signaled Target Abort\n";
 				printf(s, ahd_name(ahd), pci_status_source[i]);
 			}
 		}	
@@ -741,6 +756,7 @@
 	ahd_pci_write_config(ahd->dev_softc, PCIR_STATUS + 1,
 			     pci_status1, /*bytes*/1);
 	ahd_restore_modes(ahd, saved_modes);
+	ahd_outb(ahd, CLRINT, CLRPCIINT);
 	ahd_unpause(ahd);
 }
 
@@ -810,6 +826,7 @@
 	 */
 	ahd_pci_write_config(ahd->dev_softc, PCIXR_STATUS,
 			     pcix_status, /*bytes*/2);
+	ahd_outb(ahd, CLRINT, CLRSPLTINT);
 	ahd_restore_modes(ahd, saved_modes);
 }
 

==== //depot/projects/smpng/sys/dev/aic7xxx/aic7xxx_osm.h#7 (text+ko) ====

@@ -29,9 +29,9 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- * $Id: //depot/aic7xxx/freebsd/dev/aic7xxx/aic7xxx_osm.h#13 $
+ * $Id: //depot/aic7xxx/freebsd/dev/aic7xxx/aic7xxx_osm.h#14 $
  *
- * $FreeBSD: src/sys/dev/aic7xxx/aic7xxx_osm.h,v 1.19 2002/11/30 19:06:24 scottl Exp $
+ * $FreeBSD: src/sys/dev/aic7xxx/aic7xxx_osm.h,v 1.20 2002/12/04 22:51:29 scottl Exp $
  */
 
 #ifndef _AIC7XXX_FREEBSD_H_
@@ -251,8 +251,9 @@
 static __inline void
 ahc_scb_timer_reset(struct scb *scb, u_int usec)
 {
-	callout_reset(scb->io_ctx->ccb_h.timeout_ch.callout,
-		      (usec * hz)/1000000, ahc_timeout, scb);
+	untimeout(ahc_timeout, (caddr_t)scb, scb->io_ctx->ccb_h.timeout_ch);
+	scb->io_ctx->ccb_h.timeout_ch =
+	    timeout(ahc_timeout, scb, (usec * hz)/1000000);
 }
 
 /*************************** Device Access ************************************/

==== //depot/projects/smpng/sys/dev/aic7xxx/aic7xxx_pci.c#7 (text+ko) ====

@@ -39,9 +39,9 @@
  * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGES.
  *
- * $Id: //depot/aic7xxx/aic7xxx/aic7xxx_pci.c#52 $
+ * $Id: //depot/aic7xxx/aic7xxx/aic7xxx_pci.c#53 $
  *
- * $FreeBSD: src/sys/dev/aic7xxx/aic7xxx_pci.c,v 1.20 2002/11/30 19:13:55 scottl Exp $
+ * $FreeBSD: src/sys/dev/aic7xxx/aic7xxx_pci.c,v 1.21 2002/12/04 22:51:29 scottl Exp $
  */
 
 #ifdef __linux__
@@ -1202,8 +1202,15 @@
 int
 ahc_pci_test_register_access(struct ahc_softc *ahc)
 {
-	int   i;
-	u_int status1;
+	int	error;
+	u_int	status1;
+	uint8_t	seqctl;
+
+	error = EIO;
+
+	/* Enable PCI error interrupt status */
+	seqctl = ahc_inb(ahc, SEQCTL);
+	ahc_outb(ahc, SEQCTL, seqctl & ~FAILDIS);
 
 	/*
 	 * First a simple test to see if any
@@ -1214,7 +1221,7 @@
 	 * use for this test.
 	 */
 	if (ahc_inb(ahc, HCNTRL) == 0xFF)
-		return (EIO);
+		goto fail;
 
 	/*
 	 * Next create a situation where write combining
@@ -1223,25 +1230,33 @@
 	 * either, so look for data corruption and/or flagged
 	 * PCI errors.
 	 */
-	for (i = 0; i < 16; i++)
-		ahc_outb(ahc, SRAM_BASE + i, i);
+	ahc_outb(ahc, SRAM_BASE, 0xaa);
+	ahc_outb(ahc, SRAM_BASE + 1, 0x55);
+	ahc_outb(ahc, SRAM_BASE + 2, 0xa5);
+	ahc_outb(ahc, SRAM_BASE + 3, 0x5a);
 
-	for (i = 0; i < 16; i++)
-		if (ahc_inb(ahc, SRAM_BASE + i) != i)
-			return (EIO);
+	if ((ahc_inb(ahc, SRAM_BASE) != 0xaa)
+	 || (ahc_inb(ahc, SRAM_BASE + 1) != 0x55)
+	 || (ahc_inb(ahc, SRAM_BASE + 2) != 0xa5)
+	 || (ahc_inb(ahc, SRAM_BASE + 3) != 0x5a))
+		goto fail;
 
 	status1 = ahc_pci_read_config(ahc->dev_softc,
 				      PCIR_STATUS + 1, /*bytes*/1);
-	if ((status1 & STA) != 0) {
+	if ((status1 & STA) != 0)
+		goto fail;
 
-		/* Silently clear any latched errors. */
-		ahc_pci_write_config(ahc->dev_softc, PCIR_STATUS + 1,
-				     status1, /*bytes*/1);
-		ahc_outb(ahc, CLRINT, CLRPARERR);
-		return (EIO);
-	}
+	error = 0;
 
-	return (0);
+fail:
+	/* Silently clear any latched errors. */
+	status1 = ahc_pci_read_config(ahc->dev_softc,
+				      PCIR_STATUS + 1, /*bytes*/1);
+	ahc_pci_write_config(ahc->dev_softc, PCIR_STATUS + 1,
+			     status1, /*bytes*/1);
+	ahc_outb(ahc, CLRINT, CLRPARERR);
+	ahc_outb(ahc, SEQCTL, seqctl);
+	return (error);
 }
 
 /*

==== //depot/projects/smpng/sys/dev/ata/ata-all.c#27 (text+ko) ====

@@ -25,7 +25,7 @@
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  *
- * $FreeBSD: src/sys/dev/ata/ata-all.c,v 1.160 2002/12/03 20:19:37 sos Exp $
+ * $FreeBSD: src/sys/dev/ata/ata-all.c,v 1.161 2002/12/06 19:29:52 sos Exp $
  */
 
 #include "opt_ata.h"
@@ -611,7 +611,9 @@
 	free(ata_delayed_attach, M_TEMP);
 	ata_delayed_attach = NULL;
     }
+#ifdef DEV_ATADISK
     ata_raid_attach();
+#endif
 }
 
 static void

==== //depot/projects/smpng/sys/dev/ata/ata-card.c#5 (text+ko) ====

@@ -25,7 +25,7 @@
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  *
- * $FreeBSD: src/sys/dev/ata/ata-card.c,v 1.6 2002/09/20 18:08:57 phk Exp $
+ * $FreeBSD: src/sys/dev/ata/ata-card.c,v 1.7 2002/12/06 19:29:53 sos Exp $
  */
 
 #include <sys/param.h>
@@ -58,8 +58,18 @@
 	return (0);
 
     /* other devices might need to be matched here */
+    return(ENXIO);
+}
+
+static int
+ata_pccard_intrnoop(struct ata_channel *ch)
+{
+    return 1;
+}
 
-    return(ENXIO);
+static void
+ata_pccard_locknoop(struct ata_channel *ch, int type)
+{
 }
 
 static int
@@ -106,6 +116,8 @@
 
     ch->unit = 0;
     ch->flags |= (ATA_USE_16BIT | ATA_NO_SLAVE);
+    ch->intr_func = ata_pccard_intrnoop;
+    ch->lock_func = ata_pccard_locknoop;
     return ata_probe(dev);
 }
 

==== //depot/projects/smpng/sys/dev/ata/ata-disk.c#23 (text+ko) ====

@@ -25,7 +25,7 @@
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  *
- * $FreeBSD: src/sys/dev/ata/ata-disk.c,v 1.137 2002/12/03 20:19:37 sos Exp $
+ * $FreeBSD: src/sys/dev/ata/ata-disk.c,v 1.138 2002/12/06 19:29:53 sos Exp $
  */
 
 #include "opt_ata.h"
@@ -219,8 +219,10 @@
     /* if this disk belongs to an ATA RAID dont print the probe */
     if (ata_raiddisk_attach(adp))
 	adp->flags |= AD_F_RAID_SUBDISK;
-    else
-	ad_print(adp);
+    else {
+	if (atadev->driver)
+	    ad_print(adp);
+    }
 }
 
 void

==== //depot/projects/smpng/sys/dev/bktr/bktr_core.c#8 (text+ko) ====

@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/dev/bktr/bktr_core.c,v 1.123 2002/11/06 20:16:39 jhb Exp $ */
+/* $FreeBSD: src/sys/dev/bktr/bktr_core.c,v 1.124 2002/12/07 09:00:19 roger Exp $ */
 
 /*
  * This is part of the Driver for Video Capture Cards (Frame grabbers)
@@ -810,7 +810,6 @@
 
 	}
 
-
 	/*
 	 *  Register the completed field
 	 *    (For dual-field mode, require fields from the same frame)
@@ -3087,7 +3086,7 @@
 
 	/* contruct sync : for video packet format */
 	/* sync, mode indicator packed data */
-	*dma_prog++ = OP_SYNC | 1 << 15 | BKTR_FM1;
+	*dma_prog++ = OP_SYNC | BKTR_RESYNC | BKTR_FM1;
 	*dma_prog++ = 0;  /* NULL WORD */
 
 	b = cols;
@@ -3103,7 +3102,7 @@
 	switch (i_flag) {
 	case 1:
 		/* sync vre */
-		*dma_prog++ = OP_SYNC  | 1 << 24 | BKTR_VRE;
+		*dma_prog++ = OP_SYNC  | BKTR_GEN_IRQ | BKTR_VRE;
 		*dma_prog++ = 0;  /* NULL WORD */
 
 		*dma_prog++ = OP_JUMP;
@@ -3112,7 +3111,7 @@
 
 	case 2:
 		/* sync vro */
-		*dma_prog++ = OP_SYNC  | 1 << 24 | BKTR_VRO;
+		*dma_prog++ = OP_SYNC  | BKTR_GEN_IRQ | BKTR_VRO;
 		*dma_prog++ = 0;  /* NULL WORD */
 		*dma_prog++ = OP_JUMP;
 		*dma_prog++ = (u_long ) vtophys(bktr->dma_prog);
@@ -3120,7 +3119,7 @@
 
 	case 3:
 		/* sync vro */
-		*dma_prog++ = OP_SYNC	 | 1 << 24 | 1 << 15 | BKTR_VRO;
+		*dma_prog++ = OP_SYNC | BKTR_GEN_IRQ | BKTR_RESYNC | BKTR_VRO;
 		*dma_prog++ = 0;  /* NULL WORD */
 		*dma_prog++ = OP_JUMP  ;
 		*dma_prog = (u_long ) vtophys(bktr->odd_dma_prog);
@@ -3134,7 +3133,7 @@
 		dma_prog = (u_long * ) bktr->odd_dma_prog;
 
 		/* sync vre */
-		*dma_prog++ = OP_SYNC | 1 << 24 |  1 << 15 | BKTR_FM1;
+		*dma_prog++ = OP_SYNC | BKTR_RESYNC | BKTR_FM1;
 		*dma_prog++ = 0;  /* NULL WORD */
 
 		for (i = 0; i < (rows/interlace) ; i++) {
@@ -3147,7 +3146,7 @@
 	}
 
 	/* sync vro IRQ bit */
-	*dma_prog++ = OP_SYNC   |  1 << 24  | 1 << 15 |  BKTR_VRE;
+	*dma_prog++ = OP_SYNC   |  BKTR_GEN_IRQ  | BKTR_RESYNC |  BKTR_VRE;
 	*dma_prog++ = 0;  /* NULL WORD */
 	*dma_prog++ = OP_JUMP ;
 	*dma_prog++ = (u_long ) vtophys(bktr->dma_prog);

==== //depot/projects/smpng/sys/dev/bktr/bktr_os.c#9 (text+ko) ====

@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/dev/bktr/bktr_os.c,v 1.30 2002/09/28 17:14:25 phk Exp $ */
+/* $FreeBSD: src/sys/dev/bktr/bktr_os.c,v 1.31 2002/12/09 09:04:09 roger Exp $ */
 
 /*
  * This is part of the Driver for Video Capture Cards (Frame grabbers)
@@ -494,20 +494,12 @@
 	/* The memory is retained by the bktr_mem module so we can unload and */
 	/* then reload the main bktr driver module */
 
-	/* Unregister the /dev/bktrN, tunerN and vbiN devices */
+	/* Unregister the /dev/bktrN, tunerN and vbiN devices,
+	 * the aliases for unit 0 are automatically destroyed */
 	destroy_dev(bktr->vbidev);
 	destroy_dev(bktr->tunerdev);
 	destroy_dev(bktr->bktrdev);
 
-	/* If this is unit 0, then destroy the alias entries too */
-#if (__FreeBSD_version >=500000)
-	if (unit == 0) {
-	    destroy_dev(bktr->vbidev_alias);
-	    destroy_dev(bktr->tunerdev_alias);
-	    destroy_dev(bktr->bktrdev_alias);
-	}
-#endif
-
 	/*
 	 * Deallocate resources.
 	 */

==== //depot/projects/smpng/sys/dev/drm/drm_memory.h#2 (text+ko) ====

@@ -28,7 +28,7 @@
  *    Rickard E. (Rik) Faith <faith@valinux.com>
  *    Gareth Hughes <gareth@valinux.com>
  *
- * $FreeBSD: src/sys/dev/drm/drm_memory.h,v 1.2 2002/04/29 00:25:10 anholt Exp $
+ * $FreeBSD: src/sys/dev/drm/drm_memory.h,v 1.4 2002/12/04 23:39:05 anholt Exp $
  */
 
 #define __NO_VERSION__
@@ -125,53 +125,10 @@
 	DRM(ram_used)	   = 0;
 }
 
-/* drm_mem_info is called whenever a process reads /dev/drm/mem. */
-#ifdef __linux__
-static int DRM(_mem_info)(char *buf, char **start, off_t offset,
-			  int request, int *eof, void *data)
-{
-	drm_mem_stats_t *pt;
-	int             len = 0;
-
-	if (offset > DRM_PROC_LIMIT) {
-		*eof = 1;
-		return 0;
-	}
-
-	*eof   = 0;
-	*start = &buf[offset];
-
-	DRM_PROC_PRINT("		  total counts			"
-		       " |    outstanding  \n");
-	DRM_PROC_PRINT("type	   alloc freed fail	bytes	   freed"
-		       " | allocs      bytes\n\n");
-	DRM_PROC_PRINT("%-9.9s %5d %5d %4d %10lu kB         |\n",
-		       "system", 0, 0, 0,
-		       DRM(ram_available) << (PAGE_SHIFT - 10));
-	DRM_PROC_PRINT("%-9.9s %5d %5d %4d %10lu kB         |\n",
-		       "locked", 0, 0, 0, DRM(ram_used) >> 10);
-	DRM_PROC_PRINT("\n");
-	for (pt = DRM(mem_stats); pt->name; pt++) {
-		DRM_PROC_PRINT("%-9.9s %5d %5d %4d %10lu %10lu | %6d %10ld\n",
-			       pt->name,
-			       pt->succeed_count,
-			       pt->free_count,
-			       pt->fail_count,
-			       pt->bytes_allocated,
-			       pt->bytes_freed,
-			       pt->succeed_count - pt->free_count,
-			       (long)pt->bytes_allocated
-			       - (long)pt->bytes_freed);
-	}
-
-	if (len > request + offset) return request;

>>> TRUNCATED FOR MAIL (1000 lines) <<<

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe p4-projects" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200212092144.gB9LioSd079511>