Re: [PATCH v2 4/7] drm/msm/dpu: dont use encoder->crtc in atomic path

2019-03-06 Thread Jeykumar Sankaran
On 2019-03-04 10:09, Sean Paul wrote: On Wed, Feb 13, 2019 at 05:19:13PM -0800, Jeykumar Sankaran wrote: encoder->crtc is not really meaningful for atomic path. Use crtc->encoder_mask to identify the crtc attached with an encoder. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/ms

Re: [Freedreno] [PATCH v2 1/4] drm/msm/dpu: add atomic private object to dpu crtc

2019-03-05 Thread Jeykumar Sankaran
On 2019-03-04 13:32, Sean Paul wrote: On Wed, Feb 13, 2019 at 05:52:19PM -0800, Jeykumar Sankaran wrote: Subclass drm private object state for DPU for handling driver specific data. Adds atomic private object to dpu crtc to track hw resources per display. Provide helper function to retrieve DPU

[PATCH v2 4/4] drm/msm/dpu: remove mode_set_complete

2019-02-13 Thread Jeykumar Sankaran
This flag was introduced as a fix to notify modeset complete when hw reservations were happening in both atomic_check and atomic_commit paths. Now that we are reserving only in atomic_check, we can get rid of this flag. changes in v2: - none Signed-off-by: Jeykumar Sankaran Reviewed

[PATCH v2 2/4] drm/msm/dpu: track HW resources using private object state

2019-02-13 Thread Jeykumar Sankaran
- No explicit count for hw_ctl as they match with hw_intf count Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.h| 7 +- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 157 drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c

[PATCH v2 3/4] drm/msm/dpu: remove reserve in encoder mode_set

2019-02-13 Thread Jeykumar Sankaran
Now that we have dpu private state tracking the reserved HW resources, we have access to them after atomic swap. So avoid reserving the resources in mode_set. changes in v2: - removal applied on private object based reservation Signed-off-by: Jeykumar Sankaran Reviewed-by: Sean Paul

[PATCH v2 0/4] reserve RM resources in private obj state

2019-02-13 Thread Jeykumar Sankaran
up RM iterator API's. Thanks and Regards, Jeykumar S. Jeykumar Sankaran (4): drm/msm/dpu: add atomic private object to dpu crtc drm/msm/dpu: track HW resources using private object state drm/msm/dpu: remove reserve in encoder mode_set drm/msm/dpu: remove mode_set_complete drivers/gpu/drm

[PATCH v2 1/4] drm/msm/dpu: add atomic private object to dpu crtc

2019-02-13 Thread Jeykumar Sankaran
are maintained in dpu_crtc as the resources are tracked per display Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.h | 3 ++ drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 64 +++- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h | 15 3

Re: [PATCH v2 0/7] move dpu resource parsing to encoder modeset

2019-02-13 Thread Jeykumar Sankaran
On 2019-02-13 17:19, Jeykumar Sankaran wrote: Fixing some of the low hanging fruits by moving the hw resource parsing and assignment to encoder modeset. This series prepares DPU resource management to switch to state based resource tracking which is implemented in the next incoming changes

[PATCH v2 6/7] drm/msm/dpu: assign intf to encoder in mode_set

2019-02-13 Thread Jeykumar Sankaran
Iterate and assign HW intf block to physical encoders in encoder modeset. Moving all the HW block assignments to encoder modeset to allow easy switching to state based resource management. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c| 22

[PATCH v2 5/7] drm/msm/dpu: map mixer/ctl hw blocks in encoder modeset

2019-02-13 Thread Jeykumar Sankaran
After resource allocation, iterate and populate mixer/ctl hw blocks in encoder modeset thereby centralizing all the resource mapping to the CRTC. This change is made for easy switching to state based allocation using private objects later in this series. Signed-off-by: Jeykumar Sankaran

[PATCH v2 2/7] drm/msm/dpu: remove phys_vid subclass

2019-02-13 Thread Jeykumar Sankaran
Not holding any video encoder specific data. Get rid of it. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys.h | 11 --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c | 18 -- 2 files changed, 4 insertions(+), 25 deletions

[PATCH v2 0/7] move dpu resource parsing to encoder modeset

2019-02-13 Thread Jeykumar Sankaran
Fixing some of the low hanging fruits by moving the hw resource parsing and assignment to encoder modeset. This series prepares DPU resource management to switch to state based resource tracking which is implemented in the next incoming changes. Thanks. Jeykumar Sankaran (7): drm/msm/dpu

[PATCH v2 4/7] drm/msm/dpu: dont use encoder->crtc in atomic path

2019-02-13 Thread Jeykumar Sankaran
encoder->crtc is not really meaningful for atomic path. Use crtc->encoder_mask to identify the crtc attached with an encoder. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drive

[PATCH v2 1/7] drm/msm/dpu: move hw_inf encoder baseclass

