Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 7 Mar 2004 15:27:38 -0800 (PST)
From:      Juli Mallett <jmallett@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 48375 for review
Message-ID:  <200403072327.i27NRcrx027695@repoman.freebsd.org>

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

Change 48375 by jmallett@jmallett_oingo on 2004/03/07 15:26:45

	IFC.

Affected files ...

.. //depot/projects/mips/lib/libc/stdlib/malloc.c#8 integrate
.. //depot/projects/mips/lib/libgeom/Makefile#7 integrate
.. //depot/projects/mips/lib/libgeom/libgeom.3#5 integrate
.. //depot/projects/mips/share/man/man9/Makefile#17 integrate
.. //depot/projects/mips/share/man/man9/securelevel_gt.9#1 branch
.. //depot/projects/mips/share/misc/bsd-family-tree#11 integrate
.. //depot/projects/mips/sys/alpha/alpha/pmap.c#12 integrate
.. //depot/projects/mips/sys/amd64/amd64/pmap.c#6 integrate
.. //depot/projects/mips/sys/dev/trm/trm.c#10 integrate
.. //depot/projects/mips/sys/dev/trm/trm.h#4 integrate
.. //depot/projects/mips/sys/geom/geom_subr.c#20 integrate
.. //depot/projects/mips/sys/i386/i386/pmap.c#22 integrate
.. //depot/projects/mips/sys/ia64/ia64/pmap.c#17 integrate
.. //depot/projects/mips/sys/netgraph/ng_iface.c#8 integrate
.. //depot/projects/mips/sys/netgraph/ng_iface.h#4 integrate
.. //depot/projects/mips/sys/nfsserver/nfs.h#3 integrate
.. //depot/projects/mips/sys/nfsserver/nfs_srvsock.c#7 integrate
.. //depot/projects/mips/sys/nfsserver/nfs_srvsubs.c#9 integrate
.. //depot/projects/mips/sys/pc98/pc98/wd_cd.h#2 integrate
.. //depot/projects/mips/sys/powerpc/powerpc/pmap.c#11 integrate
.. //depot/projects/mips/sys/rpc/rpcclnt.c#4 integrate
.. //depot/projects/mips/sys/sparc64/sparc64/pmap.c#13 integrate
.. //depot/projects/mips/sys/vm/pmap.h#9 integrate
.. //depot/projects/mips/sys/vm/vm_glue.c#11 integrate
.. //depot/projects/mips/sys/vm/vm_map.c#18 integrate
.. //depot/projects/mips/usr.bin/printf/printf.c#2 integrate
.. //depot/projects/mips/usr.sbin/mergemaster/mergemaster.sh#10 integrate

Differences ...

==== //depot/projects/mips/lib/libc/stdlib/malloc.c#8 (text+ko) ====

@@ -9,7 +9,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/lib/libc/stdlib/malloc.c,v 1.86 2004/02/21 09:14:38 phk Exp $");
+__FBSDID("$FreeBSD: src/lib/libc/stdlib/malloc.c,v 1.87 2004/03/07 20:41:27 phk Exp $");
 
 /*
  * Defining MALLOC_EXTRA_SANITY will enable extra checks which are related
@@ -198,9 +198,6 @@
 #define INIT_MMAP()
 #endif
 
-/* Set when initialization has been done */
-static unsigned malloc_started;
-
 /* Number of free pages we cache */
 static unsigned malloc_cache = 16;
 
@@ -491,9 +488,6 @@
 
     malloc_ninfo = malloc_pagesize / sizeof *page_dir;
 
-    /* Been here, done that */
-    malloc_started++;
-
     /* Recalculate the cache size in bytes, and make sure it's nonzero */
 
     if (!malloc_cache)
