dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3, 1/2] soc: mediatek: Add mmsys func to adapt to dpi output for MT8186
@ 2022-08-23  6:38 xinlei.lee
  2022-08-23 20:17 ` [PATCH v3,1/2] " Nícolas F. R. A. Prado
  0 siblings, 1 reply; 6+ messages in thread
From: xinlei.lee @ 2022-08-23  6:38 UTC (permalink / raw)
  To: chunkuang.hu, p.zabel, airlied, daniel, matthias.bgg,
	rex-bc.chen, angelogioacchino.delregno, jason-jh.lin,
	yongqiang.niu
  Cc: Jitao Shi, Xinlei Lee, linux-kernel, dri-devel,
	Project_Global_Chrome_Upstream_Group, linux-mediatek,
	linux-arm-kernel

From: Xinlei Lee <xinlei.lee@mediatek.com>

Add mmsys function to manipulate dpi output format configuration for MT8186.

Co-developed-by: Jitao Shi <jitao.shi@mediatek.com>
Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
Signed-off-by: Xinlei Lee <xinlei.lee@mediatek.com>

---
 drivers/soc/mediatek/mt8186-mmsys.h    | 1 +
 drivers/soc/mediatek/mtk-mmsys.c       | 8 ++++++++
 include/linux/soc/mediatek/mtk-mmsys.h | 3 +++
 3 files changed, 12 insertions(+)

diff --git a/drivers/soc/mediatek/mt8186-mmsys.h b/drivers/soc/mediatek/mt8186-mmsys.h
index eb1ad9c37a9c..6eca3445bea3 100644
--- a/drivers/soc/mediatek/mt8186-mmsys.h
+++ b/drivers/soc/mediatek/mt8186-mmsys.h
@@ -3,6 +3,7 @@
 #ifndef __SOC_MEDIATEK_MT8186_MMSYS_H
 #define __SOC_MEDIATEK_MT8186_MMSYS_H
 
+#define MT8186_DPI_OUTPUT_FORMAT		0x400
 #define MT8186_MMSYS_OVL_CON			0xF04
 #define MT8186_MMSYS_OVL0_CON_MASK			0x3
 #define MT8186_MMSYS_OVL0_2L_CON_MASK			0xC
diff --git a/drivers/soc/mediatek/mtk-mmsys.c b/drivers/soc/mediatek/mtk-mmsys.c
index 114defd48298..aeda6e2bf80b 100644
--- a/drivers/soc/mediatek/mtk-mmsys.c
+++ b/drivers/soc/mediatek/mtk-mmsys.c
@@ -252,6 +252,14 @@ void mtk_mmsys_ddp_disconnect(struct device *dev,
 }
 EXPORT_SYMBOL_GPL(mtk_mmsys_ddp_disconnect);
 
+void mtk_mmsys_ddp_dpi_fmt_config(struct device *dev, u32 mask, u32 val,
+				   struct cmdq_pkt *cmdq_pkt)
+{
+	mtk_mmsys_update_bits(dev_get_drvdata(dev), MT8186_DPI_OUTPUT_FORMAT, mask,
+			      val, cmdq_pkt);
+}
+EXPORT_SYMBOL_GPL(mtk_mmsys_ddp_dpi_fmt_config);
+
 void mtk_mmsys_merge_async_config(struct device *dev, int idx, int width, int height,
 				  struct cmdq_pkt *cmdq_pkt)
 {
diff --git a/include/linux/soc/mediatek/mtk-mmsys.h b/include/linux/soc/mediatek/mtk-mmsys.h
index 343e093f0fc3..08caa2b8a374 100644
--- a/include/linux/soc/mediatek/mtk-mmsys.h
+++ b/include/linux/soc/mediatek/mtk-mmsys.h
@@ -90,4 +90,7 @@ void mtk_mmsys_mixer_in_config(struct device *dev, int idx, bool alpha_sel, u16
 void mtk_mmsys_mixer_in_channel_swap(struct device *dev, int idx, bool channel_swap,
 				     struct cmdq_pkt *cmdq_pkt);
 
+void mtk_mmsys_ddp_dpi_fmt_config(struct device *dev, u32 mask, u32 val,
+				   struct cmdq_pkt *cmdq_pkt);
+
 #endif /* __MTK_MMSYS_H */
-- 
2.18.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH v3,1/2] soc: mediatek: Add mmsys func to adapt to dpi output for MT8186
  2022-08-23  6:38 [PATCH v3, 1/2] soc: mediatek: Add mmsys func to adapt to dpi output for MT8186 xinlei.lee
@ 2022-08-23 20:17 ` Nícolas F. R. A. Prado
  2022-08-25 15:04   ` Matthias Brugger
  0 siblings, 1 reply; 6+ messages in thread
From: Nícolas F. R. A. Prado @ 2022-08-23 20:17 UTC (permalink / raw)
  To: xinlei.lee
  Cc: chunkuang.hu, Jitao Shi, airlied, jason-jh.lin, linux-kernel,
	dri-devel, yongqiang.niu, Project_Global_Chrome_Upstream_Group,
	matthias.bgg, linux-mediatek, rex-bc.chen, linux-arm-kernel,
	angelogioacchino.delregno

On Tue, Aug 23, 2022 at 02:38:22PM +0800, xinlei.lee@mediatek.com wrote:
> From: Xinlei Lee <xinlei.lee@mediatek.com>
> 
> Add mmsys function to manipulate dpi output format configuration for MT8186.
> 
> Co-developed-by: Jitao Shi <jitao.shi@mediatek.com>
> Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
> Signed-off-by: Xinlei Lee <xinlei.lee@mediatek.com>

Reviewed-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>

Thanks,
Nícolas

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v3,1/2] soc: mediatek: Add mmsys func to adapt to dpi output for MT8186
  2022-08-23 20:17 ` [PATCH v3,1/2] " Nícolas F. R. A. Prado