2019-02-13 Thread Jeykumar Sankaran
Both video and command physical encoders will have a hw interface assigned to it. So there is really no need to track the hw block in specific encoder subclass. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys.h | 4 +- .../gpu/drm/msm/disp/dpu1

[PATCH v2 7/7] drm/msm/dpu: check split role for single flush

2019-02-13 Thread Jeykumar Sankaran
Removing unwanted access of crtc_state for finding this information. Use split role information to know whether we have slave ctl. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c | 14 +- 1 file changed, 1 insertion(+), 13 deletions(-) diff

[PATCH v2 3/7] drm/msm/dpu: release resources on modeset failure

2019-02-13 Thread Jeykumar Sankaran
release resources allocated in mode_set if any of the hw check fails. Most of these checks are not necessary and they will be removed in the follow up patches with state based resource allocations. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 7 +-- 1

[PATCH 1/2] drm/msm/dpu: move hw_inf encoder baseclass

2019-02-06 Thread Jeykumar Sankaran
Both video and command physical encoders will have a hw interface assigned to it. So there is really no need to track the hw block in specific encoder subclass. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys.h | 4 +- .../gpu/drm/msm/disp/dpu1

[PATCH 2/2] drm/msm/dpu: remove phys_vid subclass

2019-02-06 Thread Jeykumar Sankaran
Not holding any video encoder specific data. Get rid of it. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys.h | 11 --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c | 18 -- 2 files changed, 4 insertions(+), 25 deletions

Re: [PATCH 4/4] drm/msm: dpu: Don't queue the frame_done watchdog for cursor

2019-02-06 Thread Jeykumar Sankaran
the cursor moves without a synchronous frame following it up before the timeout expires. Since we don't wait for frame_done, and don't handle it, we shouldn't modify the watchdog. Signed-off-by: Sean Paul --- Reviewed-by: Jeykumar Sankaran drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 19

Re: [PATCH 3/4] drm/msm: dpu: Untangle frame_done timeout units

2019-02-06 Thread Jeykumar Sankaran
also dropped the timeout from the previous 60 frames to 5. That seems like more than enough time to give up on a frame, and my guess is that no one intended for the timeout to _actually_ be 60 frames. Signed-off-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp

Re: [PATCH 2/4] drm/msm: dpu: Simplify frame_done watchdog timeout calculation

2019-02-06 Thread Jeykumar Sankaran
_dpu_encoder_kickoff_phys(dpu_enc, async); Reviewed-by: Jeykumar Sankaran -- Jeykumar S ___ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH 1/4] drm/msm: Use drm_mode_vrefresh instead of mode->vrefresh

2019-02-06 Thread Jeykumar Sankaran
On 2019-01-28 12:42, Sean Paul wrote: From: Sean Paul Use the drm_mode_vrefresh helper where we need refresh rate in case vrefresh is empty. Signed-off-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 6 +++--- drivers/gpu/drm/msm

[PATCH v4 1/3] drm/msm/dpu: fix documentation for intf_type

2018-12-17 Thread Jeykumar Sankaran
Fix intf_type description in msm_disp_info to show that it represents drm encoder mode of the display. changes in v3: - introduced in the series changes in v4: - none Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.h | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH v4 3/3] drm/msm/dpu: add display port support in DPU

2018-12-17 Thread Jeykumar Sankaran
/87 Signed-off-by: Jeykumar Sankaran Reviewed-by: Jordan Crouse Reviewed-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 8 ++-- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 58 + 2 files changed, 54 insertions(+), 12 deletions(-) diff --git

[PATCH v4 2/3] drm/msm/dpu: handle failures while initializing displays

2018-12-17 Thread Jeykumar Sankaran
Bail out KMS hw init on display initialization failures with proper error logging. changes in v3: - introduced in the series changes in v4: - avoid duplicate return on errors (Sean Paul) - avoid spamming errors on failures (Jordon Crouse) Signed-off-by: Jeykumar Sankaran

Re: [Freedreno] [PATCH v3 2/3] drm/msm/dpu: handle failures while initializing displays

2018-12-17 Thread Jeykumar Sankaran
On 2018-12-14 07:22, Sean Paul wrote: On Thu, Dec 13, 2018 at 10:51:03AM -0800, Jeykumar Sankaran wrote: Bail out KMS hw init on display initialization failures with proper error logging. changes in v3: - introduced in the series Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm

Re: [Freedreno] [PATCH v3 2/3] drm/msm/dpu: handle failures while initializing displays

2018-12-17 Thread Jeykumar Sankaran
On 2018-12-14 07:22, Sean Paul wrote: On Thu, Dec 13, 2018 at 10:51:03AM -0800, Jeykumar Sankaran wrote: Bail out KMS hw init on display initialization failures with proper error logging. changes in v3: - introduced in the series Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm

