[PATCH] drm/i915/scaler: Fix WA_14011503117

2025-08-05 Thread Suraj Kandpal
This introduces and uses a variable id which is just uninitialized. What really needs to be used is the scaler_id. Fixes: 73309ed9d598 ("drm/i915/display: WA_14011503117") Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/skl_scaler.c | 5 +++-- 1 file changed, 3 insert

[PATCH v4 3/3] drm/i915/edp: eDP Data Overrride

2025-07-31 Thread Suraj Kandpal
final set of link rates [Ankit] -Break this patch up [Ankit] -Optimize the assingment during loop [Ankit] --v3 -Add protection against broken VBTs [Jani] --v4 -Fix build errors -Create a seprate function to check if edp data override is selected and using the correct vbt Signed-off-by: Suraj Ka

[PATCH v3 1/3] drm/i915/vbt: Add eDP Data rate overrride field in VBT

2025-07-30 Thread Suraj Kandpal
Add edp_data_rate_override field VBT which gives us a mask of rates which needs to be skipped in favour of subsequent higher rate. --v2 -Rename vbt field [Jani] -Fix comment to 263+ [Jani] -Use BIT_U32 [Jani] -Fix the bits assignment in vbt [Jani] Bspec: 20124 Signed-off-by: Suraj Kandpal

[PATCH v3 3/3] drm/i915/edp: eDP Data Overrride

2025-07-30 Thread Suraj Kandpal
final set of link rates [Ankit] -Break this patch up [Ankit] -Optimize the assingment during loop [Ankit] --v3 -Add protection against broken VBTs [Jani] Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_dp.c | 29 + 1 file changed, 29 insertions(+)

[PATCH v3 2/3] drm/i915/bios: Add function to check if edp data override is needed

2025-07-30 Thread Suraj Kandpal
[Jani] Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_bios.c | 29 +++ drivers/gpu/drm/i915/display/intel_bios.h | 2 ++ 2 files changed, 31 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_bios.c b/drivers/gpu/drm/i915/display

[PATCH v3 0/3] eDP Data Override

2025-07-30 Thread Suraj Kandpal
--v2 -Break 2nd patch to two parts -Rename intel bios parse function -Create seprate function for setting rates -v3 -Fix VBT definition -Rename intel bios function -Make the function only return mask -Protect against broken VBT HSD:14022096069 Signed-off-by: Suraj Kandpal Suraj Kandpal (3): drm

[PATCH 3/3] drm/i915/edp: eDP Data Overrride

2025-07-24 Thread Suraj Kandpal
final set of link rates [Ankit] -Break this patch up [Ankit] -Optimize the assingment during loop [Ankit] Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_dp.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/dr

[PATCH 2/3] drm/i915/bios: Add function to check if edp data override is needed

2025-07-24 Thread Suraj Kandpal
Add a function that helps identify if the rate provided needs to be overridden. For this we need a function that compares the rate provided and bitmask of rates provided in VBT. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_bios.c | 58 +++ drivers/gpu

[PATCH 1/3] drm/i915/vbt: Add eDP Data Overrride field in VBT

2025-07-24 Thread Suraj Kandpal
Add a field which add the edp_data_override field VBT which gives us a mask of rates which need to be skipped in favour of subsequent higher rate. Bspec: 20124 Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_bios.c | 4 +++- drivers/gpu/drm/i915/display/intel_vbt_defs.h

[PATCH 0/3] eDP Data Override

2025-07-24 Thread Suraj Kandpal
-by: Suraj Kandpal Suraj Kandpal (3): drm/i915/vbt: Add eDP Data Overrride field in VBT drm/i915/bios: Add function to check if edp data override is needed drm/i915/edp: eDP Data Overrride drivers/gpu/drm/i915/display/intel_bios.c | 62 ++- drivers/gpu/drm/i915/display

[PATCH 27/28] drm/i915/writeback: Make exception for writeback connector

2025-07-24 Thread Suraj Kandpal
Writeback connector is a special connector as it does not actually exist. This means a lot of checks and computations need to be skipped and exceptions need to be made when it comes to this connector. This commit contains all those changes for a writeback connector. Signed-off-by: Suraj Kandpal

[PATCH 28/28] drm/i915/writeback: Modify state verify function

2025-07-24 Thread Suraj Kandpal
Modify the state verify functions to take into account the fact that writeback does not need all the timings for it to be set. Moreover there is no need for dpll state nor do we need to set any sort of flags for it. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_display.c

[PATCH 26/28] drm/i915/writeback: Define the disable sequence for writeback

2025-07-24 Thread Suraj Kandpal
Define the disable sequence for a writeback encoder. We only disable the encoder if no writeback job is pending, if it is then we just need to disable the wd function so that values can be updated accordingly. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_writeback.c| 28

[PATCH 25/28] drm/i915/writeback: Initialize writeback encoder.

2025-07-24 Thread Suraj Kandpal
Call the init function to initialize the writeback encoder only for ADLP. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_display.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display