@@ -729,9 +723,6 @@
 {
     void *result;
 
-    if (!malloc_started)
-	malloc_init();
-
     if (suicide)
 	abort();
 
@@ -764,11 +755,6 @@
     if (suicide)
 	abort();
 
-    if (!malloc_started) {
-	wrtwarning("malloc() has never been called\n");
-	return (NULL);
-    }
-
     index = ptr2index(ptr);
 
     if (index < malloc_pageshift) {
@@ -1061,11 +1047,6 @@
     if (ptr == NULL)
 	return;
 
-    if (!malloc_started) {
-	wrtwarning("malloc() has never been called\n");
-	return;
-    }
-
     /* If we're already sinking, don't make matters any worse. */
     if (suicide)
 	return;
@@ -1097,6 +1078,7 @@
     void *r;
     int err = 0;
     static int malloc_active; /* Recusion flag for public interface. */
+    static unsigned malloc_started; /* Set when initialization has been done */
 
     /*
      * If a thread is inside our code with a functional lock held, and then
@@ -1115,6 +1097,18 @@
 	return (NULL);
     } 
     malloc_active = 1;
+
+    if (!malloc_started) {
+        if (ptr != NULL) {
+	    wrtwarning("malloc() has never been called\n");
+	    malloc_active = 0;
+            _MALLOC_UNLOCK();
+	    errno = EDOOFUS;
+	    return (NULL);
+	}
+	malloc_init();
+	malloc_started = 1;
+    }
    
     if (ptr == ZEROSIZEPTR)
 	ptr = NULL;

==== //depot/projects/mips/lib/libgeom/Makefile#7 (text+ko) ====

@@ -1,4 +1,4 @@
-# $FreeBSD: src/lib/libgeom/Makefile,v 1.9 2003/08/18 15:25:38 obrien Exp $
+# $FreeBSD: src/lib/libgeom/Makefile,v 1.10 2004/03/07 16:07:57 phk Exp $
 
 LIB=	geom
 SHLIBDIR?= /lib
@@ -25,6 +25,12 @@
 	libgeom.3 geom_stats_snapshot_free.3 \
 	libgeom.3 geom_stats_snapshot_timestamp.3 \
 	libgeom.3 geom_stats_snapshot_reset.3 \
-	libgeom.3 geom_stats_snapshot_next.3
+	libgeom.3 geom_stats_snapshot_next.3 \
+	libgeom.3 gctl_get_handle.3 \
+	libgeom.3 gctl_ro_param.3 \
+	libgeom.3 gctl_rw_param.3 \
+	libgeom.3 gctl_issue.3 \
+	libgeom.3 gctl_free.3 \
+	libgeom.3 gctl_dump.3
 
 .include <bsd.lib.mk>

==== //depot/projects/mips/lib/libgeom/libgeom.3#5 (text+ko) ====

@@ -25,7 +25,7 @@
 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 .\" SUCH DAMAGE.
 .\"
-.\" $FreeBSD: src/lib/libgeom/libgeom.3,v 1.4 2003/06/18 19:43:17 charnier Exp $
+.\" $FreeBSD: src/lib/libgeom/libgeom.3,v 1.5 2004/03/07 16:07:57 phk Exp $
 .\"
 .Dd February 8, 2003
 .Dt LIBGEOM 3
@@ -38,7 +38,13 @@
 .Nm geom_stats_snapshot_free ,
 .Nm geom_stats_snapshot_timestamp ,
 .Nm geom_stats_snapshot_reset ,
-.Nm geom_stats_snapshot_next
+.Nm geom_stats_snapshot_next ,
+.Nm gctl_get_handle ,
+.Nm gctl_ro_param ,
+.Nm gctl_rw_param ,
+.Nm gctl_issue ,
+.Nm gctl_free ,
+.Nm gctl_dump
 .Nd userland API library for kernel GEOM subsystem
 .Sh LIBRARY
 .Lb libgeom
@@ -61,6 +67,19 @@
 .Fn geom_stats_snapshot_reset "void *arg"
 .Ft "struct g_stat *"
 .Fn geom_stats_snapshot_next "void *arg"
+.Ss "Control Functions"
+.Ft "struct gctl_req *"
+.Fn gctl_get_handle "void"
+.Ft void
+.Fn gctl_ro_param "struct gctl_req *req" "const char *name" "int len" "const void *value"
+.Ft void
+.Fn gctl_rw_param "struct gctl_req *req" "const char *name" "int len" "void *value"
+.Ft "const char *"
+.Fn gctl_issue "struct gctl_req *req"
+.Ft void
+.Fn gctl_free "struct gctl_req *req"
+.Ft void
+.Fn gctl_dump "struct gctl_req *req" "FILE *f"
 .Sh DESCRIPTION
 The
 .Nm geom
@@ -129,10 +148,99 @@
 returns the next item, and
 .Dv NULL
 if there are no more items in the snapshot.
-.Sh AUTHORS
-.An Poul-Henning Kamp Aq phk@FreeBSD.org
+.Ss "Control Functions"
+The
+.Fn gctl_*
+functions are used to send requests to GEOM classes.  In order for a GEOM
+class to actually be able to receive these requests, it must have defined a
+"ctlreq" method.
+.Pp
+A
+.Ar struct gctl_req * ,
+obtained with
+.Fn gctl_get_handle ,
+can hold any number of parameters, which must be added to it with
+.Fn gctl_ro_param
+(for read-only parameters) or
+.Fn gctl_rw_param
+(for read/write parameters).
+.Pp
+Both
+.Fn gctl_ro_param
+and
+.Fn gctl_rw_param
+take a string
+.Ar name ,
+which is used to identify the parameter, and a
+.Ar value ,
+which contains - in the read-only case - the data to be passed to the
+GEOM class, or - in the read/write case - a pointer to preallocated memory
+that the GEOM class should fill with the desired data.  If
+.Ar len
+is negative, it is assumed that
+.Ar value
+is an ASCII string and the actual length is taken from the string length of
+.Ar value ;
+otherwise it must hold the size of
+.Ar value .
+.Pp
+A parameter with a
+.Ar name
+containing the string "class" is mandatory for each request, and the
+corresponding
+.Ar value
+must hold the name of the GEOM class where the request should be sent to.
+.Pp
+Also mandatory for each request is a parameter with a
+.Ar name
+called "verb", and the corresponding
+.Ar value
+needs to hold the command string that the GEOM class should react upon.
+.Pp
+Once all desired parameters are filled in, the request must be sent to
+the GEOM subsystem with
+.Fn gctl_issue ,
+which returns NULL on success, or a string containing the error message
+on failure.
+.Pp
+After the request is finished, the allocated memory should be released with
+.Fn gctl_free .
+.Pp
+.Fn gctl_dump
+can be used to format the contents of
+.Ar req
+to the open file handle pointed to by
+.Ar f 
+for debugging purposes.
+.Pp
+Error handling for the control functions is postponed until the call
+to 
+.Fn gctl_issue
+which returns NULL on success or an error message corresponding to the
+first error which happened.
+.Sh EXAMPLES
+Create a request that is to be sent to the CCD class and tell
+it to destroy a specific geom:
+.Bd -literal -offset indent
+H = gctl_get_handle();
+gctl_ro_param(H, "verb", -1, "destroy geom");
+gctl_ro_param(H, "class", -1, "CCD");
+sprintf(buf, "ccd%d", ccd);
+gctl_ro_param(H, "geom", -1, buf);
+errstr = gctl_issue(H);
+if (errstr != NULL)
+    err(1, "Could not destroy ccd: %s", errstr);
+gctl_free(H);
+.Ed
+.Sh SEE ALSO
+.Rs
+http://ezine.daemonnews.org/200308/blueprints.html
+.Re
 .Sh HISTORY
 The
 .Nm geom
 library appeared in
 .Fx 5.1 .
+.Sh AUTHORS
+.An Poul-Henning Kamp Aq phk@FreeBSD.org
+.An Lukas Ertl Aq le@FreeBSD.org

==== //depot/projects/mips/share/man/man9/Makefile#17 (text+ko) ====

@@ -1,4 +1,4 @@
-# $FreeBSD: src/share/man/man9/Makefile,v 1.225 2004/03/06 08:01:16 jkoshy Exp $
+# $FreeBSD: src/share/man/man9/Makefile,v 1.226 2004/03/07 15:22:08 josef Exp $
 
 MAN=	accept_filter.9 \
 	accf_data.9 \
@@ -186,6 +186,7 @@
 	runqueue.9 \
 	sbuf.9 \
 	scheduler.9 \
+	securelevel_gt.9 \
 	selrecord.9 \
 	sema.9 \
 	signal.9 \
@@ -732,6 +733,7 @@
 	scheduler.9 sched_setup.9 \
 	scheduler.9 setrunnable.9 \
 	scheduler.9 updatepri.9
+MLINKS+=securelevel_gt.9 securelevel_ge.9
 MLINKS+=selrecord.9 selwakeup.9
 MLINKS+=sema.9 sema_destroy.9 \
 	sema.9 sema_init.9 \

==== //depot/projects/mips/share/misc/bsd-family-tree#11 (text+ko) ====

@@ -158,17 +158,17 @@
  |      |             |   NetBSD 1.6       OpenBSD 3.2       |
  |   FreeBSD 4.8      |      |    |            |             |
  |      |             |      | NetBSD 1.6.1    |             |
- |      |             |      |    |        OpenBSD 3.3       |
+ |      |             |      |    |        OpenBSD 3.3     BSD/OS 5.0
  |      |             |      |    |            |             |
- |   FreeBSD 4.9      |      |    |        OpenBSD 3.4       |
- |      |             |      |    |            |             |
- |      v             |      | NetBSD 1.6.2    |             |
- |                    |      |    |            |             |
- |                    |      |    v            |             |
-FreeBSD 5.0	      |      |                 |             |
- |                    |      |                 |            BSD/OS 5.0
-FreeBSD 5.1           |   NetBSD -current  OpenBSD -current  |
- |          \         |      |                 |             v
+ |   FreeBSD 4.9      |      |    |        OpenBSD 3.4     BSD/OS 5.1 ISE
+ |      |             |      |    |            |
+ |      v             |      | NetBSD 1.6.2    |
+ |                    |      |    |            |
+ |                    |      |    v            |
+FreeBSD 5.0	      |      |                 |
+ |                    |      |                 |
+FreeBSD 5.1           |   NetBSD -current  OpenBSD -current
+ |          \         |      |                 |
  |           ----- Mac OS X  |                 |
  |                   10.3    |                 |
 FreeBSD 5.2           |      |                 |
@@ -391,6 +391,7 @@
 FreeBSD 5.1		2003-06-09 [FBD]
 Mac OS X 10.3		2003-10-24 [APL]
 FreeBSD 4.9		2003-10-28 [FBD]
+BSD/OS 5.1 ISE		2003-10-?? [WRS] (final version)
 OpenBSD 3.4		2003-11-01 [OBD]
 FreeBSD 5.2		2004-01-12 [FBD]
 FreeBSD 5.2.1		2004-02-22 [FBD] (patch release)
@@ -451,4 +452,4 @@
 Copyright (c) 1997-2004 Wolfram Schneider <wosch@FreeBSD.ORG>
 URL: http://cvsweb.freebsd.org/src/share/misc/bsd-family-tree
 
-$FreeBSD: src/share/misc/bsd-family-tree,v 1.78 2004/03/04 05:34:29 maxim Exp $
+$FreeBSD: src/share/misc/bsd-family-tree,v 1.79 2004/03/07 16:44:10 wosch Exp $

==== //depot/projects/mips/sys/alpha/alpha/pmap.c#12 (text+ko) ====

@@ -148,7 +148,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/alpha/alpha/pmap.c,v 1.139 2003/10/03 22:46:52 alc Exp $");
+__FBSDID("$FreeBSD: src/sys/alpha/alpha/pmap.c,v 1.140 2004/03/07 21:06:46 alc Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -1109,18 +1109,6 @@
 	mtx_lock_spin(&allpmaps_lock);
 	LIST_INSERT_HEAD(&allpmaps, pmap, pm_list);
 	mtx_unlock_spin(&allpmaps_lock);
-}
-
-/*
- * Wire in kernel global address entries.  To avoid a race condition
- * between pmap initialization and pmap_growkernel, this procedure
- * should be called after the vmspace is attached to the process
- * but before this pmap is activated.
- */
-void
-pmap_pinit2(pmap)
-	struct pmap *pmap;
-{
 	bcopy(PTlev1 + K1SEGLEV1I, pmap->pm_lev1 + K1SEGLEV1I, nklev2 * PTESIZE);
 }
 

==== //depot/projects/mips/sys/amd64/amd64/pmap.c#6 (text+ko) ====

@@ -75,7 +75,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/amd64/amd64/pmap.c,v 1.452 2004/02/05 00:11:05 peter Exp $");
+__FBSDID("$FreeBSD: src/sys/amd64/amd64/pmap.c,v 1.453 2004/03/07 21:06:47 alc Exp $");
 
 /*
  *	Manages physical address maps.
@@ -1103,19 +1103,6 @@
 }
 
 /*
- * Wire in kernel global address entries.  To avoid a race condition
- * between pmap initialization and pmap_growkernel, this procedure
- * should be called after the vmspace is attached to the process
- * but before this pmap is activated.
- */
-void
-pmap_pinit2(pmap)
-	struct pmap *pmap;
-{
-	/* XXX: Remove this stub when no longer called */
-}
-
-/*
  * this routine is called if the page table page is not
  * mapped correctly.
  *

==== //depot/projects/mips/sys/dev/trm/trm.c#10 (text+ko) ====

@@ -12,7 +12,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/trm/trm.c,v 1.19 2004/02/20 20:36:55 cognet Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/trm/trm.c,v 1.20 2004/03/07 17:23:39 cognet Exp $");
 
 /*
  *	HISTORY:					
@@ -2992,6 +2992,25 @@
 	return;
 }
 
+static void
+trm_destroySRB(PACB pACB)
+{
+	PSRB pSRB;
+
+	pSRB = pACB->pFreeSRB;
+	while (pSRB) {
+		if (pSRB->sg_dmamap) {
+			bus_dmamap_unload(pACB->sg_dmat, pSRB->sg_dmamap);
+			bus_dmamem_free(pACB->sg_dmat, pSRB->pSRBSGL,
+			    pSRB->sg_dmamap);
+			bus_dmamap_destroy(pACB->sg_dmat, pSRB->sg_dmamap);
+		}
+		if (pSRB->dmamap)
+			bus_dmamap_destroy(pACB->buffer_dmat, pSRB->dmamap);
+		pSRB = pSRB->pNextSRB;
+	}
+}
+
 static int
 trm_initSRB(PACB pACB)
 {
@@ -3002,29 +3021,11 @@
 	for (i = 0; i < TRM_MAX_SRB_CNT; i++) {
 	       	pSRB = (PSRB)&pACB->pFreeSRB[i];
 
-		/* DMA tag for our S/G structures */
-		if (bus_dma_tag_create(                    
-		    /*parent_dmat*/pSRB->parent_dmat, 
-		    /*alignment*/  1,
-		    /*boundary*/   0,
-		    /*lowaddr*/    BUS_SPACE_MAXADDR,
-		    /*highaddr*/   BUS_SPACE_MAXADDR,
-		    /*filter*/     NULL, 
-		    /*filterarg*/  NULL,
-		    /*maxsize*/    TRM_MAX_SG_LISTENTRY * sizeof(SGentry), 
-		    /*nsegments*/  1,
-		    /*maxsegsz*/   TRM_MAXTRANSFER_SIZE,
-		    /*flags*/      0, 
-		    /*lockfunc*/   busdma_lock_mutex,
-		    /*lockarg*/    &Giant,
-		    /*dmat*/       &pSRB->sg_dmat) != 0) {
-			return ENXIO;
-		}
-		if (bus_dmamem_alloc(pSRB->sg_dmat, (void **)&pSRB->pSRBSGL,
+		if (bus_dmamem_alloc(pACB->sg_dmat, (void **)&pSRB->pSRBSGL,
 		    BUS_DMA_NOWAIT, &pSRB->sg_dmamap) !=0 ) {
 			return ENXIO;
 		}
-		bus_dmamap_load(pSRB->sg_dmat, pSRB->sg_dmamap, pSRB->pSRBSGL,
+		bus_dmamap_load(pACB->sg_dmat, pSRB->sg_dmamap, pSRB->pSRBSGL,
 		    TRM_MAX_SG_LISTENTRY * sizeof(SGentry),
 		    trm_srbmapSG, pSRB, /*flags*/0);
 		if (i != TRM_MAX_SRB_CNT - 1) {
@@ -3042,9 +3043,6 @@
 
 		/*
 		 * Create the dmamap.  This is no longer optional!
-		 *
-		 * XXX This is not freed on unload!  None of the other
-		 * allocations in this function are either!
 		 */
 		if ((error = bus_dmamap_create(pACB->buffer_dmat, 0,
 					       &pSRB->dmamap)) != 0)
@@ -3499,6 +3497,23 @@
 		}
 	}
 	bzero(pACB->pFreeSRB, TRM_MAX_SRB_CNT * sizeof(TRM_SRB));
+	if (bus_dma_tag_create(                    
+		    /*parent_dmat*/NULL, 
+		    /*alignment*/  1,
+		    /*boundary*/   0,
+		    /*lowaddr*/    BUS_SPACE_MAXADDR,
+		    /*highaddr*/   BUS_SPACE_MAXADDR,
+		    /*filter*/     NULL, 
+		    /*filterarg*/  NULL,
+		    /*maxsize*/    TRM_MAX_SG_LISTENTRY * sizeof(SGentry), 
+		    /*nsegments*/  1,
+		    /*maxsegsz*/   TRM_MAXTRANSFER_SIZE,
+		    /*flags*/      0, 
+		    /*lockfunc*/   busdma_lock_mutex,
+		    /*lockarg*/    &Giant,
+		    /*dmat*/       &pACB->sg_dmat) != 0)
+		goto bad;
+
 	if (trm_initSRB(pACB)) {
 		printf("trm_initSRB: error\n");
 		goto bad;
@@ -3520,6 +3535,10 @@
 	}
 	if (pACB->sense_dmat)
 		bus_dma_tag_destroy(pACB->sense_dmat);
+	if (pACB->sg_dmat) {
+		trm_destroySRB(pACB);
+		bus_dma_tag_destroy(pACB->sg_dmat);
+	}
 	if (pACB->srb_dmamap) {
 		bus_dmamap_unload(pACB->srb_dmat, pACB->srb_dmamap);
 		bus_dmamem_free(pACB->srb_dmat, pACB->pFreeSRB, 
@@ -3628,6 +3647,11 @@
 	if (pACB->iores)
 		bus_release_resource(dev, SYS_RES_IOPORT, PCIR_BAR(0),
 		    pACB->iores);
+	if (pACB->sg_dmat) {		
+		trm_destroySRB(pACB);
+		bus_dma_tag_destroy(pACB->sg_dmat);
+	}
+	
 	if (pACB->srb_dmamap) {
 		bus_dmamap_unload(pACB->srb_dmat, pACB->srb_dmamap);
 		bus_dmamem_free(pACB->srb_dmat, pACB->pFreeSRB, 
@@ -3685,6 +3709,8 @@
 	PACB pACB = device_get_softc(dev);
 
 	bus_release_resource(dev, SYS_RES_IOPORT, PCIR_BAR(0), pACB->iores);
+	trm_destroySRB(pACB);
+	bus_dma_tag_destroy(pACB->sg_dmat);
 	bus_dmamap_unload(pACB->srb_dmat, pACB->srb_dmamap);
 	bus_dmamem_free(pACB->srb_dmat, pACB->pFreeSRB,
 	    pACB->srb_dmamap);

==== //depot/projects/mips/sys/dev/trm/trm.h#4 (text+ko) ====

@@ -27,7 +27,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/trm/trm.h,v 1.3 2003/02/20 03:21:34 cognet Exp $
+ * $FreeBSD: src/sys/dev/trm/trm.h,v 1.4 2004/03/07 17:23:39 cognet Exp $
  */
 
 #ifndef trm_H
@@ -155,8 +155,6 @@
 	 *	          CAM ccb
 	 */
 	union  ccb      *pccb; 
-	bus_dma_tag_t	parent_dmat;
-	bus_dma_tag_t	sg_dmat;
 	bus_dmamap_t	sg_dmamap;
 	bus_dmamap_t	 dmamap;
 	u_int16_t	SRBState;
@@ -235,6 +233,7 @@
 	bus_dma_tag_t		buffer_dmat;   /* dmat for buffer I/O */  
 	bus_dma_tag_t		srb_dmat;
 	bus_dma_tag_t		sense_dmat; /* dmat for sense buffer */
+	bus_dma_tag_t		sg_dmat;
 	bus_dmamap_t		sense_dmamap;
 	bus_dmamap_t		srb_dmamap;
 	bus_addr_t		sense_busaddr;

==== //depot/projects/mips/sys/geom/geom_subr.c#20 (text+ko) ====

@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/geom/geom_subr.c,v 1.71 2004/02/14 17:58:57 phk Exp $");
+__FBSDID("$FreeBSD: src/sys/geom/geom_subr.c,v 1.72 2004/03/07 17:33:15 phk Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -272,7 +272,8 @@
 	if (!(gp->flags & G_GEOM_WITHER)) {
 		gp->flags |= G_GEOM_WITHER;
 		LIST_FOREACH(pp, &gp->provider, provider)
-			g_orphan_provider(pp, error);
+			if (!(pp->flags & G_PF_ORPHAN))
+				g_orphan_provider(pp, error);
 	}
 	for (pp = LIST_FIRST(&gp->provider); pp != NULL; pp = pp2) {
 		pp2 = LIST_NEXT(pp, provider);

==== //depot/projects/mips/sys/i386/i386/pmap.c#22 (text+ko) ====

@@ -73,7 +73,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/i386/i386/pmap.c,v 1.462 2004/02/01 20:14:00 alc Exp $");
+__FBSDID("$FreeBSD: src/sys/i386/i386/pmap.c,v 1.463 2004/03/07 21:06:47 alc Exp $");
 
 /*
  *	Manages physical address maps.
@@ -1147,19 +1147,6 @@
 }
 
 /*
- * Wire in kernel global address entries.  To avoid a race condition
- * between pmap initialization and pmap_growkernel, this procedure
- * should be called after the vmspace is attached to the process
- * but before this pmap is activated.
- */
-void
-pmap_pinit2(pmap)
-	struct pmap *pmap;
-{
-	/* XXX: Remove this stub when no longer called */
-}
-
-/*
  * this routine is called if the page table page is not
  * mapped correctly.
  */

==== //depot/projects/mips/sys/ia64/ia64/pmap.c#17 (text+ko) ====

@@ -46,7 +46,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/ia64/ia64/pmap.c,v 1.126 2004/03/07 07:43:13 alc Exp $");
+__FBSDID("$FreeBSD: src/sys/ia64/ia64/pmap.c,v 1.127 2004/03/07 21:06:47 alc Exp $");
 
 #include <sys/param.h>
 #include <sys/kernel.h>
@@ -735,17 +735,6 @@
 	bzero(&pmap->pm_stats, sizeof pmap->pm_stats);
 }
 
-/*
- * Wire in kernel global address entries.  To avoid a race condition
- * between pmap initialization and pmap_growkernel, this procedure
- * should be called after the vmspace is attached to the process
- * but before this pmap is activated.
- */
-void
-pmap_pinit2(struct pmap *pmap)
-{
-}
-
 /***************************************************
  * Pmap allocation/deallocation routines.
  ***************************************************/

==== //depot/projects/mips/sys/netgraph/ng_iface.c#8 (text+ko) ====

@@ -35,7 +35,7 @@
  *
  * Author: Archie Cobbs <archie@freebsd.org>
  *
- * $FreeBSD: src/sys/netgraph/ng_iface.c,v 1.28 2003/12/28 03:56:00 sam Exp $
+ * $FreeBSD: src/sys/netgraph/ng_iface.c,v 1.29 2004/03/07 23:00:44 ru Exp $
  * $Whistle: ng_iface.c,v 1.33 1999/11/01 09:24:51 julian Exp $
  */
 
@@ -186,6 +186,13 @@
 	  NULL,
 	  &ng_cisco_ipaddr_type
 	},
+	{
+	  NGM_IFACE_COOKIE,
+	  NGM_IFACE_GET_IFINDEX,
+	  "getifindex",
+	  NULL,
+	  &ng_parse_uint32_type
+	},
 	{ 0 }
 };
 
@@ -667,6 +674,15 @@
 			break;
 		    }
 
+		case NGM_IFACE_GET_IFINDEX:
+			NG_MKRESPONSE(resp, msg, sizeof(uint32_t), M_NOWAIT);
+			if (resp == NULL) {
+				error = ENOMEM;
+				break;
+			}
+			*((uint32_t *)resp->data) = priv->ifp->if_index;
+			break;
+
 		default:
 			error = EINVAL;
 			break;

==== //depot/projects/mips/sys/netgraph/ng_iface.h#4 (text+ko) ====

@@ -36,7 +36,7 @@
  *
  * Author: Archie Cobbs <archie@freebsd.org>
  *
- * $FreeBSD: src/sys/netgraph/ng_iface.h,v 1.5 2003/11/11 12:30:37 ru Exp $
+ * $FreeBSD: src/sys/netgraph/ng_iface.h,v 1.6 2004/03/07 23:00:44 ru Exp $
  * $Whistle: ng_iface.h,v 1.5 1999/01/20 00:22:13 archie Exp $
  */
 
@@ -69,6 +69,7 @@
 	NGM_IFACE_GET_IFNAME = 1,	/* returns struct ng_iface_ifname */
 	NGM_IFACE_POINT2POINT,
 	NGM_IFACE_BROADCAST,
+	NGM_IFACE_GET_IFINDEX,
 };
 
 struct ng_iface_ifname {

==== //depot/projects/mips/sys/nfsserver/nfs.h#3 (text+ko) ====

@@ -34,7 +34,7 @@
  * SUCH DAMAGE.
  *
  *	@(#)nfs.h	8.4 (Berkeley) 5/1/95
- * $FreeBSD: src/sys/nfsserver/nfs.h,v 1.69 2003/05/25 06:17:33 truckman Exp $
+ * $FreeBSD: src/sys/nfsserver/nfs.h,v 1.70 2004/03/07 16:28:31 kan Exp $
  */
 
 #ifndef _NFSSERVER_NFS_H_
@@ -132,7 +132,7 @@
 struct vattr;
 struct nameidata;
 
-extern struct callout_handle nfsrv_timer_handle;
+extern struct callout nfsrv_callout;
 extern struct nfsrvstats nfsrvstats;
 
 extern int	nfsrv_ticks;

==== //depot/projects/mips/sys/nfsserver/nfs_srvsock.c#7 (text+ko) ====

@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/nfsserver/nfs_srvsock.c,v 1.86 2003/11/17 00:56:53 rwatson Exp $");
+__FBSDID("$FreeBSD: src/sys/nfsserver/nfs_srvsock.c,v 1.87 2004/03/07 16:28:31 kan Exp $");
 
 /*
  * Socket operations for use by nfs
@@ -96,7 +96,7 @@
  */
 #define	NFS_CWNDSCALE	256
 #define	NFS_MAXCWND	(NFS_CWNDSCALE * 32)
-struct callout_handle	nfsrv_timer_handle;
+struct callout	nfsrv_callout;
 
 static void	nfs_realign(struct mbuf **pm, int hsiz);	/* XXX SHARED */
 static int	nfsrv_getstream(struct nfssvc_sock *, int);
@@ -779,5 +779,5 @@
 			nfsrv_wakenfsd(slp);
 	}
 	splx(s);
-	nfsrv_timer_handle = timeout(nfsrv_timer, NULL, nfsrv_ticks);
+	callout_reset(&nfsrv_callout, nfsrv_ticks, nfsrv_timer, NULL);
 }

==== //depot/projects/mips/sys/nfsserver/nfs_srvsubs.c#9 (text+ko) ====

@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/nfsserver/nfs_srvsubs.c,v 1.123 2003/12/17 16:12:01 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/nfsserver/nfs_srvsubs.c,v 1.124 2004/03/07 16:28:31 kan Exp $");
 
 /*
  * These functions support the macros and help fiddle mbuf chains for
@@ -545,6 +545,7 @@
 		nfsrv_init(0);		/* Init server data structures */
 		nfsrv_initcache();	/* Init the server request cache */
 
+		callout_init(&nfsrv_callout, 0);
 		nfsrv_timer(0);
 
 		nfs_prev_nfssvc_sy_narg = sysent[SYS_nfssvc].sy_narg;
@@ -555,7 +556,7 @@
 
 		case MOD_UNLOAD:
 
-		untimeout(nfsrv_timer, (void *)NULL, nfsrv_timer_handle);
+		callout_stop(&nfsrv_callout);
 		sysent[SYS_nfssvc].sy_narg = nfs_prev_nfssvc_sy_narg;
 		sysent[SYS_nfssvc].sy_call = nfs_prev_nfssvc_sy_call;
 		break;

==== //depot/projects/mips/sys/pc98/pc98/wd_cd.h#2 (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/pc98/pc98/wd_cd.h,v 1.3 2002/09/23 18:54:32 alfred Exp $
+ * $FreeBSD: src/sys/pc98/pc98/wd_cd.h,v 1.4 2004/03/07 14:16:42 nyan Exp $
  */
 
 /*
@@ -347,3 +347,12 @@
 	u_int next_writeable_lba;	/* Next writable position */
 	struct wormio_prepare_track preptrack;	/* Scratch region */
 };
+
+struct ioc_read_audio {
+	u_char address_format;
+	union msf_lba address;
+	int nframes;
+	u_char* buffer;
+};
+
+#define CDIOCREADAUDIO _IOWR('c',31,struct ioc_read_audio)

==== //depot/projects/mips/sys/powerpc/powerpc/pmap.c#11 (text+ko) ====

@@ -91,7 +91,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/powerpc/powerpc/pmap.c,v 1.71 2004/03/02 06:49:21 grehan Exp $");
+__FBSDID("$FreeBSD: src/sys/powerpc/powerpc/pmap.c,v 1.72 2004/03/07 21:06:48 alc Exp $");
 
 /*
  * Manages physical address maps.
@@ -1443,12 +1443,6 @@
 	bzero(&pm->pm_stats, sizeof(pm->pm_stats));
 }
 
-void
-pmap_pinit2(pmap_t pmap)
-{
-	/* XXX: Remove this stub when no longer called */
-}
-
 /*
  * Set the physical protection on the specified range of this map as requested.
  */

==== //depot/projects/mips/sys/rpc/rpcclnt.c#4 (text+ko) ====

@@ -1,4 +1,4 @@
-/* $FreeBSD: src/sys/rpc/rpcclnt.c,v 1.6 2004/01/17 21:25:05 alfred Exp $ */
+/* $FreeBSD: src/sys/rpc/rpcclnt.c,v 1.7 2004/03/07 16:23:03 kan Exp $ */
 /* $Id: rpcclnt.c,v 1.9 2003/11/05 14:59:03 rees Exp $ */
 
 /*
@@ -203,7 +203,7 @@
  */
 static 
 TAILQ_HEAD(, rpctask) rpctask_q;
-struct callout_handle rpcclnt_timer_handle;
+struct callout	rpcclnt_callout;
 
 #ifdef __OpenBSD__
 static int             rpcclnt_send(struct socket *, struct mbuf *, struct mbuf *, struct rpctask *);
@@ -283,8 +283,8 @@
 	timeout_set(&rpcclnt_timer_to, rpcclnt_timer, &rpcclnt_timer_to);
 	rpcclnt_timer(&rpcclnt_timer_to);
 #else /* !__OpenBSD__ */
+	callout_init(&rpcclnt_callout, 0);
 	rpcclnt_timer(NULL);
-
 #endif /* !__OpenBSD__ */
 
 	RPCDEBUG("rpc initialed");
@@ -296,7 +296,7 @@
 rpcclnt_uninit(void)
 {
   	RPCDEBUG("uninit");
-	untimeout(rpcclnt_timer, (void *)NULL, rpcclnt_timer_handle);
+	callout_stop(&rpcclnt_callout);
 
 	/* XXX delete sysctl variables? */
 }
@@ -1476,7 +1476,7 @@
 #ifdef __OpenBSD__
 	timeout_add(rpcclnt_timer, to, rpcclnt_ticks);
 #else
-	rpcclnt_timer_handle = timeout(rpcclnt_timer, NULL, rpcclnt_ticks);
+	callout_reset(&rpcclnt_callout, rpcclnt_ticks, rpcclnt_timer, NULL);
 #endif
 }
 

==== //depot/projects/mips/sys/sparc64/sparc64/pmap.c#13 (text+ko) ====

@@ -39,7 +39,7 @@
  * SUCH DAMAGE.
  *
  *      from:   @(#)pmap.c      7.7 (Berkeley)  5/12/91
- * $FreeBSD: src/sys/sparc64/sparc64/pmap.c,v 1.126 2003/10/03 22:46:53 alc Exp $
+ * $FreeBSD: src/sys/sparc64/sparc64/pmap.c,v 1.127 2004/03/07 21:06:48 alc Exp $
  */
 
 /*
@@ -1027,12 +1027,6 @@
 	bzero(&pm->pm_stats, sizeof(pm->pm_stats));
 }
 
-void
-pmap_pinit2(pmap_t pmap)
-{
-	/* XXX: Remove this stub when no longer called */
-}
-
 /*
  * Release any resources held by the given physical map.
  * Called when a pmap initialized by pmap_pinit is being released.

==== //depot/projects/mips/sys/vm/pmap.h#9 (text+ko) ====

@@ -61,7 +61,7 @@
  * any improvements or extensions that they make and grant Carnegie the
  * rights to redistribute these changes.
  *
- * $FreeBSD: src/sys/vm/pmap.h,v 1.65 2003/10/06 01:47:12 bms Exp $
+ * $FreeBSD: src/sys/vm/pmap.h,v 1.66 2004/03/07 21:06:48 alc Exp $
  */
 
 /*
@@ -120,7 +120,6 @@
 void		 pmap_page_protect(vm_page_t m, vm_prot_t prot);
 void		 pmap_pinit(pmap_t);
 void		 pmap_pinit0(pmap_t);
-void		 pmap_pinit2(pmap_t);
 void		 pmap_protect(pmap_t, vm_offset_t, vm_offset_t, vm_prot_t);
 void		 pmap_qenter(vm_offset_t, vm_page_t *, int);
 void		 pmap_qremove(vm_offset_t, int);

==== //depot/projects/mips/sys/vm/vm_glue.c#11 (text+ko) ====

@@ -61,7 +61,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/vm/vm_glue.c,v 1.191 2004/03/05 22:03:11 truckman Exp $");
+__FBSDID("$FreeBSD: src/sys/vm/vm_glue.c,v 1.192 2004/03/07 21:06:48 alc Exp $");
 
 #include "opt_vm.h"
 #include "opt_kstack_pages.h"
@@ -675,9 +675,6 @@
 
 	if ((flags & RFMEM) == 0) {
 		p2->p_vmspace = vmspace_fork(p1->p_vmspace);
-
-		pmap_pinit2(vmspace_pmap(p2->p_vmspace));
-
 		if (p1->p_vmspace->vm_shm)
 			shmfork(p1, p2);
 	}

==== //depot/projects/mips/sys/vm/vm_map.c#18 (text+ko) ====

@@ -67,7 +67,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/vm/vm_map.c,v 1.329 2004/02/12 20:56:06 alc Exp $");
+__FBSDID("$FreeBSD: src/sys/vm/vm_map.c,v 1.330 2004/03/07 21:06:48 alc Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -2798,7 +2798,6 @@
 	 * here, it is a good idea to keep this form for future mods.
 	 */

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



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