From: Kieran Bingham <kieran.bingham@ideasonboard.com> To: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>, linux-media@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: Re: [PATCH v4 4/7] media: vsp1: Fix addresses of display-related registers for VSP-DL Date: Sun, 17 Feb 2019 20:27:20 +0000 [thread overview] Message-ID: <c6d6e56f-0d68-9a76-18cf-2f35764505d5@ideasonboard.com> (raw) In-Reply-To: <20190217024852.23328-5-laurent.pinchart+renesas@ideasonboard.com> Hi Laurent, On 17/02/2019 02:48, Laurent Pinchart wrote: > The VSP-DL instances have two LIFs, and thus two copies of the > VI6_DISP_IRQ_ENB, VI6_DISP_IRQ_STA and VI6_WPF_WRBCK_CTRL registers. Fix > the corresponding macros accordingly. > Seep. This could have ended badly if someone used both LIF's :) (which I'm sure happens) > Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com> > --- > drivers/media/platform/vsp1/vsp1_drm.c | 4 ++-- > drivers/media/platform/vsp1/vsp1_regs.h | 6 +++--- > drivers/media/platform/vsp1/vsp1_wpf.c | 2 +- > 3 files changed, 6 insertions(+), 6 deletions(-) > > diff --git a/drivers/media/platform/vsp1/vsp1_drm.c b/drivers/media/platform/vsp1/vsp1_drm.c > index 8d86f618ec77..048190fd3a2d 100644 > --- a/drivers/media/platform/vsp1/vsp1_drm.c > +++ b/drivers/media/platform/vsp1/vsp1_drm.c > @@ -700,8 +700,8 @@ int vsp1_du_setup_lif(struct device *dev, unsigned int pipe_index, > drm_pipe->du_private = cfg->callback_data; > > /* Disable the display interrupts. */ > - vsp1_write(vsp1, VI6_DISP_IRQ_STA, 0); > - vsp1_write(vsp1, VI6_DISP_IRQ_ENB, 0); > + vsp1_write(vsp1, VI6_DISP_IRQ_STA(pipe_index), 0); > + vsp1_write(vsp1, VI6_DISP_IRQ_ENB(pipe_index), 0); > > /* Configure all entities in the pipeline. */ > vsp1_du_pipeline_configure(pipe); > diff --git a/drivers/media/platform/vsp1/vsp1_regs.h b/drivers/media/platform/vsp1/vsp1_regs.h > index f6e4157095cc..1bb1d39c60d9 100644 > --- a/drivers/media/platform/vsp1/vsp1_regs.h > +++ b/drivers/media/platform/vsp1/vsp1_regs.h > @@ -39,12 +39,12 @@ > #define VI6_WFP_IRQ_STA_DFE (1 << 1) > #define VI6_WFP_IRQ_STA_FRE (1 << 0) > > -#define VI6_DISP_IRQ_ENB 0x0078 > +#define VI6_DISP_IRQ_ENB(n) (0x0078 + (n) * 60) > #define VI6_DISP_IRQ_ENB_DSTE (1 << 8) > #define VI6_DISP_IRQ_ENB_MAEE (1 << 5) > #define VI6_DISP_IRQ_ENB_LNEE(n) (1 << (n)) > > -#define VI6_DISP_IRQ_STA 0x007c > +#define VI6_DISP_IRQ_STA(n) (0x007c + (n) * 60) > #define VI6_DISP_IRQ_STA_DST (1 << 8) > #define VI6_DISP_IRQ_STA_MAE (1 << 5) > #define VI6_DISP_IRQ_STA_LNE(n) (1 << (n)) > @@ -307,7 +307,7 @@ > #define VI6_WPF_DSTM_ADDR_C0 0x1028 > #define VI6_WPF_DSTM_ADDR_C1 0x102c > > -#define VI6_WPF_WRBCK_CTRL 0x1034 > +#define VI6_WPF_WRBCK_CTRL(n) (0x1034 + (n) * 0x100) > #define VI6_WPF_WRBCK_CTRL_WBMD (1 << 0) > > /* ----------------------------------------------------------------------------- > diff --git a/drivers/media/platform/vsp1/vsp1_wpf.c b/drivers/media/platform/vsp1/vsp1_wpf.c > index a07c5944b598..18c49e3a7875 100644 > --- a/drivers/media/platform/vsp1/vsp1_wpf.c > +++ b/drivers/media/platform/vsp1/vsp1_wpf.c > @@ -291,7 +291,7 @@ static void wpf_configure_stream(struct vsp1_entity *entity, > vsp1_dl_body_write(dlb, VI6_DPR_WPF_FPORCH(wpf->entity.index), > VI6_DPR_WPF_FPORCH_FP_WPFN); > > - vsp1_dl_body_write(dlb, VI6_WPF_WRBCK_CTRL, 0); > + vsp1_dl_body_write(dlb, VI6_WPF_WRBCK_CTRL(wpf->entity.index), 0); > > /* > * Sources. If the pipeline has a single input and BRx is not used, > -- Regards -- Kieran
WARNING: multiple messages have this Message-ID (diff)
From: Kieran Bingham <kieran.bingham@ideasonboard.com> To: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>, linux-media@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: Re: [PATCH v4 4/7] media: vsp1: Fix addresses of display-related registers for VSP-DL Date: Sun, 17 Feb 2019 20:27:20 +0000 [thread overview] Message-ID: <c6d6e56f-0d68-9a76-18cf-2f35764505d5@ideasonboard.com> (raw) In-Reply-To: <20190217024852.23328-5-laurent.pinchart+renesas@ideasonboard.com> Hi Laurent, On 17/02/2019 02:48, Laurent Pinchart wrote: > The VSP-DL instances have two LIFs, and thus two copies of the > VI6_DISP_IRQ_ENB, VI6_DISP_IRQ_STA and VI6_WPF_WRBCK_CTRL registers. Fix > the corresponding macros accordingly. > Seep. This could have ended badly if someone used both LIF's :) (which I'm sure happens) > Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com> > --- > drivers/media/platform/vsp1/vsp1_drm.c | 4 ++-- > drivers/media/platform/vsp1/vsp1_regs.h | 6 +++--- > drivers/media/platform/vsp1/vsp1_wpf.c | 2 +- > 3 files changed, 6 insertions(+), 6 deletions(-) > > diff --git a/drivers/media/platform/vsp1/vsp1_drm.c b/drivers/media/platform/vsp1/vsp1_drm.c > index 8d86f618ec77..048190fd3a2d 100644 > --- a/drivers/media/platform/vsp1/vsp1_drm.c > +++ b/drivers/media/platform/vsp1/vsp1_drm.c > @@ -700,8 +700,8 @@ int vsp1_du_setup_lif(struct device *dev, unsigned int pipe_index, > drm_pipe->du_private = cfg->callback_data; > > /* Disable the display interrupts. */ > - vsp1_write(vsp1, VI6_DISP_IRQ_STA, 0); > - vsp1_write(vsp1, VI6_DISP_IRQ_ENB, 0); > + vsp1_write(vsp1, VI6_DISP_IRQ_STA(pipe_index), 0); > + vsp1_write(vsp1, VI6_DISP_IRQ_ENB(pipe_index), 0); > > /* Configure all entities in the pipeline. */ > vsp1_du_pipeline_configure(pipe); > diff --git a/drivers/media/platform/vsp1/vsp1_regs.h b/drivers/media/platform/vsp1/vsp1_regs.h > index f6e4157095cc..1bb1d39c60d9 100644 > --- a/drivers/media/platform/vsp1/vsp1_regs.h > +++ b/drivers/media/platform/vsp1/vsp1_regs.h > @@ -39,12 +39,12 @@ > #define VI6_WFP_IRQ_STA_DFE (1 << 1) > #define VI6_WFP_IRQ_STA_FRE (1 << 0) > > -#define VI6_DISP_IRQ_ENB 0x0078 > +#define VI6_DISP_IRQ_ENB(n) (0x0078 + (n) * 60) > #define VI6_DISP_IRQ_ENB_DSTE (1 << 8) > #define VI6_DISP_IRQ_ENB_MAEE (1 << 5) > #define VI6_DISP_IRQ_ENB_LNEE(n) (1 << (n)) > > -#define VI6_DISP_IRQ_STA 0x007c > +#define VI6_DISP_IRQ_STA(n) (0x007c + (n) * 60) > #define VI6_DISP_IRQ_STA_DST (1 << 8) > #define VI6_DISP_IRQ_STA_MAE (1 << 5) > #define VI6_DISP_IRQ_STA_LNE(n) (1 << (n)) > @@ -307,7 +307,7 @@ > #define VI6_WPF_DSTM_ADDR_C0 0x1028 > #define VI6_WPF_DSTM_ADDR_C1 0x102c > > -#define VI6_WPF_WRBCK_CTRL 0x1034 > +#define VI6_WPF_WRBCK_CTRL(n) (0x1034 + (n) * 0x100) > #define VI6_WPF_WRBCK_CTRL_WBMD (1 << 0) > > /* ----------------------------------------------------------------------------- > diff --git a/drivers/media/platform/vsp1/vsp1_wpf.c b/drivers/media/platform/vsp1/vsp1_wpf.c > index a07c5944b598..18c49e3a7875 100644 > --- a/drivers/media/platform/vsp1/vsp1_wpf.c > +++ b/drivers/media/platform/vsp1/vsp1_wpf.c > @@ -291,7 +291,7 @@ static void wpf_configure_stream(struct vsp1_entity *entity, > vsp1_dl_body_write(dlb, VI6_DPR_WPF_FPORCH(wpf->entity.index), > VI6_DPR_WPF_FPORCH_FP_WPFN); > > - vsp1_dl_body_write(dlb, VI6_WPF_WRBCK_CTRL, 0); > + vsp1_dl_body_write(dlb, VI6_WPF_WRBCK_CTRL(wpf->entity.index), 0); > > /* > * Sources. If the pipeline has a single input and BRx is not used, > -- Regards -- Kieran _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2019-02-17 20:27 UTC|newest] Thread overview: 56+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-02-17 2:48 [PATCH v4 0/7] VSP1: Display writeback support Laurent Pinchart 2019-02-17 2:48 ` Laurent Pinchart 2019-02-17 2:48 ` [PATCH v4 1/7] Revert "[media] v4l: vsp1: Supply frames to the DU continuously" Laurent Pinchart 2019-02-17 2:48 ` Laurent Pinchart 2019-02-17 2:48 ` [PATCH v4 2/7] media: vsp1: wpf: Fix partition configuration for display pipelines Laurent Pinchart 2019-02-17 2:48 ` Laurent Pinchart 2019-02-17 20:16 ` Kieran Bingham 2019-02-17 20:16 ` Kieran Bingham 2019-02-18 23:24 ` Laurent Pinchart 2019-02-18 23:24 ` Laurent Pinchart 2019-02-17 2:48 ` [PATCH v4 3/7] media: vsp1: Replace leftover occurrence of fragment with body Laurent Pinchart 2019-02-17 2:48 ` Laurent Pinchart 2019-02-17 20:20 ` Kieran Bingham 2019-02-17 20:20 ` Kieran Bingham 2019-02-17 2:48 ` [PATCH v4 4/7] media: vsp1: Fix addresses of display-related registers for VSP-DL Laurent Pinchart 2019-02-17 2:48 ` Laurent Pinchart 2019-02-17 20:27 ` Kieran Bingham [this message] 2019-02-17 20:27 ` Kieran Bingham 2019-02-17 2:48 ` [PATCH v4 5/7] media: vsp1: Refactor vsp1_video_complete_buffer() for later reuse Laurent Pinchart 2019-02-17 2:48 ` Laurent Pinchart 2019-02-17 20:35 ` Kieran Bingham 2019-02-17 20:35 ` Kieran Bingham 2019-02-18 23:43 ` Laurent Pinchart 2019-02-18 23:43 ` Laurent Pinchart 2019-02-17 2:48 ` [PATCH v4 6/7] media: vsp1: Replace the display list internal flag with a flags field Laurent Pinchart 2019-02-17 2:48 ` Laurent Pinchart 2019-02-17 20:38 ` Kieran Bingham 2019-02-17 20:38 ` Kieran Bingham 2019-02-17 2:48 ` [PATCH v4 7/7] media: vsp1: Provide a writeback video device Laurent Pinchart 2019-02-17 2:48 ` Laurent Pinchart 2019-02-17 20:06 ` Kieran Bingham 2019-02-17 20:06 ` Kieran Bingham 2019-02-17 20:09 ` Kieran Bingham 2019-02-17 20:09 ` Kieran Bingham 2019-02-19 0:31 ` Laurent Pinchart 2019-02-19 0:31 ` Laurent Pinchart 2019-02-18 12:22 ` [PATCH v4 0/7] VSP1: Display writeback support Brian Starkey 2019-02-18 12:22 ` Brian Starkey 2019-02-18 23:04 ` Laurent Pinchart 2019-02-18 23:04 ` Laurent Pinchart 2019-02-21 8:23 ` Laurent Pinchart 2019-02-21 8:23 ` Laurent Pinchart 2019-02-21 9:50 ` Brian Starkey 2019-02-21 9:50 ` Brian Starkey 2019-02-21 10:02 ` Laurent Pinchart 2019-02-21 10:02 ` Laurent Pinchart 2019-02-21 12:19 ` Brian Starkey 2019-02-21 12:19 ` Brian Starkey 2019-02-21 12:23 ` Laurent Pinchart 2019-02-21 12:23 ` Laurent Pinchart 2019-02-21 13:44 ` Brian Starkey 2019-02-21 13:44 ` Brian Starkey 2019-02-21 23:12 ` Laurent Pinchart 2019-02-21 23:12 ` Laurent Pinchart 2019-02-21 14:15 ` Daniel Vetter 2019-02-21 14:15 ` Daniel Vetter
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=c6d6e56f-0d68-9a76-18cf-2f35764505d5@ideasonboard.com \ --to=kieran.bingham@ideasonboard.com \ --cc=dri-devel@lists.freedesktop.org \ --cc=laurent.pinchart+renesas@ideasonboard.com \ --cc=linux-media@vger.kernel.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.