[PATCH 24/28] drm/i915/writeback: Enable writeback interrupts

2025-07-24 Thread Suraj Kandpal
Enable writeback interrupts while enabling writeback and define the isr handler and schedule work for later to signal completion job. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_display_irq.c | 10 .../gpu/drm/i915/display/intel_display_regs.h | 1 + .../gpu/drm/i915

[PATCH 23/28] drm/i915/writeback: Configure WD_SURF register

2025-07-24 Thread Suraj Kandpal
Get the ggtt_offset of the drm_framebuffer which needs to be written to the surface base address bits of WD_SURF register. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_writeback.c | 3 +++ drivers/gpu/drm/i915/display/intel_writeback_reg.h | 2 ++ 2 files changed, 5

[PATCH 22/28] drm/i915/writeback: Configure WD_STRIDE reg

2025-07-24 Thread Suraj Kandpal
Write to the WD_STRIDE register using the appropriate calculation based on the color mode and hactive. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_writeback.c| 34 +++ .../drm/i915/display/intel_writeback_reg.h| 1 + 2 files changed, 35 insertions

[PATCH 21/28] drm/i915/writeback: Define writeback frame capture function

2025-07-24 Thread Suraj Kandpal
Define the commit function to be called at atomic_commit_tail if drm_writeback_job is available. This function calls the capture function and queues the job to be called later via interrupt handler when the job is complete. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display

[PATCH 20/28] drm/i915/writeback: Add writeback to xe Makefile

2025-07-24 Thread Suraj Kandpal
Add a intel_writeback.c to xe so that it builds for xe. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/xe/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/xe/Makefile b/drivers/gpu/drm/xe/Makefile index 76f980475b2c..0551e75b2569 100644 --- a/drivers/gpu/drm/xe

[PATCH 19/28] drm/i915/writeback: Add the enable sequence from writeback

2025-07-24 Thread Suraj Kandpal
Add enable sequence for writeback, use encoder->enable hook to enable the transcoder. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_writeback.c| 104 ++ 1 file changed, 104 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_writeback.c

[PATCH 18/28] drm/i915/writeback: Add connector atomic check

2025-07-24 Thread Suraj Kandpal
Add connector helper function for atomic check which sets the mode_changed bit and checks if pixel format of fb is valid or not. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_writeback.c| 49 +++ 1 file changed, 49 insertions(+) diff --git a/drivers/gpu

[PATCH 17/28] drm/i915/writeback: Define function to destroy writeback connector

2025-07-24 Thread Suraj Kandpal
Define function to destroy the drm_writbeack_connector and drm_connector associated with it. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_writeback.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_writeback.c b/drivers/gpu

[PATCH 15/28] drm/i915/writeback: Define compute_config for writeback

2025-07-24 Thread Suraj Kandpal
Define the compute config function where we assign the output_type and add the transcoder that needs to be used. We currently assign one WD0 transcoder. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_writeback.c| 20 +++ 1 file changed, 20 insertions

[PATCH 16/28] drm/i915/writeback: Define function for connector function detect

2025-07-24 Thread Suraj Kandpal
detect function always returns connector_status_connected if writeback connector has been initialized. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_writeback.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_writeback.c b

[PATCH 14/28] drm/i915/writeback: Define function for prepare and cleanup hooks

2025-07-24 Thread Suraj Kandpal
Define function for prepare and cleanup hooks which help map and unmap drm framebuffer since we need these address to do register writes in WD_SURF and WD_STRIDE register. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_writeback.c| 68 +++ 1 file changed, 68

[PATCH 13/28] drm/i915/writeback: Add private structure for writeback job

2025-07-24 Thread Suraj Kandpal
Create intel_writeback_job to track drm_writback_job and other structure we might need to complete the writeback job. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_writeback.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/gpu/drm/i915/display

[PATCH 11/28] drm/i915/writeback: Define encoder->get_hw_state

2025-07-24 Thread Suraj Kandpal
Define the get_hw_state function for encoder which get's the encoder state, pipe config. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_writeback.c| 48 +++ .../drm/i915/display/intel_writeback_reg.h| 3 ++ 2 files changed, 51 insertions(+) diff

[PATCH 12/28] drm/i915/writeback: Fill encoder->get_config

2025-07-24 Thread Suraj Kandpal
Fill the encoder->get_config hook with relevant data which helps verify state. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_writeback.c | 9 + 1 file changed, 9 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_writeback.c b/drivers/gpu/drm/i

[PATCH 10/28] drm/i915/writeback: Add hook to check modes

2025-07-24 Thread Suraj Kandpal
Add connector helper hooks to check if mode is valid or not. We add this restriction to make sure mode is 3840x2160 60Hz. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_writeback.c| 20 +++ 1 file changed, 20 insertions(+) diff --git a/drivers/gpu/drm/i915

[PATCH 09/28] drm/i915/writeback: Add function to get modes