@ 2022-08-25 15:04   ` Matthias Brugger
  2022-08-26  6:12     ` xinlei.lee
  0 siblings, 1 reply; 6+ messages in thread
From: Matthias Brugger @ 2022-08-25 15:04 UTC (permalink / raw)
  To: Nícolas F. R. A. Prado, xinlei.lee
  Cc: chunkuang.hu, Jitao Shi, airlied, jason-jh.lin, linux-kernel,
	dri-devel, yongqiang.niu, Project_Global_Chrome_Upstream_Group,
	linux-mediatek, rex-bc.chen, linux-arm-kernel,
	angelogioacchino.delregno



On 23/08/2022 22:17, Nícolas F. R. A. Prado wrote:
> On Tue, Aug 23, 2022 at 02:38:22PM +0800, xinlei.lee@mediatek.com wrote:
>> From: Xinlei Lee <xinlei.lee@mediatek.com>
>>
>> Add mmsys function to manipulate dpi output format configuration for MT8186.
>>
>> Co-developed-by: Jitao Shi <jitao.shi@mediatek.com>
>> Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
>> Signed-off-by: Xinlei Lee <xinlei.lee@mediatek.com>
> 
> Reviewed-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
> 

Patch looks fine, I'll wait for v4 as there is still some discussion on the DRM 
part. Please try to fix the threading problem you had in sending this series.