Re: [DPU PATCH v2] drm/msm/dpu: Change RGB565 and BGR565 format map.

2018-12-17 Thread Jeykumar Sankaran
On 2018-12-14 11:46, Tanmay Shah wrote: Red and Blue colors will be interchanged on display with current format maps for RGB565 and BGR565. Change both format maps to display correct colors. You can drop "DPU PATCH" prefix in the patches. Can you also provide history on what has changed since

[PATCH v5 4/5] drm/msm: clean up display thread

2018-12-14 Thread Jeykumar Sankaran
tip with [1] (Sean Paul) [1] https://patchwork.freedesktop.org/patch/255105/ Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c | 43 ++- drivers/gpu/drm/msm/msm_drv.h | 1 - 2 files changed, 2 insertions(+), 42 deletions(-) diff --git

[PATCH v5 5/5] drm/msm: subclass work object for vblank events

2018-12-14 Thread Jeykumar Sankaran
optimization on system wq (Sean Paul) changes in v3: - none changes in v4: - move flush_workqueue before irq uninstall changes in v5: - none Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c | 71 ++- drivers/gpu/drm/msm

[PATCH v5 3/5] drm/msm/dpu: use msm wq for idle power collapse

2018-12-14 Thread Jeykumar Sankaran
: - use msm wq for delayed works changes in v5: - none Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 25 +++-- 1 file changed, 7 insertions(+), 18 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c b/drivers

[PATCH v5 2/5] drm/msm/dpu: use msm wq for vblank events

2018-12-14 Thread Jeykumar Sankaran
for vblank events changes in v5: - none Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c | 9 - drivers/gpu/drm/msm/msm_drv.h | 2 +- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/msm/msm_drv.c b/drivers/gpu/drm/msm/msm_drv.c index

[PATCH v5 1/5] drm/msm/dpu: use kthread_destroy_worker to release msm workers

2018-12-14 Thread Jeykumar Sankaran
use kthread_destroy_worker to destroy workers and release their associated kthreads. changes in v3: - introduced in the series changes in v4: - none changes in v5: - none Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c | 6 ++ 1 file changed, 2

[PATCH v3 3/3] drm/msm/dpu: add display port support in DPU

2018-12-13 Thread Jeykumar Sankaran
(Jordan Crouse) changes in v3: - add dp support after fixing the current code base for error logging (Sean Paul) [1] https://lwn.net/Articles/768265/ [2] https://lkml.org/lkml/2018/11/17/87 Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 8

[PATCH v3 2/3] drm/msm/dpu: handle failures while initializing displays

2018-12-13 Thread Jeykumar Sankaran
Bail out KMS hw init on display initialization failures with proper error logging. changes in v3: - introduced in the series Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 39 +++-- 1 file changed, 27 insertions(+), 12

[PATCH v3 1/3] drm/msm/dpu: fix documentation for intf_type

2018-12-13 Thread Jeykumar Sankaran
Fix intf_type description in msm_disp_info to show that it represents drm encoder mode of the display. changes in v3: - introduced in the series Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH v2 2/6] drm/msm/dpu: remove dev from RM

2018-12-07 Thread Jeykumar Sankaran
Not used. Remove from RM. changes in v2: - none Signed-off-by: Jeykumar Sankaran Reviewed-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 3 +-- drivers/gpu/drm/msm/disp/dpu1/dpu_rm.c | 7 ++- drivers/gpu/drm/msm/disp/dpu1/dpu_rm.h | 6 +- 3 files changed, 4

[PATCH v2 3/6] drm/msm/dpu: clean up dpu_rm_check_property_topctl declaration

2018-12-07 Thread Jeykumar Sankaran
Definition was removed already. Clean up header declaration. changes in v2: - none Signed-off-by: Jeykumar Sankaran Reviewed-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_rm.h | 8 1 file changed, 8 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_rm.h b

[PATCH v2 6/6] drm/msm/dpu: maintain hw_mdp in kms

2018-12-07 Thread Jeykumar Sankaran
hw_mdp block is common for displays. No need to reserve per display. changes in v2: - use IS_ERR for error checking (Jordan Crouse) Signed-off-by: Jeykumar Sankaran Reviewed-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 11 +++ drivers/gpu/drm/msm/disp/dpu1

[PATCH v2 4/6] drm/msm/dpu: remove encoder from crtc mixer struct

2018-12-07 Thread Jeykumar Sankaran
Not actively used. Clean up the crtc mixer struct. changes in v2: - none Signed-off-by: Jeykumar Sankaran Reviewed-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 2 -- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.h | 2 -- 2 files changed, 4 deletions(-) diff --git a/drivers

[PATCH v2 1/6] drm/msm/dpu: avoid tracking reservations in RM