2025-07-24 Thread Suraj Kandpal
Add a function that get modes for writeback connector. Since we have a restriction on supporting only 3840x2160 60Hz modes at max we will create modes only up until that point. Bspec: 49275 Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_writeback.c | 7 +++ 1 file

[PATCH 08/28] drm/i915/writeback: Define the get_connector_from_writeback hook

2025-07-24 Thread Suraj Kandpal
Define the get_connector_from_writeback hook to get the drm_connector from drm_writeback_connector. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_writeback.c | 17 + 1 file changed, 17 insertions(+) diff --git a/drivers/gpu/drm/i915/display

[PATCH 07/28] drm/i915/writeback: Add function for get_writeback_connector

2025-07-24 Thread Suraj Kandpal
Define function to get_writeback_connector which returns the drm_writeback_connector given the drm_connector. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_writeback.c | 18 ++ 1 file changed, 18 insertions(+) diff --git a/drivers/gpu/drm/i915/display

[PATCH 06/28] drm/i915/writeback: Init writeback connector

2025-07-24 Thread Suraj Kandpal
which drm formats are supported by us. Bspec: 49275 Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/Makefile | 1 + .../gpu/drm/i915/display/intel_writeback.c| 129 ++ .../gpu/drm/i915/display/intel_writeback.h| 17 +++ 3 files changed, 147 insertions

[PATCH 05/28] drm/i915/writeback: Add some preliminary writeback definitions

2025-07-24 Thread Suraj Kandpal
Add some preliminary definitions like, output type and transcoder related to the writeback functionality. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_acpi.c | 1 + .../drm/i915/display/intel_crtc_state_dump.c | 2 +- drivers/gpu/drm/i915/display/intel_display.c

[PATCH 04/28] drm/i915/writeback: Add writeback registers

2025-07-24 Thread Suraj Kandpal
Add writeback registers to its own file. Signed-off-by: Suraj Kandpal --- .../drm/i915/display/intel_writeback_reg.h| 136 ++ 1 file changed, 136 insertions(+) create mode 100644 drivers/gpu/drm/i915/display/intel_writeback_reg.h diff --git a/drivers/gpu/drm/i915/display

[PATCH 03/28] drm/writeback: Define function to get drm_connector from writeback

2025-07-24 Thread Suraj Kandpal
ector if the helper hook is not present. Lets use this function and call it whenever drm_connector is required mostly when connector helper private funcs need to be fetched. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/drm_writeback.c | 33 ++--- 1 file change

[PATCH 02/28] drm/writeback: Add a helper function to get writeback connector

2025-07-24 Thread Suraj Kandpal
drm_writeback_connector associated with the give drm_connector. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/drm_writeback.c | 14 ++ include/drm/drm_modeset_helper_vtables.h | 59 include/drm/drm_writeback.h | 14 -- 3 files changed, 82 insertions

[PATCH 01/28] drm/writeback: Add function that takes preallocated connector

2025-07-24 Thread Suraj Kandpal
Write a function that takes a preallocated drm_connector instead of using the one allocated inside the drm writeback connector init function. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/drm_writeback.c | 76 + include/drm/drm_writeback.h | 7 +++ 2

[PATCH 00/28] Enable Pipe writeback

2025-07-24 Thread Suraj Kandpal
trigger a capture. Cc: Harry Wetland Signed-off-by: Suraj Kandpal Suraj Kandpal (28): drm/writeback: Add function that takes preallocated connector drm/writeback: Add a helper function to get writeback connector drm/writeback: Define function to get drm_connector from writeback

[PATCH] drm/i915/vblank: Change log from err to debug

2025-07-24 Thread Suraj Kandpal
Let Potential update error just be a long instead of an big error we already have Atomic Update error log which shouts out if something really goes wrong. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_vblank.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions

[PATCH 1/2] drm/i915/vbt: Add eDP Data Overrride field in VBT

2025-07-21 Thread Suraj Kandpal
Add a field which add the edp_data_override field VBT which gives us a mask of rates which need to be skipped in favour of subsequent higher rate. Bspec: 20124 Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_bios.c | 4 +++- drivers/gpu/drm/i915/display/intel_vbt_defs.h

[PATCH 2/2] drm/i915/edp: eDP Data Overrride

2025-07-21 Thread Suraj Kandpal
We need override certain link rates in favour of the next available higher link rate. The Link rates that need to be overridden are indicated by a mask in VBT. To make sure these modes are skipped we don't add them in them in the sink rates array. Signed-off-by: Suraj Kandpal --- driver

[PATCH 0/2] eDP Data Override

2025-07-21 Thread Suraj Kandpal
-by: Suraj Kandpal Suraj Kandpal (2): drm/i915/vbt: Add eDP Data Overrride field in VBT drm/i915/edp: eDP Data Overrride drivers/gpu/drm/i915/display/intel_bios.c | 60 ++- drivers/gpu/drm/i915/display/intel_bios.h | 2 + drivers/gpu/drm/i915/display/intel_dp.c

