[Intel-gfx] [PATCH 09/12] drm/i914: s/l_info/dimm_l/ etc.
Ville Syrjala
ville.syrjala at linux.intel.com
Mon Feb 25 20:29:04 UTC 2019
From: Ville Syrjälä <ville.syrjala at linux.intel.com>
Rename the dimm info structs for clarity.
Signed-off-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
---
drivers/gpu/drm/i915/i915_drv.c | 18 +++++++++---------
drivers/gpu/drm/i915/i915_drv.h | 2 +-
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c
index 9261bd0dccd6..21413069a480 100644
--- a/drivers/gpu/drm/i915/i915_drv.c
+++ b/drivers/gpu/drm/i915/i915_drv.c
@@ -1129,24 +1129,24 @@ static int
skl_dram_get_channel_info(struct dram_channel_info *ch,
int channel, u32 val)
{
- skl_dram_get_dimm_info(&ch->l_info, channel, 'L', val & 0xffff);
- skl_dram_get_dimm_info(&ch->s_info, channel, 'S', val >> 16);
+ skl_dram_get_dimm_info(&ch->dimm_l, channel, 'L', val & 0xffff);
+ skl_dram_get_dimm_info(&ch->dimm_s, channel, 'S', val >> 16);
- if (ch->l_info.size == 0 && ch->s_info.size == 0) {
+ if (ch->dimm_l.size == 0 && ch->dimm_s.size == 0) {
DRM_DEBUG_KMS("CH%d not populated\n", channel);
return -EINVAL;
}
- if (ch->l_info.ranks == 2 || ch->s_info.ranks == 2)
+ if (ch->dimm_l.ranks == 2 || ch->dimm_s.ranks == 2)
ch->ranks = 2;
- else if (ch->l_info.ranks == 1 && ch->s_info.ranks == 1)
+ else if (ch->dimm_l.ranks == 1 && ch->dimm_s.ranks == 1)
ch->ranks = 2;
else
ch->ranks = 1;
ch->is_16gb_dimm =
- skl_is_16gb_dimm(&ch->l_info) ||
- skl_is_16gb_dimm(&ch->s_info);
+ skl_is_16gb_dimm(&ch->dimm_l) ||
+ skl_is_16gb_dimm(&ch->dimm_s);
DRM_DEBUG_KMS("CH%d ranks: %d, 16Gb DIMMs: %s\n",
channel, ch->ranks, yesno(ch->is_16gb_dimm));
@@ -1159,8 +1159,8 @@ intel_is_dram_symmetric(const struct dram_channel_info *ch0,
const struct dram_channel_info *ch1)
{
return !memcmp(ch0, ch1, sizeof(*ch0)) &&
- (ch0->s_info.size == 0 ||
- !memcmp(&ch0->l_info, &ch0->s_info, sizeof(ch0->l_info)));
+ (ch0->dimm_s.size == 0 ||
+ !memcmp(&ch0->dimm_l, &ch0->dimm_s, sizeof(ch0->dimm_l)));
}
static int
diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
index fcde09934bb5..89881b68dcb4 100644
--- a/drivers/gpu/drm/i915/i915_drv.h
+++ b/drivers/gpu/drm/i915/i915_drv.h
@@ -2070,7 +2070,7 @@ struct dram_dimm_info {
};
struct dram_channel_info {
- struct dram_dimm_info l_info, s_info;
+ struct dram_dimm_info dimm_l, dimm_s;
u8 ranks;
bool is_16gb_dimm;
};
--
2.19.2
More information about the Intel-gfx
mailing list