drm/i915: Pass lane count to bxt_ddi_phy_calc_lane_optmin_mask()
Pass lane count to bxt_ddi_phy_calc_lane_optmin_mask() instead of having it extract that number from a pipe_config to decouple the phy code from intel_crtc_state. Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/a4977e0207e594953c4f9d1b5f2ef972a8679e74.1475770848.git-series.ander.conselvan.de.oliveira@intel.com
This commit is contained in:
parent
362624c9ba
commit
b284eedaf7
@ -2190,9 +2190,9 @@ bool bxt_ddi_phy_verify_state(struct drm_i915_private *dev_priv,
|
|||||||
|
|
||||||
static uint8_t
|
static uint8_t
|
||||||
bxt_ddi_phy_calc_lane_lat_optim_mask(struct intel_encoder *encoder,
|
bxt_ddi_phy_calc_lane_lat_optim_mask(struct intel_encoder *encoder,
|
||||||
struct intel_crtc_state *pipe_config)
|
uint8_t lane_count)
|
||||||
{
|
{
|
||||||
switch (pipe_config->lane_count) {
|
switch (lane_count) {
|
||||||
case 1:
|
case 1:
|
||||||
return 0;
|
return 0;
|
||||||
case 2:
|
case 2:
|
||||||
@ -2200,7 +2200,7 @@ bxt_ddi_phy_calc_lane_lat_optim_mask(struct intel_encoder *encoder,
|
|||||||
case 4:
|
case 4:
|
||||||
return BIT(3) | BIT(2) | BIT(0);
|
return BIT(3) | BIT(2) | BIT(0);
|
||||||
default:
|
default:
|
||||||
MISSING_CASE(pipe_config->lane_count);
|
MISSING_CASE(lane_count);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@ -2417,7 +2417,7 @@ static bool intel_ddi_compute_config(struct intel_encoder *encoder,
|
|||||||
if (IS_BROXTON(dev_priv) && ret)
|
if (IS_BROXTON(dev_priv) && ret)
|
||||||
pipe_config->lane_lat_optim_mask =
|
pipe_config->lane_lat_optim_mask =
|
||||||
bxt_ddi_phy_calc_lane_lat_optim_mask(encoder,
|
bxt_ddi_phy_calc_lane_lat_optim_mask(encoder,
|
||||||
pipe_config);
|
pipe_config->lane_count);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user