2018-12-07 Thread Jeykumar Sankaran
the support from RM. Replace rsvp with the corresponding encoder id to tag the HW blocks reserved. It prepares DPU to get rid of RM altogether and track reservations using private states. changes in v2: - none Signed-off-by: Jeykumar Sankaran Reviewed-by: Sean Paul --- drivers/gpu/drm/msm

[PATCH v2 5/6] drm/msm/dpu: clean up redundant hw type

2018-12-07 Thread Jeykumar Sankaran
struct dpu_hw_blk has hw block type info. Remove duplicate type tracking in struct dpu_rm_hw_blk. changes in v2: - remove redundant type in trace api's (Sean Paul) Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_rm.c| 22 +- drivers/gpu

[PATCH v2 0/6] DPU resource manager cleanup

2018-12-07 Thread Jeykumar Sankaran
First set of clean up patches for DPU resource manager. Removes/realigns some of the redudant RM interfaces. Eventual plan is to migrate resource maintenence using private state objects. Thanks and Regards, Jeykumar S Jeykumar Sankaran (6): drm/msm/dpu: avoid tracking reservations in RM drm

Re: [Freedreno] [PATCH v2 5/5] drm/msm: subclass work object for vblank events

2018-12-07 Thread Jeykumar Sankaran
On 2018-12-07 09:22, Sean Paul wrote: On Mon, Dec 03, 2018 at 12:27:42PM -0800, Jeykumar Sankaran wrote: On 2018-12-03 06:21, Sean Paul wrote: > On Fri, Nov 30, 2018 at 04:21:15PM -0800, Jeykumar Sankaran wrote: > > On 2018-11-30 12:07, Sean Paul wrote: > > > On Fri, Nov 30,

[PATCH v4 5/5] drm/msm: subclass work object for vblank events

2018-12-06 Thread Jeykumar Sankaran
optimization on system wq (Sean Paul) changes in v3: - none changes in v4: - move flush_workqueue before irq uninstall Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c | 71 ++- drivers/gpu/drm/msm/msm_drv.h | 7 - 2 files

[PATCH v4 3/5] drm/msm/dpu: use msm wq for idle power collapse

2018-12-06 Thread Jeykumar Sankaran
: - use msm wq for delayed works Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 25 +++-- 1 file changed, 7 insertions(+), 18 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c b/drivers/gpu/drm/msm/disp/dpu1

[PATCH v4 1/5] drm/msm/dpu: use kthread_destroy_worker to release msm workers

2018-12-06 Thread Jeykumar Sankaran
use kthread_destroy_worker to destroy workers and release their associated kthreads. changes in v3: - introduced in the series changes in v4: - none Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions

[PATCH v4 4/5] drm/msm: clean up display thread

2018-12-06 Thread Jeykumar Sankaran
Since there are no clients using these threads, cleaning it up. changes in v2: - switch all the dependent clients to use system wq before removing the disp_threads (Sean Paul) changes in v3: - none changes in v4: - none Signed-off-by: Jeykumar Sankaran

[PATCH v4 2/5] drm/msm/dpu: use msm wq for vblank events

2018-12-06 Thread Jeykumar Sankaran
for vblank events Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c | 9 - drivers/gpu/drm/msm/msm_drv.h | 2 +- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/msm/msm_drv.c b/drivers/gpu/drm/msm/msm_drv.c index 956f0599..37740b8 100644

Re: [Freedreno] [PATCH v2 5/5] drm/msm: subclass work object for vblank events

2018-12-06 Thread Jeykumar Sankaran
On 2018-12-06 10:56, Jeykumar Sankaran wrote: On 2018-11-07 07:55, Sean Paul wrote: On Tue, Nov 06, 2018 at 02:36:30PM -0800, Jeykumar Sankaran wrote: msm maintains a separate structure to define vblank work definitions and a list to track events submitted to the workqueue. We can avoid

Re: [Freedreno] [PATCH v2 5/5] drm/msm: subclass work object for vblank events

2018-12-06 Thread Jeykumar Sankaran
On 2018-11-07 07:55, Sean Paul wrote: On Tue, Nov 06, 2018 at 02:36:30PM -0800, Jeykumar Sankaran wrote: msm maintains a separate structure to define vblank work definitions and a list to track events submitted to the workqueue. We can avoid this redundant list and its protection mechanism

[PATCH v6] arm64: dts: qcom: sdm845: Add dpu to sdm845 dts file

2018-12-04 Thread Jeykumar Sankaran
er (Jordan) Changes in v6: - Separating this patch out of the series - fix phy-names Signed-off-by: Jeykumar Sankaran Signed-off-by: Sean Paul --- arch/arm64/boot/dts/qcom/sdm845.dtsi | 203 +++ 1 file changed, 203 insertions(+) diff --git a/arch/

Re: [Freedreno] [PATCH v2] drm/msm/dpu: add display port support in DPU

