Lets now pass drm_connector to prepare_writeback_job since
drm_writeback_connector now resides within drm_connector.
It also make it uniform with params passed to other
drm_connector_helper_funcs.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_wb.c | 2
this connector without breaking them.
The drivers modified here are amd, komeda, mali, vc4, vkms,
rcar_du, msm
Signed-off-by: Suraj Kandpal
---
.../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 4 +-
.../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 2 +-
.../drm/amd/display/amdgpu_dm/amdgpu_dm_wb.c
Move to using drm_connector structure instead of drm_writeback_connector
since this now writeback resides within drm_connector.
This helps make sure drivers change drm_writeback_connector
using helpers provided by drm core.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/amd/display/amdgpu_dm
Move to using drm_connector instead of drm_writeback_connector since
it now resides within drm_connector. This will also help with
make sure drivers do not need to access drm_writeback_connector
as much.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2
Lets now pass drm_connector to prepare_writeback_job since
drm_writeback_connector now resides within drm_connector.
It also make it uniform with params passed to other
drm_connector_helper_funcs.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_wb.c | 4
Use drm_connector instead of drm_writeback_connector since it now
resides within drm_connector and also helps make sure
drm_wrtieback_connector is being modified mostly by drm core
provided helpers.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/drm_atomic_uapi.c | 4 +---
drivers/gpu/drm
Now with drm_writeback_connector moved to drm_connector it makes
more sense use drm_connector as an argument rather than drm_connector.
The writeback connector can easily be derived from drm_connector.
Signed-off-by: Suraj Kandpal
---
.../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_wb.c | 2
[1] https://patchwork.freedesktop.org/series/152758/
[2] https://patchwork.freedesktop.org/series/152106/
[3] https://patchwork.freedesktop.org/series/152420/
Signed-off-by: Suraj Kandpal
Suraj Kandpal (7):
drm: writeback: Refactor drm_writeback_connector structure
drm: writeback: Modify writ
above
changes mentioned.
Signed-off-by: Suraj Kandpal
---
.../gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c | 3 ++-
drivers/gpu/drm/msm/disp/dpu1/dpu_writeback.c| 16 +---
drivers/gpu/drm/msm/disp/dpu1/dpu_writeback.h| 4 ++--
3 files changed, 13 insertions(+), 10 deletions
changes mentioned.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/vkms/vkms_composer.c | 2 +-
drivers/gpu/drm/vkms/vkms_drv.h | 2 +-
drivers/gpu/drm/vkms/vkms_writeback.c | 15 +--
3 files changed, 11 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/vkms
above
changes mentioned.
Signed-off-by: Suraj Kandpal
---
.../gpu/drm/renesas/rcar-du/rcar_du_crtc.h| 4 ++--
.../drm/renesas/rcar-du/rcar_du_writeback.c | 22 +++
2 files changed, 15 insertions(+), 11 deletions(-)
diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_du_crtc.h
changes mentioned.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/vc4/vc4_txp.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/vc4/vc4_txp.c b/drivers/gpu/drm/vc4/vc4_txp.c
index fef4e4ee47cf..2428807e9714 100644
--- a/drivers/gpu/drm/vc4/vc4_txp.c
changes mentioned.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/arm/malidp_drv.h | 2 +-
drivers/gpu/drm/arm/malidp_mw.c | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/arm/malidp_drv.h b/drivers/gpu/drm/arm/malidp_drv.h
index bc0387876dea
the above
changes mentioned.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/arm/display/komeda/komeda_crtc.c | 6 +++---
drivers/gpu/drm/arm/display/komeda/komeda_kms.h | 6 +++---
drivers/gpu/drm/arm/display/komeda/komeda_wb_connector.c | 8
3 files changed, 10
the above changes mentioned.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c| 4 +---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h| 2 +-
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_wb.c | 8
3 files changed, 6 insertions(+), 8
[1] https://patchwork.freedesktop.org/series/152106/
[2] https://patchwork.freedesktop.org/series/152420/
Signed-off-by: Suraj Kandpal
Suraj Kandpal (8):
drm: writeback: Refactor drm_writeback_connector structure
drm/amd/display: Adapt amd writeback to new drm_writeback_connector
drm/arm/komeda: Adapt komeda writeb
.
All drivers will be expected to allocate the drm_connector.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/drm_writeback.c | 33 ++--
include/drm/drm_connector.h | 60 +
include/drm/drm_writeback.h | 68 -
3 files ch
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 2 +-
include/drm/display/drm_dp_helper.h | 2 +-
2 files changed, 2 insertions
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
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 2
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
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
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
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
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 4 ++--
drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
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
Add new argument to drm_edp_backlight_init which gives the
drm_luminance_range_info struct which will be needed to set the min
and max values for backlight.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/display/drm_dp_helper.c | 5 -
drivers/gpu/drm/i915/display
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 7 ---
drivers/gpu/drm/i915/display
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 8 ++--
include/drm/display/drm_dp_helper.h | 1 +
2 files changed
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 8 ++--
include/drm/display/drm_dp_helper.h | 1 +
2 files changed
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
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
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 7 ---
drivers/gpu/drm/i915/display
Add new argument to drm_edp_backlight_init which gives the
drm_luminance_range_info struct which will be needed to set the min
and max values for backlight.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/display/drm_dp_helper.c | 5 -
drivers/gpu/drm/i915/display
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
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 4 ++--
drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
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
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
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 2
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
---
drivers/gpu/drm/display/drm_dp_helper.c | 2 +-
include/drm/display/drm_dp_helper.h | 2 +-
2 files changed, 2 insertions
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
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
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
ntrol for VESA")
Signed-off-by: Suraj Kandpal
Reviewed-by: Arun R Murthy
---
drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c
b/drivers/gpu/drm/i9
Add DP_EDP_SMOOTH_BRIGHTNESS register bit definition for
EDP_GENERAL_CAPABILITY 2 register.
--v2
-Add eDP 2.0 comment [Ankit]
Signed-off-by: Suraj Kandpal
Reviewed-by: Arun R Murthy
---
include/drm/display/drm_dp.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/drm/display
Add smooth brightness register bit definition for register
EDP_GENERAL_CAPABILITY 2
Signed-off-by: Suraj Kandpal
Suraj Kandpal (2):
drm/dp: Add smooth brightness register bit definition
drm/i915/backlight: Modify condition to use panel luminance
drivers/gpu/drm/i915/display
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.
Signed-off-by: Suraj Kandpal
---
drivers/gpu/drm/display/drm_dp_helper.c | 6 +++---
drivers/gpu/drm/nouveau/dispnv50
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
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
1 - 100 of 179 matches
Mail list logo