diff options
author | Imre Deak | 2016-08-31 18:13:05 +0200 |
---|---|---|
committer | Imre Deak | 2016-09-02 17:17:47 +0200 |
commit | 57ec171eae21ee0a2848ade1cb7f8f12a31b0731 (patch) | |
tree | 45b5084e47a82c27286a3b3e9473d6b3fb463ea1 /drivers/gpu/drm/i915/i915_drv.c | |
parent | drm/i915: sseu: Convert slice count field to mask (diff) | |
download | kernel-qcow2-linux-57ec171eae21ee0a2848ade1cb7f8f12a31b0731.tar.gz kernel-qcow2-linux-57ec171eae21ee0a2848ade1cb7f8f12a31b0731.tar.xz kernel-qcow2-linux-57ec171eae21ee0a2848ade1cb7f8f12a31b0731.zip |
drm/i915: sseu: Convert subslice count fields to subslice mask
In an upcoming patch we'll need the actual mask of subslices in addition
to their count, so convert the subslice_per_slice field to a mask.
Also we can easily calculate subslice_total from the other fields, so
instead of storing a cached version of this, add a helper to calculate
it.
v2:
- Use hweight8() on u8 typed vars instead of hweight32(). (Ben)
Reviewed-by: Robert Bragg <robert@sixbynine.org> (v1)
Reviewed-by: Ben Widawsky <benjamin.widawsky@intel.com> (v1)
Tested-by: Ben Widawsky <benjamin.widawsky@intel.com> (v1)
Signed-off-by: Imre Deak <imre.deak@intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_drv.c')
-rw-r--r-- | drivers/gpu/drm/i915/i915_drv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c index 5e22105b728f..02c34d6996ea 100644 --- a/drivers/gpu/drm/i915/i915_drv.c +++ b/drivers/gpu/drm/i915/i915_drv.c @@ -288,7 +288,7 @@ static int i915_getparam(struct drm_device *dev, void *data, value = i915_cmd_parser_get_version(dev_priv); break; case I915_PARAM_SUBSLICE_TOTAL: - value = INTEL_INFO(dev_priv)->sseu.subslice_total; + value = sseu_subslice_total(&INTEL_INFO(dev_priv)->sseu); if (!value) return -ENODEV; break; |