2018-12-04 Thread Jeykumar Sankaran
On 2018-12-03 06:47, Sean Paul wrote: On Tue, Nov 27, 2018 at 02:28:30PM -0800, Jeykumar Sankaran wrote: Add display port support in DPU by creating hooks for DP encoder enumeration and encoder mode initialization. This change is based on the SDM845 Display port driver changes[1]. changes

Re: [Freedreno] [PATCH v2] drm/msm/dpu: add display port support in DPU

2018-12-03 Thread Jeykumar Sankaran
On 2018-12-03 06:47, Sean Paul wrote: On Tue, Nov 27, 2018 at 02:28:30PM -0800, Jeykumar Sankaran wrote: Add display port support in DPU by creating hooks for DP encoder enumeration and encoder mode initialization. This change is based on the SDM845 Display port driver changes[1]. changes

Re: [PATCH v5 1/3] arm64: dts: qcom: sdm845: Add dpu to sdm845 dts file

2018-12-03 Thread Jeykumar Sankaran
On 2018-12-03 16:57, Doug Anderson wrote: Hi, On Mon, Dec 3, 2018 at 2:27 PM Jeykumar Sankaran wrote: + dsi0: dsi@ae94000 { + compatible = "qcom,mdss-dsi-ctrl"; + reg = <0x

[PATCH v5 1/3] arm64: dts: qcom: sdm845: Add dpu to sdm845 dts file

2018-12-03 Thread Jeykumar Sankaran
er (Jordan) Signed-off-by: Jeykumar Sankaran Signed-off-by: Sean Paul --- arch/arm64/boot/dts/qcom/sdm845.dtsi | 203 +++ 1 file changed, 203 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi index 1419b0

Re: [Freedreno] [PATCH v2 5/5] drm/msm: subclass work object for vblank events

2018-12-03 Thread Jeykumar Sankaran
On 2018-12-03 06:21, Sean Paul wrote: On Fri, Nov 30, 2018 at 04:21:15PM -0800, Jeykumar Sankaran wrote: On 2018-11-30 12:07, Sean Paul wrote: > On Fri, Nov 30, 2018 at 11:45:55AM -0800, Jeykumar Sankaran wrote: > > On 2018-11-29 14:15, Sean Paul wrote: > > > On Tue, Nov 20,

Re: [PATCH v3 14/24] drm/msm: dpu: Grab the modeset locks in frame_event

2018-12-03 Thread Jeykumar Sankaran
Sankaran Signed-off-by: Sean Paul --- I see Daniel's comments are addressed. So .. Reviewed-by: Jeykumar Sankaran drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 15 ++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c b/drivers/gpu

Re: [PATCH v2 12/24] drm/msm: dpu: Move crtc runtime resume to encoder

2018-12-03 Thread Jeykumar Sankaran
to be called while holding the modeset locks (although it sometimes is), this presents a race condition. Now that we have ->enabled on the virtual encoders, and a lock to protect it, just call resume on each encoder and only restore the ones that are enabled. Changes in v2: - None Cc: Jeykumar Sanka

Re: [PATCH v2 11/24] drm/msm: dpu: Add ->enabled to dpu_encoder_virt

2018-12-03 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul Add a bool to dpu_encoder_virt to track whether the encoder is enabled or not. Repurpose the enc_lock mutex to ensure that it is consistent with the hw state. Changes in v2: - None Cc: Jeykumar Sankaran Signed-off-by: Sean Paul

Re: [PATCH v2 04/24] drm/msm: dpu: Don't use power_event for vbif_init_memtypes

2018-12-03 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul power_events are only used for pm_runtime, and that's all handled in dpu_kms. So just call vbif_init_memtypes at the correct times. Changes in v2: - Removed obsolete comment (Jeykumar) Cc: Jeykumar Sankaran Signed-off-by: Sean Paul

Re: [PATCH v2 15/24] drm/msm: dpu: Stop using encoder->crtc pointer

2018-12-03 Thread Jeykumar Sankaran
On 2018-11-26 13:53, Sean Paul wrote: On Mon, Nov 19, 2018 at 12:03:53PM -0800, Jeykumar Sankaran wrote: On 2018-11-16 13:14, Sean Paul wrote: > On Fri, Nov 16, 2018 at 12:05:09PM -0800, Jeykumar Sankaran wrote: > > On 2018-11-16 10:42, Sean Paul wrote: > > > From: Sean Paul

Re: [Patch v3 ] drm/msm/dpu: Correct dpu destroy and disable order

2018-12-01 Thread Jeykumar Sankaran
pending work if not scheduled. Changes in v2: - Removed double spacings [Jeykumar] Changes in v3: - Fix clock on issue during bootup [Rajendra] Signed-off-by: Jayant Shekhar --- Acked-by: Jeykumar Sankaran drivers/gpu/drm/msm/disp/dpu1/dpu_mdss.c | 6 ++ 1 file changed, 2 insertions

Re: [Freedreno] [PATCH v2 5/5] drm/msm: subclass work object for vblank events

2018-11-30 Thread Jeykumar Sankaran
On 2018-11-30 12:07, Sean Paul wrote: On Fri, Nov 30, 2018 at 11:45:55AM -0800, Jeykumar Sankaran wrote: On 2018-11-29 14:15, Sean Paul wrote: > On Tue, Nov 20, 2018 at 02:04:14PM -0800, Jeykumar Sankaran wrote: > > On 2018-11-07 07:55, Sean Paul wrote: > > > On Tue, Nov 06,

Re: [Freedreno] [PATCH v2 5/5] drm/msm: subclass work object for vblank events

2018-11-30 Thread Jeykumar Sankaran
On 2018-11-29 14:15, Sean Paul wrote: On Tue, Nov 20, 2018 at 02:04:14PM -0800, Jeykumar Sankaran wrote: On 2018-11-07 07:55, Sean Paul wrote: > On Tue, Nov 06, 2018 at 02:36:30PM -0800, Jeykumar Sankaran wrote: > > msm maintains a separate structure to define vblank > > w

[PATCH] drm/msm/dpu: set geometry for iommu domain

2018-11-27 Thread Jeykumar Sankaran
Specify geometry for DPU iommu domain which sets the address space for gem allocations. Signed-off-by: Jeykumar Sankaran Suggested-by: Jordan Crouse Suggested-by: Vivek Gautam --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm

[PATCH v2] drm/msm/dpu: add display port support in DPU

2018-11-27 Thread Jeykumar Sankaran
(Jordan Crouse) [1] https://lwn.net/Articles/768265/ [2] https://lkml.org/lkml/2018/11/17/87 Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 8 ++--- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 47 + 2 files changed, 45 insertions

Re: [Freedreno] [PATCH v2 5/5] drm/msm: subclass work object for vblank events

2018-11-20 Thread Jeykumar Sankaran
On 2018-11-07 07:55, Sean Paul wrote: On Tue, Nov 06, 2018 at 02:36:30PM -0800, Jeykumar Sankaran wrote: msm maintains a separate structure to define vblank work definitions and a list to track events submitted to the workqueue. We can avoid this redundant list and its protection mechanism

Re: [PATCH v2 24/24] drm/msm: dpu: Remove crtc_lock

2018-11-19 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul Each time it's called we're holding the crtc modeset lock, so it's redundant. Changes in v2: - None Signed-off-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 11 --- drivers/gpu

Re: [PATCH v2 23/24] drm/msm: dpu: Remove vblank_requested flag from dpu_crtc

2018-11-19 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul It's just for debugfs output, we don't need it Changes in v2: - None Cc: Jeykumar Sankaran Signed-off-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 6 -- drivers/gpu/drm/msm/disp

Re: [PATCH v2 22/24] drm/msm: dpu: Separate crtc assignment from vblank enable

2018-11-19 Thread Jeykumar Sankaran
the assigned crtc will always be valid). As such, we don't need to use modeset locks or the crtc_lock in the vblank_enable/disable routine to be sure state is consistent. ...I think. Changes in v2: - Changed crtc check in toggle_vblank to != (Jeykumar) Cc: Jeykumar Sankaran Signed-off-by: Sean Paul

