From: Zeng Zhaoxiu Date: Sun, 6 Dec 2015 10:26:30 +0000 (+0800) Subject: i915: Replace "hweight8(dev_priv->info.subslice_7eu[i]) != 1" with "!is_power_of_2... X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a4d8a0fe4500b87817eebdb363c116922de87453;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git i915: Replace "hweight8(dev_priv->info.subslice_7eu[i]) != 1" with "!is_power_of_2(dev_priv->info.subslice_7eu[i])" Signed-off-by: Zeng Zhaoxiu Signed-off-by: Daniel Vetter Link: http://patchwork.freedesktop.org/patch/msgid/1449397590-14292-1-git-send-email-zhaoxiu.zeng@gmail.com --- diff --git a/drivers/gpu/drm/i915/intel_ringbuffer.c b/drivers/gpu/drm/i915/intel_ringbuffer.c index 57d78f264b53..e5359ebfb1be 100644 --- a/drivers/gpu/drm/i915/intel_ringbuffer.c +++ b/drivers/gpu/drm/i915/intel_ringbuffer.c @@ -27,6 +27,7 @@ * */ +#include #include #include "i915_drv.h" #include @@ -995,7 +996,7 @@ static int skl_tune_iz_hashing(struct intel_engine_cs *ring) * Only consider slices where one, and only one, subslice has 7 * EUs */ - if (hweight8(dev_priv->info.subslice_7eu[i]) != 1) + if (!is_power_of_2(dev_priv->info.subslice_7eu[i])) continue; /*