OSDN Git Service

drm/i915: Polish skl_is_16gb_dimm()
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Wed, 6 Mar 2019 20:35:42 +0000 (22:35 +0200)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Thu, 7 Mar 2019 21:16:29 +0000 (23:16 +0200)
commit54561b238b1994d7ffe586b9d85ddf3c39a5a37c
tree384567e70ab29b04f69d5f53a475f9e226793be5
parentea411e6b85df938eaa3ec4e3e34e885ff496a3ce
drm/i915: Polish skl_is_16gb_dimm()

Pass the dimm struct to skl_is_16gb_dimm() rather than passing each
value separately. And let's replace the hardcoded set of values with
some simple arithmetic.

Also fix the byte vs. bit inconsistency in the debug message,
and polish the wording otherwise as well.

v2: Deobfuscate the math (Chris)

Reviewed-by: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190306203551.24592-4-ville.syrjala@linux.intel.com
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/i915_drv.h