diff options
| author | thorpej <thorpej@NetBSD.org> | 2022-07-20 15:45:28 +0000 |
|---|---|---|
| committer | thorpej <thorpej@NetBSD.org> | 2022-07-20 15:45:28 +0000 |
| commit | 2e33f394a09bfe78f10cfe34d094e0f16caac39d (patch) | |
| tree | e46dbbfc9bb9b81fa056857feb5dfaa7838f6bd9 /sys/dev | |
| parent | ac0732ab34e76569641fed1be40af249389835d0 (diff) | |
In the Alpha tc_syncbus(), we need to issue a MB because WMB does not
order reads with respect to writes. Remove now-redundant tc_wmb()
calls before tc_syncbus().
NFC on MIPS other than removing a redundant wbflush() (tc_wmb() followed
by tc_syncbus()).
Diffstat (limited to 'sys/dev')
| -rw-r--r-- | sys/dev/tc/pxg.c | 6 | ||||
| -rw-r--r-- | sys/dev/tc/stic.c | 8 |
2 files changed, 4 insertions, 10 deletions
diff --git a/sys/dev/tc/pxg.c b/sys/dev/tc/pxg.c index 7133a7a5412..3e7ae186a0c 100644 --- a/sys/dev/tc/pxg.c +++ b/sys/dev/tc/pxg.c @@ -1,4 +1,4 @@ -/* $NetBSD: pxg.c,v 1.36 2019/11/10 21:16:37 chs Exp $ */ +/* $NetBSD: pxg.c,v 1.37 2022/07/20 15:45:28 thorpej Exp $ */ /*- * Copyright (c) 1999, 2000, 2001 The NetBSD Foundation, Inc. @@ -35,7 +35,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: pxg.c,v 1.36 2019/11/10 21:16:37 chs Exp $"); +__KERNEL_RCSID(0, "$NetBSD: pxg.c,v 1.37 2022/07/20 15:45:28 thorpej Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -164,7 +164,6 @@ pxg_attach(device_t parent, device_t self, void *aux) /* Start the i860. */ si->si_slotbase[PXG_I860_START_OFFSET >> 2] = 1; - tc_wmb(); tc_syncbus(); DELAY(40000); #endif @@ -208,7 +207,6 @@ pxg_init(struct stic_info *si) slot[PXG_I860_RESET_OFFSET >> 2] = 0; tc_wmb(); slot[PXG_HOST_INTR_OFFSET >> 2] = 0; - tc_wmb(); tc_syncbus(); DELAY(40000); diff --git a/sys/dev/tc/stic.c b/sys/dev/tc/stic.c index 289ed4a4907..bdf866819a8 100644 --- a/sys/dev/tc/stic.c +++ b/sys/dev/tc/stic.c @@ -1,4 +1,4 @@ -/* $NetBSD: stic.c,v 1.58 2022/05/18 13:56:32 andvar Exp $ */ +/* $NetBSD: stic.c,v 1.59 2022/07/20 15:45:28 thorpej Exp $ */ /*- * Copyright (c) 1999, 2000, 2001 The NetBSD Foundation, Inc. @@ -36,7 +36,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: stic.c,v 1.58 2022/05/18 13:56:32 andvar Exp $"); +__KERNEL_RCSID(0, "$NetBSD: stic.c,v 1.59 2022/07/20 15:45:28 thorpej Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -288,7 +288,6 @@ stic_init(struct stic_info *si) /* Now reset the VDAC. */ *si->si_vdac_reset = 0; - tc_wmb(); tc_syncbus(); DELAY(1000); @@ -358,13 +357,11 @@ stic_reset(struct stic_info *si) * Initialize the interface chip registers. */ sr->sr_sticsr = 0x00000030; /* Get the STIC's attention. */ - tc_wmb(); tc_syncbus(); DELAY(2000); /* wait 2ms for STIC to respond. */ sr->sr_sticsr = 0x00000000; /* Hit the STIC's csr again... */ tc_wmb(); sr->sr_buscsr = 0xffffffff; /* and bash its bus-access csr. */ - tc_wmb(); tc_syncbus(); /* Blam! */ DELAY(20000); /* wait until the stic recovers... */ @@ -402,7 +399,6 @@ stic_reset(struct stic_info *si) sr->sr_ipdvint = STIC_INT_WE | STIC_INT_P | STIC_INT_E_EN | STIC_INT_V_EN; sr->sr_sticsr = 8; - tc_wmb(); tc_syncbus(); } |