[PATCH 1/2] drm/i915/vbt: Add eDP Data Overrride field in VBT

2025-07-16 Thread Suraj Kandpal
Add a field which add the edp_data_override field VBT which gives us a mask of rates which need to be skipped in favour of subsequent higher rate. Bspec: 20124 Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_vbt_defs.h | 16 1 file changed, 16 insertions

[PATCH 2/2] drm/i915/edp: eDP Data Overrride

2025-07-16 Thread Suraj Kandpal
We need override certain link rates in favour of the next available higher link rate. The Link rates that need to be overridden are indicated by a mask in VBT. To make sure these modes are skipped we don't add them in them in the sink rates array. Signed-off-by: Suraj Kandpal --- driver

[PATCH 0/2] eDP Data Override

2025-07-16 Thread Suraj Kandpal
-by: Suraj Kandpal Suraj Kandpal (2): drm/i915/vbt: Add eDP Data Overrride field in VBT drm/i915/edp: eDP Data Overrride drivers/gpu/drm/i915/display/intel_bios.c | 56 +++ drivers/gpu/drm/i915/display/intel_bios.h | 2 + drivers/gpu/drm/i915/display/intel_dp.c

[PATCH 1/2] drm/i915/scaler: Use intel_display as argument to skl_scaler_max_src_size

2025-07-07 Thread Suraj Kandpal
skl_scaler_max_src_size has really no use of intel_crtc other than deriving intel_display. Let's just pass intel_display to it directly. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/skl_scaler.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/dr

[PATCH 2/2] drm/i915/xe3lpd: Prune modes for YUV420

2025-07-07 Thread Suraj Kandpal
247, 50441 Signed-off-by: Suraj Kandpal Reviewed-by: Jonathan Cavitt #v2 --- drivers/gpu/drm/i915/display/intel_dp.c | 11 --- drivers/gpu/drm/i915/display/intel_hdmi.c | 4 drivers/gpu/drm/i915/display/intel_pfit.c | 11 +++ drivers/gpu/drm/i915/display/intel_pfit.h |

[PATCH] drm/dp: Add documentation for luminance_set

2025-07-01 Thread Suraj Kandpal
Documentation for luminance_set for struct drm_edp_backlight_info was missed which causes warnings. Fixes: 2af612ad4290 ("drm/dp: Introduce new member in drm_backlight_info") Signed-off-by: Suraj Kandpal --- include/drm/display/drm_dp_helper.h | 1 + 1 file changed, 1 insertion(+) di

[PATCH] drm/i915/xe3lpd: Prune modes for YUV420

2025-06-20 Thread Suraj Kandpal
mit messge to point to why this is needed --v3 -Use a function skl_scaler_mode_valid which is routed throug intel_pfit_mode_valid [Ville] -Combine the check conditons [Jonathan] --v4 -mode_valid functions should return drm_mode_status [Jani] Bspec: 49247, 50441 Signed-off-by: Suraj Kandpal Reviewed

[PATCH v3 09/13] drm/dp: Change argument type of drm_edp_backlight_enable

2025-06-19 Thread Suraj Kandpal
Change the argument type to u32 for the default level being sent since it has to now account for luminance value which has to be set for DP_EDP_PANEL_LUMINANCE_TARGET_VALUE. --v2 -No need to typecast [Jani] Signed-off-by: Suraj Kandpal Reviewed-by: Arun R Murthy --- drivers/gpu/drm/display

[PATCH 00/13] Modify drm helpers to use luminance

2025-06-19 Thread Suraj Kandpal
This series modifies drm dp edp helpers so that drivers can now use them to manipulate brightness using luminance value via the PANEL_TARGET_LUMINANCE_VALUE register. This feature was introduced frin eDP 1.5. Signed-off-by: Suraj Kandpal Suraj Kandpal (13): drm/dp: Introduce new member in

[PATCH v3 13/13] drm/i915/backlight: Use drm_edp_backlight_enable

2025-06-19 Thread Suraj Kandpal
Use drm dp helper to enable backlight now that it has been modified to set PANEL_LUMINANCE_CONTROL_ENABLE bit based on if capability supports it and the driver wants it. Remove the dead code. Signed-off-by: Suraj Kandpal Reviewed-by: Arun R Murthy --- .../gpu/drm/i915/display

[PATCH v3 12/13] drm/i915/backlight: Use drm helper to set edp backlight

2025-06-19 Thread Suraj Kandpal
Now that the drm helper sets the backlight using luminance too we can use that. Remove the obselete function. Signed-off-by: Suraj Kandpal Reviewed-by: Arun R Murthy --- .../drm/i915/display/intel_dp_aux_backlight.c | 34 ++- 1 file changed, 3 insertions(+), 31 deletions

[PATCH v3 11/13] drm/i915/backlight: Use drm helper to initialize edp backlight

