fixup bens fix so it works..

main
Dave Airlie 2005-09-30 03:39:02 +00:00
parent 68b4ad3cce
commit 856bdf0f67
1 changed files with 4 additions and 3 deletions

View File

@ -56,7 +56,8 @@ static drm_map_list_t *drm_find_matching_map(drm_device_t *dev,
list_for_each(list, &dev->maplist->head) {
drm_map_list_t *entry = list_entry(list, drm_map_list_t, head);
if (entry->map && map->type == entry->map->type &&
entry->map->offset == map->offset) {
((entry->map->offset == map->offset) ||
(map->type == _DRM_SHM && map->flags==_DRM_CONTAINS_LOCK))) {
return entry;
}
}
@ -188,8 +189,8 @@ int drm_addmap_core(drm_device_t * dev, unsigned int offset,
MTRR_TYPE_WRCOMB, 1);
}
}
//if (map->type == _DRM_REGISTERS)
map->handle = drm_ioremap(map->offset, map->size, dev);
if (map->type == _DRM_REGISTERS)
map->handle = drm_ioremap(map->offset, map->size, dev);
break;
case _DRM_SHM:
list = drm_find_matching_map(dev, map);