Re: [PATCH v2 21/24] drm/msm: dpu: Don't bother checking ->enabled in dpu_crtc_vblank

2018-11-19 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul The drm_crtc_vblank_on/off calls in enable/disable guarantee that we won't call this function when crtc is not enabled. Changes in v2: - None Signed-off-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1

Re: [PATCH v2 20/24] drm/msm: dpu: Use atomic_disable for dpu_crtc_disable

2018-11-19 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul Matches dpu_crtc_enable and we'll need the old state in a future patch Changes in v2: - None Signed-off-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 5 +++-- 1 file changed, 3

Re: [PATCH v2 19/24] drm/msm: dpu: Remove vblank_callback from encoder

2018-11-19 Thread Jeykumar Sankaran
. In a later patch, we'll make use of this further. Changes in v2: - None Cc: Jeykumar Sankaran Signed-off-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c| 8 +++ drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.h| 6 + drivers/gpu/drm/msm/disp

Re: [PATCH v2 18/24] drm/msm: dpu: Remove crtc_lock from setup_mixers

2018-11-19 Thread Jeykumar Sankaran
nd add a modeset lock check. While we're at it, use the encoder mask from crtc state instead of legacy pointer. Changes in v2: - None Signed-off-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 12 +++- 1 file changed, 3 insertions

Re: [PATCH v2 17/24] drm/msm: dpu: Move pm_runtime_(get|put) from vblank_enable

2018-11-19 Thread Jeykumar Sankaran
-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c index cd0a0bea4335..c49aaf412b6e 100644

