Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/alpha/pci Do the previously slightly differently, t...
details: https://anonhg.NetBSD.org/src/rev/1ac450a3bfba
branches: trunk
changeset: 493902:1ac450a3bfba
user: thorpej <thorpej%NetBSD.org@localhost>
date: Mon Jun 26 18:19:26 2000 +0000
description:
Do the previously slightly differently, to avoid confusing the internal
space extent maps. Pointed out by msaitoh%netbsd.org@localhost. (Someone should
send me an EV6 machine!)
diffstat:
sys/arch/alpha/pci/irongate.c | 14 +++++++++++---
sys/arch/alpha/pci/pci_bwx_bus_io_chipdep.c | 12 +++---------
sys/arch/alpha/pci/pci_bwx_bus_mem_chipdep.c | 12 +++---------
sys/arch/alpha/pci/tsc.c | 14 +++++++++++---
4 files changed, 28 insertions(+), 24 deletions(-)
diffs (146 lines):
diff -r 8684392170fa -r 1ac450a3bfba sys/arch/alpha/pci/irongate.c
--- a/sys/arch/alpha/pci/irongate.c Mon Jun 26 17:36:56 2000 +0000
+++ b/sys/arch/alpha/pci/irongate.c Mon Jun 26 18:19:26 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: irongate.c,v 1.1 2000/06/01 20:30:30 thorpej Exp $ */
+/* $NetBSD: irongate.c,v 1.2 2000/06/26 18:19:26 thorpej Exp $ */
/*-
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -40,7 +40,7 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: irongate.c,v 1.1 2000/06/01 20:30:30 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: irongate.c,v 1.2 2000/06/26 18:19:26 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -198,6 +198,7 @@
{
struct irongate_config *icp = &irongate_configuration;
bus_space_tag_t st;
+ int error;
switch (type) {
case ALPHA_BUS_TYPE_PCI_IO:
@@ -212,5 +213,12 @@
panic("irongate_bus_get_window");
}
- return (alpha_bus_space_get_window(st, window, abst));
+ error = alpha_bus_space_get_window(st, window, abst);
+ if (error)
+ return (error);
+
+ abst->abst_sys_start = IRONGATE_PHYSADDR(abst->abst_sys_start);
+ abst->abst_sys_end = IRONGATE_PHYSADDR(abst->abst_sys_end);
+
+ return (0);
}
diff -r 8684392170fa -r 1ac450a3bfba sys/arch/alpha/pci/pci_bwx_bus_io_chipdep.c
--- a/sys/arch/alpha/pci/pci_bwx_bus_io_chipdep.c Mon Jun 26 17:36:56 2000 +0000
+++ b/sys/arch/alpha/pci/pci_bwx_bus_io_chipdep.c Mon Jun 26 18:19:26 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pci_bwx_bus_io_chipdep.c,v 1.10 2000/06/26 02:42:10 thorpej Exp $ */
+/* $NetBSD: pci_bwx_bus_io_chipdep.c,v 1.11 2000/06/26 18:19:26 thorpej Exp $ */
/*-
* Copyright (c) 1997, 1998, 2000 The NetBSD Foundation, Inc.
@@ -213,10 +213,6 @@
#define CHIP_IO_EX_STORE_SIZE(v) (sizeof __C(CHIP, _io_ex_storage))
#endif
-#ifndef CHIP_PHYSADDR
-#define CHIP_PHYSADDR(x) (x)
-#endif
-
void
__C(CHIP,_bus_io_init)(t, v)
bus_space_tag_t t;
@@ -340,10 +336,8 @@
case 0:
abst->abst_bus_start = 0;
abst->abst_bus_end = 0xffffffffUL;
- abst->abst_sys_start =
- CHIP_PHYSADDR(CHIP_IO_SYS_START(v));
- abst->abst_sys_end =
- CHIP_PHYSADDR(CHIP_IO_SYS_START(v) + abst->abst_bus_end);
+ abst->abst_sys_start = CHIP_IO_SYS_START(v);
+ abst->abst_sys_end = CHIP_IO_SYS_START(v) + abst->abst_bus_end;
abst->abst_addr_shift = 0;
abst->abst_size_shift = 0;
abst->abst_flags = ABST_DENSE|ABST_BWX;
diff -r 8684392170fa -r 1ac450a3bfba sys/arch/alpha/pci/pci_bwx_bus_mem_chipdep.c
--- a/sys/arch/alpha/pci/pci_bwx_bus_mem_chipdep.c Mon Jun 26 17:36:56 2000 +0000
+++ b/sys/arch/alpha/pci/pci_bwx_bus_mem_chipdep.c Mon Jun 26 18:19:26 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pci_bwx_bus_mem_chipdep.c,v 1.11 2000/06/26 02:42:10 thorpej Exp $ */
+/* $NetBSD: pci_bwx_bus_mem_chipdep.c,v 1.12 2000/06/26 18:19:26 thorpej Exp $ */
/*-
* Copyright (c) 1997, 1998, 2000 The NetBSD Foundation, Inc.
@@ -213,10 +213,6 @@
#define CHIP_MEM_EX_STORE_SIZE(v) (sizeof __C(CHIP,_mem_ex_storage))
#endif
-#ifndef CHIP_PHYSADDR
-#define CHIP_PHYSADDR(x) (x)
-#endif
-
void
__C(CHIP,_bus_mem_init)(t, v)
bus_space_tag_t t;
@@ -334,10 +330,8 @@
case 0:
abst->abst_bus_start = 0;
abst->abst_bus_end = 0xffffffffUL;
- abst->abst_sys_start =
- CHIP_PHYSADDR(CHIP_MEM_SYS_START(v));
- abst->abst_sys_end =
- CHIP_PHYSADDR(CHIP_MEM_SYS_START(v) + abst->abst_bus_end);
+ abst->abst_sys_start = CHIP_MEM_SYS_START(v);
+ abst->abst_sys_end = CHIP_MEM_SYS_START(v) + abst->abst_bus_end;
abst->abst_addr_shift = 0;
abst->abst_size_shift = 0;
abst->abst_flags = ABST_DENSE|ABST_BWX;
diff -r 8684392170fa -r 1ac450a3bfba sys/arch/alpha/pci/tsc.c
--- a/sys/arch/alpha/pci/tsc.c Mon Jun 26 17:36:56 2000 +0000
+++ b/sys/arch/alpha/pci/tsc.c Mon Jun 26 18:19:26 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: tsc.c,v 1.3 2000/06/25 19:17:40 thorpej Exp $ */
+/* $NetBSD: tsc.c,v 1.4 2000/06/26 18:19:27 thorpej Exp $ */
/*-
* Copyright (c) 1999 by Ross Harvey. All rights reserved.
@@ -35,7 +35,7 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: tsc.c,v 1.3 2000/06/25 19:17:40 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tsc.c,v 1.4 2000/06/26 18:19:27 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -241,6 +241,7 @@
{
struct tsp_config *tsp = &tsp_configuration[tsp_console_hose];
bus_space_tag_t st;
+ int error;
switch (type) {
case ALPHA_BUS_TYPE_PCI_IO:
@@ -255,5 +256,12 @@
panic("tsp_bus_get_window");
}
- return (alpha_bus_space_get_window(st, window, abst));
+ error = alpha_bus_space_get_window(st, window, abst);
+ if (error)
+ return (error);
+
+ abst->abst_sys_start = TS_PHYSADDR(abst->abst_sys_start);
+ abst->abst_sys_end = TS_PHYSADDR(abst->abst_sys_end);
+
+ return (0);
}
Home |
Main Index |
Thread Index |
Old Index