Thanks,
Matthias

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v3,1/2] soc: mediatek: Add mmsys func to adapt to dpi output for MT8186
  2022-08-25 15:04   ` Matthias Brugger
@ 2022-08-26  6:12     ` xinlei.lee
  2022-08-26 13:29       ` Nícolas F. R. A. Prado
  0 siblings, 1 reply; 6+ messages in thread
From: xinlei.lee @ 2022-08-26  6:12 UTC (permalink / raw)
  To: Matthias Brugger, Nícolas F. R. A. Prado
  Cc: chunkuang.hu, Jitao Shi, airlied, jason-jh.lin, linux-kernel,
	dri-devel, yongqiang.niu, Project_Global_Chrome_Upstream_Group,
	linux-mediatek, rex-bc.chen, linux-arm-kernel,
	angelogioacchino.delregno

On Thu, 2022-08-25 at 17:04 +0200, Matthias Brugger wrote:
> 
> On 23/08/2022 22:17, Nícolas F. R. A. Prado wrote:
> > On Tue, Aug 23, 2022 at 02:38:22PM +0800, xinlei.lee@mediatek.com
> > wrote:
> > > From: Xinlei Lee <xinlei.lee@mediatek.com>
> > > 
> > > Add mmsys function to manipulate dpi output format configuration
> > > for MT8186.
> > > 
> > > Co-developed-by: Jitao Shi <jitao.shi@mediatek.com>
> > > Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
> > > Signed-off-by: Xinlei Lee <xinlei.lee@mediatek.com>
> > 
> > Reviewed-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
> > 
> 
> Patch looks fine, I'll wait for v4 as there is still some discussion
> on the DRM 
> part. Please try to fix the threading problem you had in sending this
> series.
> 
> Thanks,
> Matthias

Hi Matthias:

Thanks for your review.

Before I send the next version, do you mean the treading problem you
are talking about is the problem I'm discussing in another patch in
this series, or something else?

Best Regards!
Xinlei


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v3,1/2] soc: mediatek: Add mmsys func to adapt to dpi output for MT8186
  2022-08-26  6:12     ` xinlei.lee
@ 2022-08-26 13:29       ` Nícolas F. R. A. Prado
  2022-08-29  1:38         ` xinlei.lee
  0 siblings, 1 reply; 6+ messages in thread
From: Nícolas F. R. A. Prado @ 2022-08-26 13:29 UTC (permalink / raw)
  To: xinlei.lee
  Cc: chunkuang.hu, Jitao Shi, airlied, jason-jh.lin, linux-kernel,
	dri-devel, yongqiang.niu, Project_Global_Chrome_Upstream_Group,
	rex-bc.chen, linux-mediatek, Matthias Brugger, linux-arm-kernel,
	angelogioacchino.delregno

On Fri, Aug 26, 2022 at 02:12:00PM +0800, xinlei.lee wrote:
> On Thu, 2022-08-25 at 17:04 +0200, Matthias Brugger wrote:
> > 
> > On 23/08/2022 22:17, Nícolas F. R. A. Prado wrote:
> > > On Tue, Aug 23, 2022 at 02:38:22PM +0800, xinlei.lee@mediatek.com
> > > wrote:
> > > > From: Xinlei Lee <xinlei.lee@mediatek.com>
> > > > 
> > > > Add mmsys function to manipulate dpi output format configuration
> > > > for MT8186.
> > > > 
> > > > Co-developed-by: Jitao Shi <jitao.shi@mediatek.com>
> > > > Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
> > > > Signed-off-by: Xinlei Lee <xinlei.lee@mediatek.com>
> > > 
> > > Reviewed-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
> > > 
> > 
> > Patch looks fine, I'll wait for v4 as there is still some discussion
> > on the DRM 
> > part. Please try to fix the threading problem you had in sending this
> > series.
> > 
> > Thanks,
> > Matthias
> 
> Hi Matthias:
> 
> Thanks for your review.
> 
> Before I send the next version, do you mean the treading problem you
> are talking about is the problem I'm discussing in another patch in
> this series, or something else?

Hi Xinlei,

no, the threading problem Matthias is referring to is the fact that this version
of your series had two cover letters (patch 0) and a patch 2 [1], while patch 1
was sent in a different email thread [2]. The whole series (cover letter,
patches 1 and 2), should have been in the same email thread. Also, I noticed
that your cover letter lists the patches with incorrect prefixes "FROMLIST".

So something weird happened when you sent this version of the series. It was ok
in the previous version. So just make sure this is fixed when you send the next
version of the series (after we finish the discussion on patch 2).

[1] https://lore.kernel.org/linux-mediatek/1661235517-23699-1-git-send-email-xinlei.lee@mediatek.com/
[2] https://lore.kernel.org/linux-mediatek/1661236702-30682-1-git-send-email-xinlei.lee@mediatek.com/