2025-06-19 Thread Suraj Kandpal
Now that drm_edp_backlight init has been modified to take into account the setup of lumininace based brightness manipulation we can just use that. --v2 -Fix commit message [Arun] Signed-off-by: Suraj Kandpal --- .../drm/i915/display/intel_dp_aux_backlight.c | 98 +-- 1 file

[PATCH v3 06/13] drm/dp: Modify drm_edp_probe_state

2025-06-19 Thread Suraj Kandpal
Modify drm_edp_probe_state to read current level from DP_EDP_PANEL_TARGET_LUMINANCE_VALUE. We divide it by 1000 since the value in this register is in millinits. --v2 -Add comment on the unit sent back [Arun] Signed-off-by: Suraj Kandpal Reviewed-by: Arun R Murthy --- drivers/gpu/drm/display

[PATCH v3 10/13] drm/dp: Enable backlight control using luminance

2025-06-19 Thread Suraj Kandpal
Add flag to enable brightness control via luminance value when enabling edp backlight. Signed-off-by: Suraj Kandpal Reviewed-by: Arun R Murthy --- drivers/gpu/drm/display/drm_dp_helper.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/display/drm_dp_helper.c b/drivers

[PATCH v3 08/13] drm/dp: Modify drm_edp_backlight_set_level

2025-06-19 Thread Suraj Kandpal
Modify drm_edp_backlight_set_level to be able to set the value for register in DP_EDP_PANEL_TARGET_LUMINANCE_VALUE. We multiply the level with 1000 since we get the value in Nits and the register accepts it in milliNits. --v2 -Add comment regarding the unit [Arun] Signed-off-by: Suraj Kandpal

[PATCH v3 07/13] drm/dp: Change argument type for drm_edp_backlight_set_level

2025-06-19 Thread Suraj Kandpal
Use u32 for level variable as one may need to pass value for DP_EDP_PANEL_TARGET_LUMINANCE_VALUE. --v2 -Typecase is not needed [Jani] Signed-off-by: Suraj Kandpal Reviewed-by: Arun R Murthy --- drivers/gpu/drm/display/drm_dp_helper.c | 2 +- include/drm/display/drm_dp_helper.h | 2 +- 2

[PATCH v3 05/13] drm/dp: Change current_level argument type to u32

2025-06-19 Thread Suraj Kandpal
Change the current_level argument type to u32 from u16 since it can now carry the value which it gets from DP_EDP_PANEL_TARGET_LUMINANCE_VALUE. Signed-off-by: Suraj Kandpal Reviewed-by: Arun R Murthy --- drivers/gpu/drm/display/drm_dp_helper.c | 4 ++-- drivers/gpu/drm/i915

[PATCH v3 04/13] drm/dp: Move from u16 to u32 for max in drm_edp_backlight_info

2025-06-19 Thread Suraj Kandpal
Use u32 instead of u16 for max variable in drm_edp_backlight_info since it can now hold max luminance range value which is u32. We will set this max with max_luminance value when luminance_set is true. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/display/drm_dp_helper.c | 10

[PATCH v3 03/13] drm/dp: Add argument for max luminance in drm_edp_backlight_init

2025-06-19 Thread Suraj Kandpal
Add new argument to drm_edp_backlight_init which gives the max_luminance which will be needed to set the max values for backlight. --v2 -Use pass only max luminance instead of luminance_range_info struct [Arun] Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/display/drm_dp_helper.c

[PATCH v3 02/13] drm/dp: Add argument in drm_edp_backlight_init

2025-06-19 Thread Suraj Kandpal
Add bool argument in drm_edp_backlight init to provide the drivers option to choose if they want to use luminance values to manipulate brightness. Signed-off-by: Suraj Kandpal Reviewed-by: Arun R Murthy --- drivers/gpu/drm/display/drm_dp_helper.c | 7 --- drivers/gpu/drm/i915

[PATCH v3 01/13] drm/dp: Introduce new member in drm_backlight_info

2025-06-19 Thread Suraj Kandpal
Introduce luminance_set flag which indicates if we can manipulate backlight using luminance value or not which is only possible after eDP v1.5. Signed-off-by: Suraj Kandpal Reviewed-by: Arun R Murthy --- drivers/gpu/drm/display/drm_dp_helper.c | 8 ++-- include/drm/display/drm_dp_helper.h

[PATCH 2/2] drm/i915/hdcp: Use HDCP2_STREAM_STATUS instead of HDCP2_AUTH_STREAM

2025-06-19 Thread Suraj Kandpal
>From PTL we need to move to using HDCP2_STREAM_STATUS as a WARN_ON to see if written content type info is not the same since HDCP2_AUTH_STREAM is inaccessible to us now. --v2 -Fix commit message [Jani] Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_dp_hdcp.c |

[PATCH 1/2] drm/i915/hdcp: Do not use inline intel_de_read

