summaryrefslogtreecommitdiffstats
path: root/sys/alpha/pci
diff options
context:
space:
mode:
authorticso <ticso@FreeBSD.org>2005-09-19 13:50:07 +0000
committerticso <ticso@FreeBSD.org>2005-09-19 13:50:07 +0000
commit67624ed0f75907065578f29229d87b84e7a071fc (patch)
treee5a92c6294c73c413dd73635b6ace4b05147b50f /sys/alpha/pci
parentdb795b2c7606fa5ffdcc900c11384e51ad99d8b1 (diff)
downloadFreeBSD-src-67624ed0f75907065578f29229d87b84e7a071fc.zip
FreeBSD-src-67624ed0f75907065578f29229d87b84e7a071fc.tar.gz
Relocate direct map specs into struct alpha_chipset.
Prepare for PCI Scatter-Gather map. Panic if driver tries alpha_XXX_dmamap() out of range.
Diffstat (limited to 'sys/alpha/pci')
-rw-r--r--sys/alpha/pci/apecs.c3
-rw-r--r--sys/alpha/pci/cia.c3
-rw-r--r--sys/alpha/pci/irongate.c4
-rw-r--r--sys/alpha/pci/lca.c4
-rw-r--r--sys/alpha/pci/t2.c3
-rw-r--r--sys/alpha/pci/tsunami.c4
6 files changed, 18 insertions, 3 deletions
diff --git a/sys/alpha/pci/apecs.c b/sys/alpha/pci/apecs.c
index 3faf1e1..a5c9c26 100644
--- a/sys/alpha/pci/apecs.c
+++ b/sys/alpha/pci/apecs.c
@@ -235,6 +235,9 @@ apecs_init_sgmap(void)
chipset.sgmap = sgmap_map_create(APECS_SGMAP_BASE,
APECS_SGMAP_BASE + APECS_SGMAP_SIZE,
apecs_sgmap_map, sgtable);
+ chipset.pci_sgmap = NULL;
+ chipset.dmsize = 1UL * 1024UL * 1024UL * 1024UL;
+ chipset.dmoffset = 1UL * 1024UL * 1024UL * 1024UL;
}
void
diff --git a/sys/alpha/pci/cia.c b/sys/alpha/pci/cia.c
index 91deb35..c025bbf 100644
--- a/sys/alpha/pci/cia.c
+++ b/sys/alpha/pci/cia.c
@@ -314,6 +314,9 @@ cia_init_sgmap(void)
chipset.sgmap = sgmap_map_create(CIA_SGMAP_BASE,
CIA_SGMAP_BASE + CIA_SGMAP_SIZE - 1,
cia_sgmap_map, sgtable);
+ chipset.pci_sgmap = NULL;
+ chipset.dmsize = 1UL * 1024UL * 1024UL * 1024UL;
+ chipset.dmoffset = 1UL * 1024UL * 1024UL * 1024UL;
if (cia_ispyxis) {
/*
diff --git a/sys/alpha/pci/irongate.c b/sys/alpha/pci/irongate.c
index a744c3d..6092bd7 100644
--- a/sys/alpha/pci/irongate.c
+++ b/sys/alpha/pci/irongate.c
@@ -123,7 +123,6 @@ irongate_init()
initted = 1;
chipset = irongate_chipset;
- alpha_XXX_dmamap_or = 0UL;
bwx_init_space(&io_space, KV(IRONGATE_IO));
bwx_init_space(&mem_space, KV(IRONGATE_MEM));
@@ -166,6 +165,9 @@ irongate_attach(device_t dev)
chipset_dense = IRONGATE_MEM;
/* no s/g support in this chipset, must use bounce-buffers */
chipset.sgmap = NULL;
+ chipset.pci_sgmap = NULL;
+ chipset.dmsize = 4UL * 1024UL * 1024UL * 1024UL;
+ chipset.dmoffset = 0;
bus_generic_attach(dev);
diff --git a/sys/alpha/pci/lca.c b/sys/alpha/pci/lca.c
index e279555..c631a93 100644
--- a/sys/alpha/pci/lca.c
+++ b/sys/alpha/pci/lca.c
@@ -186,7 +186,9 @@ lca_init_sgmap(void)
chipset.sgmap = sgmap_map_create(LCA_SGMAP_BASE,
LCA_SGMAP_BASE + LCA_SGMAP_SIZE,
lca_sgmap_map, sgtable);
-
+ chipset.pci_sgmap = NULL;
+ chipset.dmsize = 1UL * 1024UL * 1024UL * 1024UL;
+ chipset.dmoffset = 1UL * 1024UL * 1024UL * 1024UL;
REGVAL64(LCA_IOC_W_T_BASE0) = pmap_kextract((vm_offset_t) sgtable);
alpha_mb();
diff --git a/sys/alpha/pci/t2.c b/sys/alpha/pci/t2.c
index b1c0b26..fb412cc 100644
--- a/sys/alpha/pci/t2.c
+++ b/sys/alpha/pci/t2.c
@@ -252,6 +252,9 @@ t2_init_sgmap(int h)
chipset.sgmap = sgmap_map_create(T2_SGMAP_BASE,
T2_SGMAP_BASE + T2_SGMAP_SIZE,
t2_sgmap_map, sgtable);
+ chipset.pci_sgmap = NULL;
+ chipset.dmsize = 2UL * 1024UL * 1024UL * 1024UL;
+ chipset.dmoffset = 1UL * 1024UL * 1024UL * 1024UL;
}
static void
diff --git a/sys/alpha/pci/tsunami.c b/sys/alpha/pci/tsunami.c
index 23dd370..bef551a 100644
--- a/sys/alpha/pci/tsunami.c
+++ b/sys/alpha/pci/tsunami.c
@@ -234,6 +234,7 @@ tsunami_init_sgmap(void)
chipset.sgmap = sgmap_map_create(TSUNAMI_SGMAP_BASE,
TSUNAMI_SGMAP_BASE + TSUNAMI_SGMAP_SIZE,
tsunami_sgmap_map, sgtable);
+ chipset.pci_sgmap = NULL;
}
void
@@ -258,7 +259,8 @@ tsunami_init()
chipset = tsunami_chipset;
platform.pci_intr_enable = tsunami_intr_enable;
platform.pci_intr_disable = tsunami_intr_disable;
- alpha_XXX_dmamap_or = 2UL * 1024UL * 1024UL * 1024UL;
+ chipset.dmsize = 2UL * 1024UL * 1024UL * 1024UL;
+ chipset.dmoffset = 2UL * 1024UL * 1024UL * 1024UL;
if (platform.pci_intr_init)
platform.pci_intr_init();
OpenPOWER on IntegriCloud