PERFORCE change 54845 for review
Robert Watson
rwatson at FreeBSD.org
Sun Jun 13 19:54:44 GMT 2004
http://perforce.freebsd.org/chv.cgi?CH=54845
Change 54845 by rwatson at rwatson_tislabs on 2004/06/13 19:53:50
Top-up integrate of netperf_socket.
Affected files ...
.. //depot/projects/netperf_socket/sys/amd64/amd64/pmap.c#12 integrate
.. //depot/projects/netperf_socket/sys/dev/esp/ncr53c9x.c#4 integrate
.. //depot/projects/netperf_socket/sys/net/if_fwsubr.c#2 integrate
Differences ...
==== //depot/projects/netperf_socket/sys/amd64/amd64/pmap.c#12 (text+ko) ====
@@ -75,7 +75,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/amd64/amd64/pmap.c,v 1.467 2004/06/12 20:01:47 alc Exp $");
+__FBSDID("$FreeBSD: src/sys/amd64/amd64/pmap.c,v 1.468 2004/06/13 19:48:38 alc Exp $");
/*
* Manages physical address maps.
@@ -142,7 +142,6 @@
#include <machine/smp.h>
#endif
-#define PMAP_KEEP_PDIRS
#ifndef PMAP_SHPGPERPROC
#define PMAP_SHPGPERPROC 200
#endif
@@ -208,8 +207,7 @@
static PMAP_INLINE void free_pv_entry(pv_entry_t pv);
static pv_entry_t get_pv_entry(void);
-static void pmap_clear_ptes(vm_page_t m, int bit)
- __always_inline;
+static void pmap_clear_ptes(vm_page_t m, int bit);
static int pmap_remove_pte(pmap_t pmap, pt_entry_t *ptq, vm_offset_t sva);
static void pmap_remove_page(struct pmap *pmap, vm_offset_t va);
@@ -1336,13 +1334,11 @@
void
pmap_growkernel(vm_offset_t addr)
{
- int s;
vm_paddr_t paddr;
vm_page_t nkpg;
pd_entry_t *pde, newpdir;
pdp_entry_t newpdp;
- s = splhigh();
mtx_assert(&kernel_map->system_mtx, MA_OWNED);
if (kernel_vm_end == 0) {
kernel_vm_end = KERNBASE;
@@ -1390,7 +1386,6 @@
kernel_vm_end = (kernel_vm_end + PAGE_SIZE * NPTEPG) & ~(PAGE_SIZE * NPTEPG - 1);
}
- splx(s);
}
@@ -1439,9 +1434,7 @@
{
pv_entry_t pv;
int rtval;
- int s;
- s = splvm();
mtx_assert(&vm_page_queue_mtx, MA_OWNED);
if (m->md.pv_list_count < pmap->pm_stats.resident_count) {
TAILQ_FOREACH(pv, &m->md.pv_list, pv_list) {
@@ -1467,7 +1460,6 @@
free_pv_entry(pv);
}
- splx(s);
return rtval;
}
@@ -1479,10 +1471,8 @@
pmap_insert_entry(pmap_t pmap, vm_offset_t va, vm_page_t mpte, vm_page_t m)
{
- int s;
pv_entry_t pv;
- s = splvm();
pv = get_pv_entry();
pv->pv_va = va;
pv->pv_pmap = pmap;
@@ -1494,7 +1484,6 @@
m->md.pv_list_count++;
vm_page_unlock_queues();
- splx(s);
}
/*
@@ -1674,7 +1663,6 @@
{
register pv_entry_t pv;
pt_entry_t *pte, tpte;
- int s;
#if defined(PMAP_DIAGNOSTIC)
/*
@@ -1686,7 +1674,6 @@
}
#endif
mtx_assert(&vm_page_queue_mtx, MA_OWNED);
- s = splvm();
while ((pv = TAILQ_FIRST(&m->md.pv_list)) != NULL) {
pv->pv_pmap->pm_stats.resident_count--;
pte = pmap_pte(pv->pv_pmap, pv->pv_va);
@@ -1718,7 +1705,6 @@
free_pv_entry(pv);
}
vm_page_flag_clear(m, PG_WRITEABLE);
- splx(s);
}
/*
@@ -2411,23 +2397,19 @@
{
pv_entry_t pv;
int loops = 0;
- int s;
if (!pmap_initialized || (m->flags & PG_FICTITIOUS))
return FALSE;
- s = splvm();
mtx_assert(&vm_page_queue_mtx, MA_OWNED);
TAILQ_FOREACH(pv, &m->md.pv_list, pv_list) {
if (pv->pv_pmap == pmap) {
- splx(s);
return TRUE;
}
loops++;
if (loops >= 16)
break;
}
- splx(s);
return (FALSE);
}
@@ -2448,7 +2430,6 @@
pt_entry_t *pte, tpte;
vm_page_t m;
pv_entry_t pv, npv;
- int s;
#ifdef PMAP_REMOVE_PAGES_CURPROC_ONLY
if (!curthread || (pmap != vmspace_pmap(curthread->td_proc->p_vmspace))) {
@@ -2457,7 +2438,6 @@
}
#endif
mtx_assert(&vm_page_queue_mtx, MA_OWNED);
- s = splvm();
for (pv = TAILQ_FIRST(&pmap->pm_pvlist); pv; pv = npv) {
if (pv->pv_va >= eva || pv->pv_va < sva) {
@@ -2517,7 +2497,6 @@
pmap_unuse_pt(pv->pv_pmap, pv->pv_va, pv->pv_ptem);
free_pv_entry(pv);
}
- splx(s);
pmap_invalidate_all(pmap);
}
@@ -2532,12 +2511,10 @@
{
pv_entry_t pv;
pt_entry_t *pte;
- int s;
if (!pmap_initialized || (m->flags & PG_FICTITIOUS))
return FALSE;
- s = splvm();
mtx_assert(&vm_page_queue_mtx, MA_OWNED);
TAILQ_FOREACH(pv, &m->md.pv_list, pv_list) {
/*
@@ -2555,11 +2532,9 @@
#endif
pte = pmap_pte(pv->pv_pmap, pv->pv_va);
if (*pte & PG_M) {
- splx(s);
return TRUE;
}
}
- splx(s);
return (FALSE);
}
@@ -2592,13 +2567,11 @@
{
register pv_entry_t pv;
pt_entry_t pbits, *pte;
- int s;
if (!pmap_initialized || (m->flags & PG_FICTITIOUS) ||
(bit == PG_RW && (m->flags & PG_WRITEABLE) == 0))
return;
- s = splvm();
mtx_assert(&vm_page_queue_mtx, MA_OWNED);
/*
* Loop over all current mappings setting/clearing as appropos If
@@ -2636,7 +2609,6 @@
}
if (bit == PG_RW)
vm_page_flag_clear(m, PG_WRITEABLE);
- splx(s);
}
/*
@@ -2674,13 +2646,11 @@
register pv_entry_t pv, pvf, pvn;
pt_entry_t *pte;
pt_entry_t v;
- int s;
int rtval = 0;
if (!pmap_initialized || (m->flags & PG_FICTITIOUS))
return (rtval);
- s = splvm();
mtx_assert(&vm_page_queue_mtx, MA_OWNED);
if ((pv = TAILQ_FIRST(&m->md.pv_list)) != NULL) {
@@ -2709,7 +2679,6 @@
}
} while ((pv = pvn) != NULL && pv != pvf);
}
- splx(s);
return (rtval);
}
==== //depot/projects/netperf_socket/sys/dev/esp/ncr53c9x.c#4 (text+ko) ====
@@ -104,7 +104,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/esp/ncr53c9x.c,v 1.4 2004/06/13 09:08:44 scottl Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/esp/ncr53c9x.c,v 1.5 2004/06/13 18:45:57 scottl Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -667,7 +667,7 @@
* always possible that the interrupt may never happen.
*/
ecb->ccb->ccb_h.timeout_ch =
- timeout(ncr53c9x_timeout, sc, mstohz(ecb->timeout));
+ timeout(ncr53c9x_timeout, ecb, mstohz(ecb->timeout));
/*
* The docs say the target register is never reset, and I
@@ -1217,7 +1217,7 @@
lun = ccb->ccb_h.target_lun;
li = TINFO_LUN(ti, lun);
- untimeout(ncr53c9x_timeout, sc, ccb->ccb_h.timeout_ch);
+ untimeout(ncr53c9x_timeout, ecb, ccb->ccb_h.timeout_ch);
/*
* Now, if we've come here with no error code, i.e. we've kept the
@@ -2331,7 +2331,7 @@
goto reset;
}
printf("sending REQUEST SENSE\n");
- untimeout(ncr53c9x_timeout, sc,
+ untimeout(ncr53c9x_timeout, ecb,
ecb->ccb->ccb_h.timeout_ch);
ncr53c9x_sense(sc, ecb);
goto out;
@@ -2400,7 +2400,7 @@
*/
if (sc->sc_state == NCR_SELECTING) {
NCR_INTS(("backoff selector "));
- untimeout(ncr53c9x_timeout, sc,
+ untimeout(ncr53c9x_timeout, ecb,
ecb->ccb->ccb_h.timeout_ch);
ncr53c9x_dequeue(sc, ecb);
TAILQ_INSERT_HEAD(&sc->ready_list, ecb, chain);
@@ -2855,7 +2855,7 @@
* Reschedule timeout.
*/
ecb->ccb->ccb_h.timeout_ch =
- timeout(ncr53c9x_timeout, sc, mstohz(ecb->timeout));
+ timeout(ncr53c9x_timeout, ecb, mstohz(ecb->timeout));
} else {
/*
* Just leave the command where it is.
==== //depot/projects/netperf_socket/sys/net/if_fwsubr.c#2 (text+ko) ====
@@ -11,10 +11,6 @@
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the University of
- * California, Berkeley and its contributors.
* 4. Neither the name of the University nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
@@ -31,7 +27,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/net/if_fwsubr.c,v 1.1 2004/06/13 10:54:35 dfr Exp $
+ * $FreeBSD: src/sys/net/if_fwsubr.c,v 1.2 2004/06/13 19:15:44 dfr Exp $
*/
#include "opt_inet.h"
More information about the p4-projects
mailing list