drm: mm: fix range restricted allocations
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Thu, 26 Aug 2010 19:44:17 +0000 (21:44 +0200)
committerDave Airlie <airlied@redhat.com>
Thu, 26 Aug 2010 23:10:16 +0000 (09:10 +1000)
commit7521473305f1379403b893a30ac09a2132dc1e25
tree594d1c7f2807da61abb20aa3febe0ca159c3bdeb
parent5afda9e9a4625d771795a5f540fb202eec08a49c
drm: mm: fix range restricted allocations

With the code cleanup in

7a6b2896f261894dde287d3faefa4b432cddca53 is the first bad commit
commit 7a6b2896f261894dde287d3faefa4b432cddca53
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date:   Fri Jul 2 15:02:15 2010 +0100

    drm_mm: extract check_free_mm_node

I've botched up the range-restriction checks. The result is usually
an X server dying with SIGBUS in libpixman (software fallback rendering).
Change the code to adjust the start and end for range restricted
allocations. IMHO this even makes the code a bit clearer.

Fixes regression bug: https://bugs.freedesktop.org/show_bug.cgi?id=29738

Reported-by-Tested-by: Till MAtthiesen <entropy@everymail.net>
Acked-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/drm_mm.c