Thanks,
Nícolas

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v3,1/2] soc: mediatek: Add mmsys func to adapt to dpi output for MT8186
  2022-08-26 13:29       ` Nícolas F. R. A. Prado
@ 2022-08-29  1:38         ` xinlei.lee
  0 siblings, 0 replies; 6+ messages in thread
From: xinlei.lee @ 2022-08-29  1:38 UTC (permalink / raw)
  To: Nícolas F. R. A. Prado
  Cc: chunkuang.hu, Jitao Shi, airlied, jason-jh.lin, linux-kernel,
	dri-devel, yongqiang.niu, Project_Global_Chrome_Upstream_Group,
	rex-bc.chen, linux-mediatek, Matthias Brugger, linux-arm-kernel,
	angelogioacchino.delregno

On Fri, 2022-08-26 at 09:29 -0400, Nícolas F. R. A. Prado wrote:
> On Fri, Aug 26, 2022 at 02:12:00PM +0800, xinlei.lee wrote:
> > On Thu, 2022-08-25 at 17:04 +0200, Matthias Brugger wrote:
> > > 
> > > On 23/08/2022 22:17, Nícolas F. R. A. Prado wrote:
> > > > On Tue, Aug 23, 2022 at 02:38:22PM +0800, 
> > > > xinlei.lee@mediatek.com
> > > > wrote:
> > > > > From: Xinlei Lee <xinlei.lee@mediatek.com>
> > > > > 
> > > > > Add mmsys function to manipulate dpi output format
> > > > > configuration
> > > > > for MT8186.
> > > > > 
> > > > > Co-developed-by: Jitao Shi <jitao.shi@mediatek.com>
> > > > > Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
> > > > > Signed-off-by: Xinlei Lee <xinlei.lee@mediatek.com>
> > > > 
> > > > Reviewed-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
> > > > 
> > > 
> > > Patch looks fine, I'll wait for v4 as there is still some
> > > discussion
> > > on the DRM 
> > > part. Please try to fix the threading problem you had in sending
> > > this
> > > series.
> > > 
> > > Thanks,
> > > Matthias
> > 
> > Hi Matthias:
> > 
> > Thanks for your review.
> > 
> > Before I send the next version, do you mean the treading problem
> > you
> > are talking about is the problem I'm discussing in another patch in
> > this series, or something else?
> 
> Hi Xinlei,
> 
> no, the threading problem Matthias is referring to is the fact that
> this version
> of your series had two cover letters (patch 0) and a patch 2 [1],
> while patch 1
> was sent in a different email thread [2]. The whole series (cover
> letter,
> patches 1 and 2), should have been in the same email thread. Also, I
> noticed
> that your cover letter lists the patches with incorrect prefixes
> "FROMLIST".
> 
> So something weird happened when you sent this version of the series.
> It was ok
> in the previous version. So just make sure this is fixed when you
> send the next
> version of the series (after we finish the discussion on patch 2).
> 
> [1] 
> https://lore.kernel.org/linux-mediatek/1661235517-23699-1-git-send-email-xinlei.lee@mediatek.com/
> [2] 
> https://lore.kernel.org/linux-mediatek/1661236702-30682-1-git-send-email-xinlei.lee@mediatek.com/
> 
> Thanks,
> Nícolas

Hi Nícolas:

Thanks for the thoughtful explanation of this, I may know what caused
the two patches not to be in a series. 
I will fix this and revise the "FROMLIST" tag in the cover letter in
the next version.

Best Regards!
Xinlei


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-08-29  1:38 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-23  6:38 [PATCH v3, 1/2] soc: mediatek: Add mmsys func to adapt to dpi output for MT8186 xinlei.lee
2022-08-23 20:17 ` [PATCH v3,1/2] " Nícolas F. R. A. Prado
2022-08-25 15:04   ` Matthias Brugger
2022-08-26  6:12     ` xinlei.lee
2022-08-26 13:29       ` Nícolas F. R. A. Prado
2022-08-29  1:38         ` xinlei.lee

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).