mirror of
https://github.com/torvalds/linux.git
synced 2026-09-12 20:53:03 +02:00
Merge tag 'drm-intel-fixes-2026-09-03' of https://gitlab.freedesktop.org/drm/i915/kernel into drm-fixes
drm/i915 fixes for v7.3-rc2: - Drop an accidentally duplicated panel fitter call in DP MST - Fix DDI clock programming for Cx0 and LT PHY - Fix PTL CDCLK handling at probe, causing a glitch - Fix dg2_power_well_count() return type - Fix a NULL pointer deref at forced probe - Fix selective fetch disable Signed-off-by: Dave Airlie <airlied@redhat.com> From: Jani Nikula <jani.nikula@intel.com> Link: https://patch.msgid.link/affe11af9d5eb9dc6f906441495cb843f9d4817c@intel.com
This commit is contained in:
commit
5ff6e2f8a7
|
|
@ -2381,8 +2381,10 @@ static void bxt_sanitize_cdclk(struct intel_display *display)
|
|||
* dividers both syncing to an active pipe, or asynchronously
|
||||
* (PIPE_NONE).
|
||||
*/
|
||||
cdctl &= ~bxt_cdclk_cd2x_pipe_mask(display);
|
||||
cdctl |= bxt_cdclk_cd2x_pipe(display, INVALID_PIPE);
|
||||
if (DISPLAY_VER(display) < 30) {
|
||||
cdctl &= ~bxt_cdclk_cd2x_pipe_mask(display);
|
||||
cdctl |= bxt_cdclk_cd2x_pipe(display, INVALID_PIPE);
|
||||
}
|
||||
|
||||
if (cdctl != expected) {
|
||||
if (DISPLAY_VER(display) < 20) {
|
||||
|
|
@ -2713,8 +2715,8 @@ static void intel_set_cdclk(struct intel_display *display,
|
|||
}
|
||||
}
|
||||
|
||||
static bool dg2_power_well_count(struct intel_display *display,
|
||||
const struct intel_cdclk_state *cdclk_state)
|
||||
static int dg2_power_well_count(struct intel_display *display,
|
||||
const struct intel_cdclk_state *cdclk_state)
|
||||
{
|
||||
return display->platform.dg2 ? hweight8(cdclk_state->active_pipes) : 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -530,13 +530,18 @@ static int i9xx_check_cursor(struct intel_crtc_state *crtc_state,
|
|||
}
|
||||
|
||||
static void i9xx_cursor_disable_sel_fetch_arm(struct intel_dsb *dsb,
|
||||
struct intel_plane *plane,
|
||||
const struct intel_crtc_state *crtc_state)
|
||||
struct intel_plane *plane)
|
||||
{
|
||||
struct intel_display *display = to_intel_display(plane);
|
||||
enum pipe pipe = plane->pipe;
|
||||
|
||||
if (!crtc_state->enable_psr2_sel_fetch)
|
||||
/*
|
||||
* Clear this whenever the hardware has selective fetch, not just when
|
||||
* the current state uses it. The cursor may have been enabled with
|
||||
* selective fetch earlier and had its enable bit orphaned when the
|
||||
* feature was switched off.
|
||||
*/
|
||||
if (!HAS_PSR2_SEL_FETCH(display))
|
||||
return;
|
||||
|
||||
intel_de_write_dsb(display, dsb, SEL_FETCH_CUR_CTL(pipe), 0);
|
||||
|
|
@ -586,7 +591,7 @@ static void i9xx_cursor_update_sel_fetch_arm(struct intel_dsb *dsb,
|
|||
if (crtc_state->enable_psr2_su_region_et)
|
||||
wa_16021440873(dsb, plane, crtc_state, plane_state);
|
||||
else
|
||||
i9xx_cursor_disable_sel_fetch_arm(dsb, plane, crtc_state);
|
||||
i9xx_cursor_disable_sel_fetch_arm(dsb, plane);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -695,7 +700,7 @@ static void i9xx_cursor_update_arm(struct intel_dsb *dsb,
|
|||
if (plane_state)
|
||||
i9xx_cursor_update_sel_fetch_arm(dsb, plane, crtc_state, plane_state);
|
||||
else
|
||||
i9xx_cursor_disable_sel_fetch_arm(dsb, plane, crtc_state);
|
||||
i9xx_cursor_disable_sel_fetch_arm(dsb, plane);
|
||||
|
||||
if (plane->cursor.base != base ||
|
||||
plane->cursor.size != fbc_ctl ||
|
||||
|
|
|
|||
|
|
@ -3233,7 +3233,8 @@ static void intel_cx0pll_enable(struct intel_encoder *encoder,
|
|||
* 8. Program DDI_CLK_VALFREQ to match intended DDI
|
||||
* clock frequency.
|
||||
*/
|
||||
intel_de_write(display, DDI_CLK_VALFREQ(encoder->port), port_clock);
|
||||
intel_de_write(display, DDI_CLK_VALFREQ(encoder->port),
|
||||
intel_ddi_link_symbol_clock(encoder, port_clock));
|
||||
|
||||
/*
|
||||
* 9. Set PORT_CLOCK_CTL register PCLK PLL Request
|
||||
|
|
@ -3406,7 +3407,7 @@ void intel_mtl_tbt_pll_enable_clock(struct intel_encoder *encoder, int port_cloc
|
|||
* clock frequency.
|
||||
*/
|
||||
intel_de_write(display, DDI_CLK_VALFREQ(encoder->port),
|
||||
port_clock);
|
||||
intel_ddi_link_symbol_clock(encoder, port_clock));
|
||||
}
|
||||
|
||||
void intel_mtl_pll_enable(struct intel_encoder *encoder,
|
||||
|
|
|
|||
|
|
@ -1529,6 +1529,17 @@ int intel_ddi_level(struct intel_encoder *encoder,
|
|||
return level;
|
||||
}
|
||||
|
||||
int intel_ddi_link_symbol_clock(struct intel_encoder *encoder, int clock)
|
||||
{
|
||||
if (intel_encoder_is_dp(encoder))
|
||||
return intel_dp_link_symbol_clock(clock);
|
||||
|
||||
if (intel_hdmi_is_frl(clock))
|
||||
return DIV_ROUND_CLOSEST(clock * 10, 18);
|
||||
|
||||
return clock;
|
||||
}
|
||||
|
||||
static void
|
||||
hsw_set_signal_levels(struct intel_encoder *encoder,
|
||||
const struct intel_crtc_state *crtc_state)
|
||||
|
|
|
|||
|
|
@ -81,6 +81,7 @@ void intel_ddi_sanitize_encoder_pll_mapping(struct intel_encoder *encoder);
|
|||
int intel_ddi_level(struct intel_encoder *encoder,
|
||||
const struct intel_crtc_state *crtc_state,
|
||||
int lane);
|
||||
int intel_ddi_link_symbol_clock(struct intel_encoder *encoder, int clock);
|
||||
void intel_ddi_update_active_dpll(struct intel_atomic_state *state,
|
||||
struct intel_encoder *encoder,
|
||||
struct intel_crtc *crtc);
|
||||
|
|
|
|||
|
|
@ -761,10 +761,6 @@ static int mst_stream_compute_config(struct intel_atomic_state *state,
|
|||
pipe_config->sink_format = INTEL_OUTPUT_FORMAT_RGB;
|
||||
pipe_config->output_format = INTEL_OUTPUT_FORMAT_RGB;
|
||||
|
||||
ret = intel_pfit_compute_config(pipe_config, conn_state);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = intel_pfit_compute_config(pipe_config, conn_state);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
|
|
|||
|
|
@ -1976,7 +1976,8 @@ void intel_lt_phy_pll_enable(struct intel_encoder *encoder,
|
|||
* Change. We handle this step in bxt_set_cdclk().
|
||||
*/
|
||||
/* 10. Program DDI_CLK_VALFREQ to match intended DDI clock frequency. */
|
||||
intel_de_write(display, DDI_CLK_VALFREQ(encoder->port), port_clock);
|
||||
intel_de_write(display, DDI_CLK_VALFREQ(encoder->port),
|
||||
intel_ddi_link_symbol_clock(encoder, port_clock));
|
||||
|
||||
/* 11. Program PORT_CLOCK_CTL[PCLK PLL Request LN0] = 1. */
|
||||
intel_de_rmw(display, XELPDP_PORT_CLOCK_CTL(display, port),
|
||||
|
|
@ -2023,7 +2024,8 @@ void intel_lt_phy_pll_enable(struct intel_encoder *encoder,
|
|||
lane_phy_pulse_status,
|
||||
lane_phy_pulse_status);
|
||||
} else {
|
||||
intel_de_write(display, DDI_CLK_VALFREQ(encoder->port), port_clock);
|
||||
intel_de_write(display, DDI_CLK_VALFREQ(encoder->port),
|
||||
intel_ddi_link_symbol_clock(encoder, port_clock));
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -879,13 +879,18 @@ skl_plane_disable_arm(struct intel_dsb *dsb,
|
|||
}
|
||||
|
||||
static void icl_plane_disable_sel_fetch_arm(struct intel_dsb *dsb,
|
||||
struct intel_plane *plane,
|
||||
const struct intel_crtc_state *crtc_state)
|
||||
struct intel_plane *plane)
|
||||
{
|
||||
struct intel_display *display = to_intel_display(plane);
|
||||
enum pipe pipe = plane->pipe;
|
||||
|
||||
if (!crtc_state->enable_psr2_sel_fetch)
|
||||
/*
|
||||
* Clear this whenever the hardware has selective fetch, not just when
|
||||
* the current state uses it. The plane may have been enabled with
|
||||
* selective fetch earlier and had its enable bit orphaned when the
|
||||
* feature was switched off.
|
||||
*/
|
||||
if (!HAS_PSR2_SEL_FETCH(display))
|
||||
return;
|
||||
|
||||
intel_de_write_dsb(display, dsb, SEL_FETCH_PLANE_CTL(pipe, plane->id), 0);
|
||||
|
|
@ -921,7 +926,7 @@ icl_plane_disable_arm(struct intel_dsb *dsb,
|
|||
|
||||
skl_write_plane_wm(dsb, plane, crtc_state);
|
||||
|
||||
icl_plane_disable_sel_fetch_arm(dsb, plane, crtc_state);
|
||||
icl_plane_disable_sel_fetch_arm(dsb, plane);
|
||||
|
||||
if (plane_has_normalizer(plane))
|
||||
intel_de_write_dsb(display, dsb,
|
||||
|
|
@ -1641,7 +1646,7 @@ static void icl_plane_update_sel_fetch_arm(struct intel_dsb *dsb,
|
|||
intel_de_write_dsb(display, dsb, SEL_FETCH_PLANE_CTL(pipe, plane->id),
|
||||
SEL_FETCH_PLANE_CTL_ENABLE);
|
||||
else
|
||||
icl_plane_disable_sel_fetch_arm(dsb, plane, crtc_state);
|
||||
icl_plane_disable_sel_fetch_arm(dsb, plane);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
|
|
@ -958,6 +958,9 @@ static int i915_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
|
|||
(struct intel_device_info *) ent->driver_data;
|
||||
int err;
|
||||
|
||||
if (!intel_info)
|
||||
return -ENODEV;
|
||||
|
||||
if (intel_info->require_force_probe && !id_forced(pdev->device)) {
|
||||
dev_info(&pdev->dev,
|
||||
"Your graphics device %04x is not properly supported by i915 in this\n"
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user