drm: Simplify drm_mm scan-list manipulation
Since we mandate a strict reverse-order of drm_mm_scan_remove_block() after drm_mm_scan_add_block() we can further simplify the list manipulations when generating the temporary scan-hole. v2: Highlight the games being played with the lists to track the scan holes without allocation. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/20161222083641.2691-33-chris@chris-wilson.co.uk
This commit is contained in:

committed by
Daniel Vetter

parent
9a956b1548
commit
f29051f12f
@@ -74,11 +74,8 @@ struct drm_mm_node {
|
||||
struct list_head hole_stack;
|
||||
struct rb_node rb;
|
||||
unsigned hole_follows : 1;
|
||||
unsigned scanned_block : 1;
|
||||
unsigned scanned_prev_free : 1;
|
||||
unsigned scanned_next_free : 1;
|
||||
unsigned scanned_preceeds_hole : 1;
|
||||
unsigned allocated : 1;
|
||||
bool scanned_block : 1;
|
||||
unsigned long color;
|
||||
u64 start;
|
||||
u64 size;
|
||||
@@ -118,8 +115,6 @@ struct drm_mm_scan {
|
||||
u64 hit_start;
|
||||
u64 hit_end;
|
||||
|
||||
struct drm_mm_node *prev_scanned_node;
|
||||
|
||||
unsigned long color;
|
||||
unsigned int flags;
|
||||
};
|
||||
|
Reference in New Issue
Block a user