summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/hppa/dev/dino.c14
-rw-r--r--sys/arch/hppa/dev/elroy.c10
2 files changed, 20 insertions, 4 deletions
diff --git a/sys/arch/hppa/dev/dino.c b/sys/arch/hppa/dev/dino.c
index 639fe3da2c4..d77af850be4 100644
--- a/sys/arch/hppa/dev/dino.c
+++ b/sys/arch/hppa/dev/dino.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dino.c,v 1.22 2007/05/23 18:07:19 kettenis Exp $ */
+/* $OpenBSD: dino.c,v 1.23 2007/08/28 21:19:17 kettenis Exp $ */
/*
* Copyright (c) 2003-2005 Michael Shalayeff
@@ -179,6 +179,7 @@ void dino_unmap(void *, bus_space_handle_t, bus_size_t);
void dino_free(void *, bus_space_handle_t, bus_size_t);
void dino_barrier(void *, bus_space_handle_t, bus_size_t, bus_size_t, int);
void * dino_alloc_parent(struct device *, struct pci_attach_args *, int);
+void * dino_vaddr(void *, bus_space_handle_t);
u_int8_t dino_r1(void *, bus_space_handle_t, bus_size_t);
u_int16_t dino_r2(void *, bus_space_handle_t, bus_size_t);
u_int32_t dino_r4(void *, bus_space_handle_t, bus_size_t);
@@ -634,6 +635,15 @@ dino_alloc_parent(struct device *self, struct pci_attach_args *pa, int io)
}
#endif
+void *
+dino_vaddr(void *v, bus_space_handle_t h)
+{
+ if (h & 0xf0000000)
+ return ((void *)h);
+ else
+ return (NULL);
+}
+
u_int8_t
dino_r1(void *v, bus_space_handle_t h, bus_size_t o)
{
@@ -1475,7 +1485,7 @@ const struct hppa_bus_space_tag dino_iomemt = {
NULL,
NULL, dino_unmap, dino_subregion, NULL, dino_free,
- dino_barrier, NULL,
+ dino_barrier, dino_vaddr,
dino_r1, dino_r2, dino_r4, dino_r8,
dino_w1, dino_w2, dino_w4, dino_w8,
dino_rm_1, dino_rm_2, dino_rm_4, dino_rm_8,
diff --git a/sys/arch/hppa/dev/elroy.c b/sys/arch/hppa/dev/elroy.c
index df499df1e3d..15a8a5515d9 100644
--- a/sys/arch/hppa/dev/elroy.c
+++ b/sys/arch/hppa/dev/elroy.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: elroy.c,v 1.3 2007/06/17 14:51:21 kettenis Exp $ */
+/* $OpenBSD: elroy.c,v 1.4 2007/08/28 21:19:44 kettenis Exp $ */
/*
* Copyright (c) 2005 Michael Shalayeff
@@ -346,6 +346,12 @@ elroy_alloc_parent(struct device *self, struct pci_attach_args *pa, int io)
}
#endif
+void *
+elroy_vaddr(void *v, bus_space_handle_t h)
+{
+ return ((void *)h);
+}
+
u_int8_t
elroy_r1(void *v, bus_space_handle_t h, bus_size_t o)
{
@@ -905,7 +911,7 @@ const struct hppa_bus_space_tag elroy_iomemt = {
NULL,
NULL, elroy_unmap, elroy_subregion, NULL, elroy_free,
- elroy_barrier, NULL,
+ elroy_barrier, elroy_vaddr,
elroy_r1, elroy_r2, elroy_r4, elroy_r8,
elroy_w1, elroy_w2, elroy_w4, elroy_w8,
elroy_rm_1, elroy_rm_2, elroy_rm_4, elroy_rm_8,