2025-06-19 Thread Suraj Kandpal
Do not use intel_de_read() inline in the WARN_ON functions. While we are at it make the comparision for stream_type u8 to u8. --v2 -Use REG_GENMASK() [Jani] -USe REG_FIELD_GET() [Jani] -Fix the WARN_ON() condition [Jani] Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display

[PATCH 0/2] Changes in hdcp2_stream_encryption

2025-06-19 Thread Suraj Kandpal
Contains changes in hdcp2_stream_encryption where we remove the intel_de_read from the WARN_ON function also we move to using HDCP2_STREAM_STATUS for our WARN_ON for platforms PTL and above. Signed-off-by: Suraj Kandpal Suraj Kandpal (2): drm/i915/hdcp: Do not use inline intel_de_read drm

[PATCH 0/2] Changes in hdcp2_stream_encryption

2025-06-19 Thread Suraj Kandpal
Contains changes in hdcp2_stream_encryption where we remove the intel_de_read from the WARN_ON function also we move to using HDCP2_STREAM_STATUS for our WARN_ON for platforms PTL and above. Signed-off-by: Suraj Kandpal Suraj Kandpal (2): drm/i915/hdcp: Do not use inline intel_de_read drm

[PATCH 1/2] drm/i915/hdcp: Do not use inline intel_de_read

2025-06-19 Thread Suraj Kandpal
Do not use intel_de_read() inline in the WARN_ON functions. While we are at it make the comparision for stream_type u8 to u8. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_dp_hdcp.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm

[PATCH 2/2] drm/i915/hdcp: Use HDCP2_STREAM_STATUS instead of HDCP2_AUTH_STREAM

2025-06-19 Thread Suraj Kandpal
>From PTL we need to move to using HDCP2_STREAM_STATUS as a WARN_ON to see if written content type info is not the same since HDCP2_AUTH_STREAM is inaccessible to us now. --v2 -Fix commit message [Jani] Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_dp_hdcp.c |

[PATCH] drm/i915/hdcp: Use HDCP2_STREAM_STATUS to verify content type status

2025-06-18 Thread Suraj Kandpal
>From PTL we need to move to using HDCP2_STREAM_STATUS to check if the written content type info is the same as we expect since HDCP2_AUTH_STREAM is inaccessible to us now. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_dp_hdcp.c | 13 ++--- 1 file changed,

[PATCH] drm/i915/xe3lpd: Prune modes for YUV420

2025-06-16 Thread Suraj Kandpal
mit messge to point to why this is needed --v3 -Use a function skl_scaler_mode_valid which is routed throug intel_pfit_mode_valid [Ville] -Combine the check conditons [Jonathan] Bspec: 49247, 50441 Signed-off-by: Suraj Kandpal Reviewed-by: Jonathan Cavitt #v2 --- drivers/gpu/drm/i915/disp

[RFC PATCH 0/4] New Helper to Initialise writeback connector

2025-06-12 Thread Suraj Kandpal
This series is for review comments only and is not tested. This series added a helper to be able to initialise writeback connector in a way where drivers can send their own connector and encoder. Signed-off-by: Suraj Kandpal Suraj Kandpal (4): drm/writeback: Add function that takes

[RFC PATCH 4/4] drm/i915/writeback: Init writeback connector

2025-06-12 Thread Suraj Kandpal
which drm formats are supported by us. Bspec: 49275 Signed-off-by: Suraj Kandpal diff --git a/drivers/gpu/drm/i915/Makefile b/drivers/gpu/drm/i915/Makefile index 13d4a16f7d33..0748edae8aa9 100644 --- a/drivers/gpu/drm/i915/Makefile +++ b/drivers/gpu/drm/i915/Makefile @@ -294,6 +294,7 @@ i915-y

[RFC PATCH 3/4] drm/i915/writeback: Add some preliminary writeback definitions

2025-06-12 Thread Suraj Kandpal
Add some preliminary definitions like, output type and transcoder related to the writeback functionality. Signed-off-by: Suraj Kandpal diff --git a/drivers/gpu/drm/i915/display/intel_display.h b/drivers/gpu/drm/i915/display/intel_display.h index 3b54a62c290a..ae474cbeb791 100644 --- a/drivers

[RFC PATCH 2/4] drm/i915/writeback: Add writeback registers

2025-06-12 Thread Suraj Kandpal
Add writeback registers to its own file. Signed-off-by: Suraj Kandpal diff --git a/drivers/gpu/drm/i915/display/intel_writeback_reg.h b/drivers/gpu/drm/i915/display/intel_writeback_reg.h new file mode 100644 index ..dd872b6f8103 --- /dev/null +++ b/drivers/gpu/drm/i915/display

[RFC PATCH 1/4] drm/writeback: Add function that takes preallocated connector

2025-06-12 Thread Suraj Kandpal
Write a function that takes a preallocated drm_connector instead of using the one allocated inside the drm writeback connector init function. Signed-off-by: Suraj Kandpal diff --git a/drivers/gpu/drm/drm_writeback.c b/drivers/gpu/drm/drm_writeback.c index edbeab88ff2b..0d287ab9bded 100644 --- a

