提交 27b7c63a 编写于 作者: L Lauri Kasanen 提交者: Daniel Vetter

drm/i915: Fix build failure

ERROR: "__build_bug_on_failed" [drivers/gpu/drm/i915/i915.ko] undefined!

Originally reported at http://www.gossamer-threads.com/lists/linux/kernel/1631803
FDO bug #62775

This needs to be backported to both 3.7 and 3.8 stable trees. Doesn't apply straight,
but it's a quick change.
Signed-off-by: NLauri Kasanen <cand@gmx.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=62775
Cc: stable@vger.kernel.org
Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
上级 637f44d2
...@@ -57,7 +57,7 @@ eb_create(struct drm_i915_gem_execbuffer2 *args) ...@@ -57,7 +57,7 @@ eb_create(struct drm_i915_gem_execbuffer2 *args)
if (eb == NULL) { if (eb == NULL) {
int size = args->buffer_count; int size = args->buffer_count;
int count = PAGE_SIZE / sizeof(struct hlist_head) / 2; int count = PAGE_SIZE / sizeof(struct hlist_head) / 2;
BUILD_BUG_ON(!is_power_of_2(PAGE_SIZE / sizeof(struct hlist_head))); BUILD_BUG_ON_NOT_POWER_OF_2(PAGE_SIZE / sizeof(struct hlist_head));
while (count > 2*size) while (count > 2*size)
count >>= 1; count >>= 1;
eb = kzalloc(count*sizeof(struct hlist_head) + eb = kzalloc(count*sizeof(struct hlist_head) +
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册