Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/riastradh-drm2]: src/sys/external/bsd/drm2/dist/drm Replace ioremap/ioun...
details: https://anonhg.NetBSD.org/src/rev/956e256ff0ca
branches: riastradh-drm2
changeset: 788072:956e256ff0ca
user: riastradh <riastradh%NetBSD.org@localhost>
date: Wed Jul 24 02:06:04 2013 +0000
description:
Replace ioremap/iounmap by drm_ioremap/drm_iounmap in drm_bufs.c.
diffstat:
sys/external/bsd/drm2/dist/drm/drm_bufs.c | 16 ++++++++++++++++
1 files changed, 16 insertions(+), 0 deletions(-)
diffs (51 lines):
diff -r f20798ea42e7 -r 956e256ff0ca sys/external/bsd/drm2/dist/drm/drm_bufs.c
--- a/sys/external/bsd/drm2/dist/drm/drm_bufs.c Wed Jul 24 02:05:49 2013 +0000
+++ b/sys/external/bsd/drm2/dist/drm/drm_bufs.c Wed Jul 24 02:06:04 2013 +0000
@@ -211,7 +211,11 @@
}
}
if (map->type == _DRM_REGISTERS) {
+#ifdef __NetBSD__
+ map->handle = drm_ioremap(dev, map);
+#else
map->handle = ioremap(map->offset, map->size);
+#endif
if (!map->handle) {
kfree(map);
return -ENOMEM;
@@ -337,7 +341,11 @@
list = kzalloc(sizeof(*list), GFP_KERNEL);
if (!list) {
if (map->type == _DRM_REGISTERS)
+#ifdef __NetBSD__
+ drm_iounmap(dev, map);
+#else
iounmap(map->handle);
+#endif
kfree(map);
return -EINVAL;
}
@@ -354,7 +362,11 @@
(map->type == _DRM_SHM));
if (ret) {
if (map->type == _DRM_REGISTERS)
+#ifdef __NetBSD__
+ drm_iounmap(dev, map);
+#else
iounmap(map->handle);
+#endif
kfree(map);
kfree(list);
mutex_unlock(&dev->struct_mutex);
@@ -452,7 +464,11 @@
switch (map->type) {
case _DRM_REGISTERS:
+#ifdef __NetBSD__
+ drm_iounmap(dev, map);
+#else
iounmap(map->handle);
+#endif
/* FALLTHROUGH */
case _DRM_FRAME_BUFFER:
if (drm_core_has_MTRR(dev) && map->mtrr >= 0) {
Home |
Main Index |
Thread Index |
Old Index