[PATCH] drm/i915/xe3lpd: Prune modes for YUV420

2025-06-09 Thread Suraj Kandpal
mit messge to point to why this is needed Bspec: 49247, 50441 Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_dp.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_d

[PATCH 07/14] drm/i915/dpll: Move away from using shared dpll

2025-05-15 Thread Suraj Kandpal
Rename functions to move away from using shared dpll in the dpll framework as much as possible since dpll may not always be shared. --v2 -Use intel_dpll_global instead of global_dpll [Jani] --v3 -Just use intel_dpll [Jani] --v4 -Drop the global from comments [Jani] Signed-off-by: Suraj Kandpal

[PATCH 11/14] drm/i915/dpll: Rename intel_reference_dpll_crtc

2025-05-15 Thread Suraj Kandpal
Rename intel_reference_dpll_crtc to intel_dpll_crtc_get in an effort to have all the exported functions have the name start with file name. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_dpll_mgr.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff

[PATCH 02/14] drm/i915/dpll: Rename intel_dpll_funcs

2025-05-15 Thread Suraj Kandpal
Rename intel_dpll_funcs to intel_dpll_global_funcs so that later on intel_shared_dpll_funcs can be renamed to intel_dpll_funcs. This is done to move away from the shared naming convention since starting MTL dpll's are not shared among PHYs. Signed-off-by: Suraj Kandpal Reviewed-by: Jani N

[PATCH 10/14] drm/i915/dpll: Rename intel_unreference_dpll_crtc

2025-05-15 Thread Suraj Kandpal
Rename intel_unreference_dpll_crtc to intel_dpll_crtc_put in an effort to keep names of exported functions start with the filename. --v2 -Make the new name more sensible [Jani] Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_dpll_mgr.c | 10 +- drivers/gpu/drm

[PATCH 13/14] drm/i915/dpll: Rename intel_compute_dpll

2025-05-15 Thread Suraj Kandpal
Rename intel_compute_dpll to intel_dpll_compute in an effort to make sure all function names that are exported have the filename at start. Signed-off-by: Suraj Kandpal Reviewed-by: Jani Nikula --- drivers/gpu/drm/i915/display/intel_dpll.c | 6 +++--- drivers/gpu/drm/i915/display

[PATCH 12/14] drm/i915/dpll: Rename intel__dpll

2025-05-15 Thread Suraj Kandpal
Rename intel__dpll to intel_dpll_ in an effort to keep names of exported functions start with the filename. Signed-off-by: Suraj Kandpal Reviewed-by: Jani Nikula --- drivers/gpu/drm/i915/display/intel_display.c | 2 +- drivers/gpu/drm/i915/display/intel_dpll.c | 4 +-- drivers/gpu/drm

[PATCH 14/14] drm/i915/dpll: Rename intel_update_active_dpll

2025-05-15 Thread Suraj Kandpal
Rename intel_update_active_dpll to intel_dpll_update_active in an effort to have function names which are exported to start with filenames they are exported from. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/i915/display/intel_ddi.c | 2 +- drivers/gpu/drm/i915/display/intel_dpll_mgr.c

[PATCH 04/14] drm/i915/dpll: Rename macro for_each_shared_dpll

2025-05-15 Thread Suraj Kandpal
Rename the macro for_each_shared_dpll to for_each_dpll since this loop will not necessarily be used for only shared dpll in future. Signed-off-by: Suraj Kandpal Reviewed-by: Jani Nikula --- .../gpu/drm/i915/display/intel_display_debugfs.c | 2 +- drivers/gpu/drm/i915/display/intel_dpll_mgr.c

[PATCH 09/14] drm/i915/dpll: Rename intel_[enable/disable]_dpll

2025-05-15 Thread Suraj Kandpal
Rename intel_[enable/disable]_dpll to intel_dpll_[enable/disable] in an effort to make sure all functions that are exported start with the filename. Signed-off-by: Suraj Kandpal Reviewed-by: Jani Nikula --- drivers/gpu/drm/i915/display/intel_display.c | 4 ++-- drivers/gpu/drm/i915

[PATCH 01/14] drm/i915/dpll: Rename intel_dpll

2025-05-15 Thread Suraj Kandpal
ff-by: Suraj Kandpal Reviewed-by: Jani Nikula --- drivers/gpu/drm/i915/display/intel_display_core.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_display_core.h b/drivers/gpu/drm/i915/display/intel_display_core.h index b4937e1

[PATCH 08/14] drm/i915/dpll: Rename crtc_get_shared_dpll

2025-05-15 Thread Suraj Kandpal
-v4 -Modify commit message [Jani] Signed-off-by: Suraj Kandpal Reviewed-by: Jani Nikula --- drivers/gpu/drm/i915/display/intel_display.c | 2 +- drivers/gpu/drm/i915/display/intel_dpll.c| 24 ++-- drivers/gpu/drm/i915/display/intel_dpll.h| 4 ++-- 3 files changed,

