projects
/
platform
/
upstream
/
libdrm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
659e9a0
)
Fixup test for memory at end of memory space
author
Dave Airlie
<airlied@linux.ie>
Sat, 18 Feb 2006 02:34:53 +0000
(
02:34
+0000)
committer
Dave Airlie
<airlied@linux.ie>
Sat, 18 Feb 2006 02:34:53 +0000
(
02:34
+0000)
linux-core/drm_bufs.c
patch
|
blob
|
history
diff --git
a/linux-core/drm_bufs.c
b/linux-core/drm_bufs.c
index
5e70e47
..
c6dc277
100644
(file)
--- a/
linux-core/drm_bufs.c
+++ b/
linux-core/drm_bufs.c
@@
-154,7
+154,7
@@
int drm_addmap_core(drm_device_t * dev, unsigned int offset,
case _DRM_REGISTERS:
case _DRM_FRAME_BUFFER:
#if !defined(__sparc__) && !defined(__alpha__) && !defined(__ia64__) && !defined(__powerpc64__) && !defined(__x86_64__)
- if (map->offset +
map->size
< map->offset ||
+ if (map->offset +
(map->size - 1)
< map->offset ||
map->offset < virt_to_phys(high_memory)) {
drm_free(map, sizeof(*map), DRM_MEM_MAPS);
return -EINVAL;