From: "Gjorgji Rosikopulos (Consultant)" <gjorgji.rosikopulos@oss.qualcomm.com>
To: Loic Poulain <loic.poulain@oss.qualcomm.com>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Bryan O'Donoghue <bryan.odonoghue@linaro.org>,
Vladimir Zapolskiy <vladimir.zapolskiy@linaro.org>
Cc: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-msm@vger.kernel.org
Subject: Re: [PATCH v4 13/14] media: qcom: camss: vfe-680: Report the address of the current frame
Date: Fri, 4 Dec 2026 16:49:41 +0200 [thread overview]
Message-ID: <ad365131-0660-4c54-9523-482f314ee4f9@oss.qualcomm.com> (raw)
In-Reply-To: <20261203-camss-hw-ts-v4-13-c271022b4b0d@oss.qualcomm.com>
On 12/3/2026 6:53 PM, Loic Poulain wrote:
> VFE680 write masters report the start address of the frame they are
> writing in their address status block. Implement the operation reading
> it.
>
> The block was described as a single register, with the wrong offset for
> the lite variant, whose write client has one more register before it.
> Nothing used it, replace it with an indexed form.
>
> Signed-off-by: Loic Poulain <loic.poulain@oss.qualcomm.com>
> ---
> drivers/media/platform/qcom/camss/camss-vfe-680.c | 15 ++++++++++++++-
> 1 file changed, 14 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/media/platform/qcom/camss/camss-vfe-680.c b/drivers/media/platform/qcom/camss/camss-vfe-680.c
> index 99036e7c1e763a07c077e4ce024f3da2575a95e2..984621c1ac5e9083fc1a0581faafbd5772f5e5d0 100644
> --- a/drivers/media/platform/qcom/camss/camss-vfe-680.c
> +++ b/drivers/media/platform/qcom/camss/camss-vfe-680.c
> @@ -54,7 +54,10 @@
> #define VFE_BUS_MMU_PREFETCH_CFG(vfe, c) ((vfe_is_lite(vfe) ? 0x460 : 0xe60) + (c) * 0x100)
> #define VFE_BUS_MMU_PREFETCH_CFG_EN BIT(0)
> #define VFE_BUS_MMU_PREFETCH_MAX_OFFSET(vfe, c) ((vfe_is_lite(vfe) ? 0x464 : 0xe64) + (c) * 0x100)
> -#define VFE_BUS_ADDR_STATUS0(vfe, c) ((vfe_is_lite(vfe) ? 0x470 : 0xe70) + (c) * 0x100)
> +/* The lite write client block has one more register before this one */
> +#define VFE_BUS_ADDR_STATUS(vfe, c, k) ((vfe_is_lite(vfe) ? 0x474 : 0xe70) + \
> + (k) * 4 + (c) * 0x100)
> +#define ADDR_STATUS_CURR_FRAME 3
>
> /*
> * TODO: differentiate the port id based on requested type of RDI, BHIST etc
> @@ -152,6 +155,15 @@ static void vfe_wm_update(struct vfe_device *vfe, u8 rdi, u32 addr,
> writel(addr, vfe->base + VFE_BUS_IMAGE_ADDR(vfe, wm));
> }
>
> +/* The address the write master reports for the frame it is filling */
> +static u32 vfe_wm_curr_addr(struct vfe_device *vfe, u8 rdi)
> +{
> + u8 wm = RDI_WM(rdi);
> +
> + return readl_relaxed(vfe->base +
> + VFE_BUS_ADDR_STATUS(vfe, wm, ADDR_STATUS_CURR_FRAME));
> +}
> +
> static void vfe_wm_start(struct vfe_device *vfe, u8 rdi, struct vfe_line *line)
> {
> struct v4l2_pix_format_mplane *pix =
> @@ -238,6 +250,7 @@ const struct vfe_hw_ops vfe_ops_680 = {
> .vfe_wm_start = vfe_wm_start,
> .vfe_wm_stop = vfe_wm_stop,
> .vfe_buf_done = vfe_buf_done,
> + .vfe_wm_curr_addr = vfe_wm_curr_addr,
> .vfe_wm_update = vfe_wm_update,
> .reg_update = vfe_reg_update,
> .reg_update_clear = vfe_reg_update_clear,
Looks good to me.
Reviewed-by: Gjorgji Rosikopulos <gjorgji.rosikopulos@oss.qualcomm.com>
>
next prev parent reply other threads:[~2026-12-04 14:49 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-03 16:53 [PATCH v4 00/14] media: qcom: camss: Report the hardware SOF timestamp Loic Poulain
2026-12-03 16:53 ` [PATCH v4 01/14] media: qcom: camss: Add csid pad to port helper Loic Poulain
2026-12-03 16:53 ` [PATCH v4 02/14] media: qcom: camss: csid: Add an operation to read the SOF timestamp Loic Poulain
2026-12-04 7:31 ` Gjorgji Rosikopulos (Consultant)
2026-12-03 16:53 ` [PATCH v4 03/14] media: qcom: camss: csid-340: Report the hardware " Loic Poulain
2026-12-03 16:53 ` [PATCH v4 04/14] media: camss: Define timestamp registers for csid-gen2 Loic Poulain
2026-12-03 16:53 ` [PATCH v4 05/14] media: camss: csid-gen2: Report the hardware SOF timestamp Loic Poulain
2026-12-03 16:53 ` [PATCH v4 06/14] media: qcom: camss: csid-gen3: Fix the RDI timestamp controls on Titan 690 Loic Poulain
2026-12-04 7:44 ` Gjorgji Rosikopulos (Consultant)
2026-12-03 16:53 ` [PATCH v4 07/14] media: qcom: camss: csid-gen3: Report the hardware SOF timestamp Loic Poulain
2026-12-03 16:53 ` [PATCH v4 08/14] media: qcom: camss: Timestamp buffers at start of frame Loic Poulain
2026-12-04 7:59 ` Gjorgji Rosikopulos (Consultant)
2026-12-03 16:53 ` [PATCH v4 09/14] media: qcom: camss: Tell userspace we're using start-of-frame timestamps Loic Poulain
2026-12-04 8:54 ` Gjorgji Rosikopulos (Consultant)
2026-12-03 16:53 ` [PATCH v4 10/14] media: qcom: camss: csid: Let a consumer hook into the frame start Loic Poulain
2026-12-04 13:18 ` Gjorgji Rosikopulos (Consultant)
2026-12-03 16:53 ` [PATCH v4 11/14] media: qcom: camss: Stamp the buffer the write master is filling Loic Poulain
2026-12-04 13:31 ` Gjorgji Rosikopulos (Consultant)
2026-12-03 16:53 ` [PATCH v4 12/14] media: qcom: camss: vfe-gen3: Report the address of the current frame Loic Poulain
2026-12-04 13:32 ` Gjorgji Rosikopulos (Consultant)
2026-12-03 16:53 ` [PATCH v4 13/14] media: qcom: camss: vfe-680: " Loic Poulain
2026-12-04 14:49 ` Gjorgji Rosikopulos (Consultant) [this message]
2026-12-03 16:53 ` [PATCH v4 14/14] media: qcom: camss: vfe-340: " Loic Poulain
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=ad365131-0660-4c54-9523-482f314ee4f9@oss.qualcomm.com \
--to=gjorgji.rosikopulos@oss.qualcomm.com \
--cc=bryan.odonoghue@linaro.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=loic.poulain@oss.qualcomm.com \
--cc=mchehab@kernel.org \
--cc=vladimir.zapolskiy@linaro.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: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®