Re: [PATCH v2 15/24] drm/msm: dpu: Stop using encoder->crtc pointer

2018-11-19 Thread Jeykumar Sankaran
On 2018-11-16 13:14, Sean Paul wrote: On Fri, Nov 16, 2018 at 12:05:09PM -0800, Jeykumar Sankaran wrote: On 2018-11-16 10:42, Sean Paul wrote: > From: Sean Paul > > It's for legacy drivers, for atomic drivers crtc->state->encoder_mask > should be used to map encoder to crtc.

Re: [PATCH v2 13/24] drm/msm: dpu: Don't drop locks in crtc_vblank_enable

2018-11-19 Thread Jeykumar Sankaran
Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c index 9be24907f8c1..80de5289ada3 100644 --- a/drivers/gpu/drm/msm/disp

Re: [PATCH v2 05/24] drm/msm: dpu: Handle crtc pm_runtime_resume() directly

2018-11-19 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul Instead of registering through dpu_power_handle just to get a call on runtime_resume, call the crtc function directly. Changes in v2: - None Signed-off-by: Sean Paul Reviewed-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1

Re: [PATCH 1/2] drm/msm/dpu: add dpu encoder uninit

2018-11-19 Thread Jeykumar Sankaran
On 2018-11-16 13:37, Sean Paul wrote: On Fri, Nov 16, 2018 at 04:35:26PM -0500, Sean Paul wrote: On Fri, Nov 16, 2018 at 11:22:21AM -0800, Jeykumar Sankaran wrote: > Add encoder interface to release dpu encoder > on mode_init failures in kms. > > Signed-off-by: Jeyku

Re: [PATCH 1/2] drm/msm/dpu: add dpu encoder uninit

2018-11-19 Thread Jeykumar Sankaran
On 2018-11-16 13:35, Sean Paul wrote: On Fri, Nov 16, 2018 at 11:22:21AM -0800, Jeykumar Sankaran wrote: Add encoder interface to release dpu encoder on mode_init failures in kms. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 12 ++-- drivers/gpu

Re: [PATCH v2 3/3] drm/msm: dpu: Make legacy cursor updates asynchronous

2018-11-19 Thread Jeykumar Sankaran
On 2018-11-16 12:02, Sean Paul wrote: On Thu, Nov 08, 2018 at 02:00:51PM -0800, Jeykumar Sankaran wrote: On 2018-10-30 09:00, Sean Paul wrote: > From: Sean Paul > > This patch sprinkles a few async/legacy_cursor_update checks > through commit to ensure that cursor updates ar

Re: [PATCH v2 16/24] drm/msm: dpu: Add modeset lock checks where applicable

2018-11-16 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul Add modeset lock checks to functions that could be called outside the core atomic stack. Changes in v2: - None Signed-off-by: Sean Paul --- Reviewed-by: Jeykumar Sankaran drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 2 ++ drivers/gpu

Re: [PATCH v2 15/24] drm/msm: dpu: Stop using encoder->crtc pointer

2018-11-16 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul It's for legacy drivers, for atomic drivers crtc->state->encoder_mask should be used to map encoder to crtc. Changes in v2: - None Signed-off-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 46

Re: [PATCH v2 14/24] drm/msm: dpu: Grab the modeset locks in frame_event

2018-11-16 Thread Jeykumar Sankaran
On 2018-11-16 10:42, Sean Paul wrote: From: Sean Paul This patch wraps dpu_core_perf_crtc_release_bw() with modeset locks since it digs into the state objects. Changes in v2: - None Signed-off-by: Sean Paul --- Reviewed-by: Jeykumar Sankaran drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 2

[PATCH 2/2] drm/msm/dpu: add display port support in DPU

2018-11-16 Thread Jeykumar Sankaran
Add display port support in DPU by creating hooks for DP encoder enumeration and encoder mode initialization. This change is based on the SDM845 Display port driver changes[1]. [1] https://lwn.net/Articles/768265/ Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1

[PATCH 1/2] drm/msm/dpu: add dpu encoder uninit

2018-11-16 Thread Jeykumar Sankaran
Add encoder interface to release dpu encoder on mode_init failures in kms. Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 12 ++-- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.h | 6 ++ 2 files changed, 16 insertions(+), 2 deletions(-) diff --git

[PATCH v3 2/5] drm/msm/dpu: use system wq for vblank events

2018-11-15 Thread Jeykumar Sankaran
performance hits, use system workqueue to queue requests. A separate patch is submitted later in this series to remove the display threads altogether. changes in v2: - switch to system wq before removing disp threads (Sean Paul) changes in v3: - none Signed-off-by: Jeykumar Sankaran

[PATCH v3 4/5] drm/msm: clean up display thread

2018-11-15 Thread Jeykumar Sankaran
Since there are no clients using these threads, cleaning it up. changes in v2: - switch all the dependent clients to use system wq before removing the disp_threads (Sean Paul) changes in v3: - none Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c