[PATCH 06/14] drm/i915/dpll: Rename intel_shared_dpll

2025-05-15 Thread Suraj Kandpal
make sure names start with the filename [Jani/Ville] -Explain the need of this rename [Jani] --v3 -Just keep it intel_dpll [Jani] --v4 -Fix comment [Jani] -Use just num_dpll and dplls [Jani] Signed-off-by: Suraj Kandpal Reviewed-by: Jani Nikula --- drivers/gpu/drm/i915/display/icl_

[PATCH 05/14] drm/i915/dpll: Rename intel_shared_dpll_funcs

2025-05-15 Thread Suraj Kandpal
altogether [Jani] --v4 -Keep declarations sorted [Jani] Signed-off-by: Suraj Kandpal Reviewed-by: Jani Nikula --- drivers/gpu/drm/i915/display/intel_dpll_mgr.c | 24 +-- drivers/gpu/drm/i915/display/intel_dpll_mgr.h | 4 ++-- 2 files changed, 14 insertions(+), 14 deletions(-) diff

[PATCH 03/14] drm/i915/dpll: Rename intel_shared_dpll_state

2025-05-15 Thread Suraj Kandpal
Rename intel_shared_dpll_state to just intel_dpll_state since it may not necessarily store share dpll state info specially since DISPLAY_VER >= 14 PLL's are not shared. Also change the name of variables which may have been associated as a shared_dpll. Signed-off-by: Suraj Kandpal Rev

[PATCH 00/14] DPLL framework redesign

2025-05-15 Thread Suraj Kandpal
base --v5 -Break series and send the controvertial patch next patch series of this redesign Signed-off-by: Suraj Kandpal Suraj Kandpal (14): drm/i915/dpll: Rename intel_dpll drm/i915/dpll: Rename intel_dpll_funcs drm/i915/dpll: Rename intel_shared_dpll_state drm/i915/dpll: Re

[PATCH 06/13] drm/dp: Modify drm_edp_probe_state

2025-05-09 Thread Suraj Kandpal
Modify drm_edp_probe_state to read current level from DP_EDP_PANEL_TARGET_LUMINANCE_VALUE. We divide it by 1000 since the value in this register is in millinits. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/display/drm_dp_helper.c | 35 ++--- 1 file changed, 25

[PATCH 04/18] drm/i915/dpll: Rename macro for_each_shared_dpll

2025-05-08 Thread Suraj Kandpal
Rename the macro for_each_shared_dpll to for_each_dpll since this loop will not necessarily be used for only shared dpll in future. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_display_debugfs.c | 2 +- drivers/gpu/drm/i915/display/intel_dpll_mgr.c| 16

[PATCH 12/13] drm/i915/backlight: Use drm helper to set edp backlight

2025-05-08 Thread Suraj Kandpal
Now that the drm helper sets the backlight using luminance too we can use that. Remove the obselete function. Signed-off-by: Suraj Kandpal --- .../drm/i915/display/intel_dp_aux_backlight.c | 34 ++- 1 file changed, 3 insertions(+), 31 deletions(-) diff --git a/drivers/gpu/drm

[PATCH 13/13] drm/i915/backlight: Use drm_edp_backlight_enable

2025-05-08 Thread Suraj Kandpal
Use drm dp helper to enable backlight now that it has been modified to set PANEL_LUMINANCE_CONTROL_ENABLE bit based on if capability supports it and the driver wants it. Remove the dead code. Signed-off-by: Suraj Kandpal --- .../gpu/drm/i915/display/intel_dp_aux_backlight.c | 14

[PATCH 08/13] drm/dp: Modify drm_edp_backlight_set_level

2025-05-08 Thread Suraj Kandpal
Modify drm_edp_backlight_set_level to be able to set the value for register in DP_EDP_PANEL_TARGET_LUMINANCE_VALUE. We multiply the level with 1000 since we get the value in Nits and the register accepts it in milliNits. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/display/drm_dp_helper.c

[PATCH 11/13] drm/i915/backlight: Use drm helper to initialize edp backlight

2025-05-08 Thread Suraj Kandpal
Now that drm_edp_backlight init has been to be able to setup brightness manipulation via luminance we can just use that. Signed-off-by: Suraj Kandpal --- .../drm/i915/display/intel_dp_aux_backlight.c | 100 +- 1 file changed, 49 insertions(+), 51 deletions(-) diff --git a

[PATCH 10/13] drm/dp: Enable backlight control using luminance

2025-05-08 Thread Suraj Kandpal
Add flag to enable brightness control via luminance value when enabling edp backlight. Signed-off-by: Suraj Kandpal --- drivers/gpu/drm/display/drm_dp_helper.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/display/drm_dp_helper.c b/drivers/gpu/drm/display

  1   2   3   4   5   6   7   8   9   10   >