[PATCH v3 1/5] drm/msm/dpu: use kthread_destroy_worker to release msm workers

2018-11-15 Thread Jeykumar Sankaran
use kthread_destroy_worker to destroy workers and release their associated kthreads. changes in v3: - introduced in the series Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm

[PATCH v3 3/5] drm/msm/dpu: use system wq for idle power collapse

2018-11-15 Thread Jeykumar Sankaran
-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 22 ++ 1 file changed, 6 insertions(+), 16 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c index 82c55ef..dd7ab85 100644 --- a/drivers

[PATCH v3 5/5] drm/msm: subclass work object for vblank events

2018-11-15 Thread Jeykumar Sankaran
optimization on system wq (Sean Paul) changes in v3: - none Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.c | 65 +-- drivers/gpu/drm/msm/msm_drv.h | 7 - 2 files changed, 19 insertions(+), 53 deletions(-) diff --git a/drivers

Re: [PATCH 6/8] drm/msm: dpu: Separate crtc assignment from vblank enable

2018-11-14 Thread Jeykumar Sankaran
On 2018-11-14 12:52, Sean Paul wrote: On Wed, Nov 14, 2018 at 12:46:32PM -0800, Jeykumar Sankaran wrote: On 2018-11-14 11:57, Ville Syrjälä wrote: > On Wed, Nov 14, 2018 at 11:43:51AM -0800, Jeykumar Sankaran wrote: > > On 2018-11-14 07:16, Sean Paul wrote: > > > On Tue, Nov

Re: [PATCH 6/8] drm/msm: dpu: Separate crtc assignment from vblank enable

2018-11-14 Thread Jeykumar Sankaran
On 2018-11-14 11:57, Ville Syrjälä wrote: On Wed, Nov 14, 2018 at 11:43:51AM -0800, Jeykumar Sankaran wrote: On 2018-11-14 07:16, Sean Paul wrote: > On Tue, Nov 13, 2018 at 04:48:12PM -0800, Jeykumar Sankaran wrote: >> On 2018-11-13 12:52, Sean Paul wrote: >> &g

Re: [PATCH 6/8] drm/msm: dpu: Separate crtc assignment from vblank enable

2018-11-14 Thread Jeykumar Sankaran
On 2018-11-14 07:16, Sean Paul wrote: On Tue, Nov 13, 2018 at 04:48:12PM -0800, Jeykumar Sankaran wrote: On 2018-11-13 12:52, Sean Paul wrote: > From: Sean Paul > > Instead of assigning/clearing the crtc on vblank enable/disable, we can > just assign and clear the crt

Re: [PATCH 3/8] drm/msm: dpu: Remove vblank_callback from encoder

2018-11-14 Thread Jeykumar Sankaran
On 2018-11-14 07:13, Sean Paul wrote: On Tue, Nov 13, 2018 at 04:47:22PM -0800, Jeykumar Sankaran wrote: On 2018-11-13 12:52, Sean Paul wrote: > From: Sean Paul > > The indirection of registering a callback and opaque pointer isn't real > useful when there's only one callsite

Re: [PATCH 6/8] drm/msm: dpu: Separate crtc assignment from vblank enable

2018-11-13 Thread Jeykumar Sankaran
On 2018-11-13 12:52, Sean Paul wrote: From: Sean Paul Instead of assigning/clearing the crtc on vblank enable/disable, we can just assign and clear the crtc on modeset. That allows us to just toggle the encoder's vblank interrupts on vblank_enable. So why is this important? Previously the

Re: [PATCH 7/8] drm/msm: dpu: Remove vblank_requested flag from dpu_crtc

2018-11-13 Thread Jeykumar Sankaran
On 2018-11-13 12:52, Sean Paul wrote: From: Sean Paul It's just for debug output, we don't need it Signed-off-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 6 -- drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.h | 2 -- drivers/gpu/drm/msm/disp/dpu1/dpu_trace.h | 14

Re: [PATCH 3/8] drm/msm: dpu: Remove vblank_callback from encoder

2018-11-13 Thread Jeykumar Sankaran
On 2018-11-13 12:52, Sean Paul wrote: From: Sean Paul The indirection of registering a callback and opaque pointer isn't real useful when there's only one callsite. So instead of having the vblank_cb registration, just give encoder a crtc and let it directly call the vblank handler. In a

Re: [PATCH 12/12] drm/msm: dpu: Move crtc runtime resume to encoder

2018-11-12 Thread Jeykumar Sankaran
On 2018-11-12 11:42, Sean Paul wrote: From: Sean Paul The crtc runtime resume doesn't actually operate on the crtc, but rather its encoders. The problem with this is that we need to inspect the crtc state to get the currently connected encoders. Since runtime resume isn't guaranteed to be

  1   2   3   4   >