linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys
@ 2022-11-11  8:29 matthias.bgg
  2022-11-14 11:58 ` AngeloGioacchino Del Regno
  0 siblings, 1 reply; 9+ messages in thread
From: matthias.bgg @ 2022-11-11  8:29 UTC (permalink / raw)
  To: matthias.bgg, nancy.lin; +Cc: linux-arm-kernel, linux-mediatek, linux-kernel

From: Matthias Brugger <matthias.bgg@gmail.com>

For backward compatibility we add the deprecated compatible.

Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
---
Changes since v1:
- fix drive data pointer

 drivers/soc/mediatek/mtk-mmsys.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/soc/mediatek/mtk-mmsys.c b/drivers/soc/mediatek/mtk-mmsys.c
index ba2e79b26993b..f3431448e8431 100644
--- a/drivers/soc/mediatek/mtk-mmsys.c
+++ b/drivers/soc/mediatek/mtk-mmsys.c
@@ -303,6 +303,10 @@ static const struct of_device_id of_match_mtk_mmsys[] = {
 		.compatible = "mediatek,mt8192-mmsys",
 		.data = &mt8192_mmsys_driver_data,
 	},
+	{	/* deprecated compatible */
+		.compatible = "mediatek,mt8195-mmsys",
+		.data = &mt8195_vdosys0_driver_data,
+	},
 	{
 		.compatible = "mediatek,mt8195-vdosys0",
 		.data = &mt8195_vdosys0_driver_data,
-- 
2.38.0


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

* Re: [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys
  2022-11-11  8:29 [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys matthias.bgg
@ 2022-11-14 11:58 ` AngeloGioacchino Del Regno
  2022-11-14 12:07   ` Matthias Brugger
  2022-12-01 11:20   ` Chen-Yu Tsai
  0 siblings, 2 replies; 9+ messages in thread
From: AngeloGioacchino Del Regno @ 2022-11-14 11:58 UTC (permalink / raw)
  To: matthias.bgg, matthias.bgg, nancy.lin
  Cc: linux-arm-kernel, linux-mediatek, linux-kernel

Il 11/11/22 09:29, matthias.bgg@kernel.org ha scritto:
> From: Matthias Brugger <matthias.bgg@gmail.com>
> 
> For backward compatibility we add the deprecated compatible.
> 
> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>

...And tested on MT8195 Cherry Chromebook.

Cheers,
Angelo

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

* Re: [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys
  2022-11-14 11:58 ` AngeloGioacchino Del Regno
@ 2022-11-14 12:07   ` Matthias Brugger
  2022-12-01 11:20   ` Chen-Yu Tsai
  1 sibling, 0 replies; 9+ messages in thread
From: Matthias Brugger @ 2022-11-14 12:07 UTC (permalink / raw)
  To: AngeloGioacchino Del Regno, matthias.bgg, nancy.lin
  Cc: linux-arm-kernel, linux-mediatek, linux-kernel



On 14/11/2022 12:58, AngeloGioacchino Del Regno wrote:
> Il 11/11/22 09:29, matthias.bgg@kernel.org ha scritto:
>> From: Matthias Brugger <matthias.bgg@gmail.com>
>>
>> For backward compatibility we add the deprecated compatible.
>>
>> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
> 
> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
> 
> ...And tested on MT8195 Cherry Chromebook.
> 

Applied, thanks for testing!

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

* Re: [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys
  2022-11-14 11:58 ` AngeloGioacchino Del Regno
  2022-11-14 12:07   ` Matthias Brugger
@ 2022-12-01 11:20   ` Chen-Yu Tsai
  2022-12-01 11:25     ` Chen-Yu Tsai
  2022-12-16 13:33     ` Matthias Brugger
  1 sibling, 2 replies; 9+ messages in thread
From: Chen-Yu Tsai @ 2022-12-01 11:20 UTC (permalink / raw)
  To: AngeloGioacchino Del Regno, matthias.bgg
  Cc: matthias.bgg, nancy.lin, linux-arm-kernel, linux-mediatek, linux-kernel

On Mon, Nov 14, 2022 at 7:59 PM AngeloGioacchino Del Regno
<angelogioacchino.delregno@collabora.com> wrote:
>
> Il 11/11/22 09:29, matthias.bgg@kernel.org ha scritto:
> > From: Matthias Brugger <matthias.bgg@gmail.com>
> >
> > For backward compatibility we add the deprecated compatible.
> >
> > Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
>
> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
>
> ...And tested on MT8195 Cherry Chromebook.

This now seems like a bad idea. In the dtsi we have two nodes (vdosys0 and
vdosys1) that both currently use the -mmsys compatible, which in the driver
maps to vdosys0. So not only do we have vdosys1 incorrectly probing as
vdosys0, we also have duplicate clks being registered and duplicate DRM
pipelines. On my device vdosys1 ends up winning the duplicate clock race.

I suggest just reverting this. The display stuff won't be useful unless
the drivers are able to distinguish themselves from one another.

Regards
ChenYu

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

* Re: [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys
  2022-12-01 11:20   ` Chen-Yu Tsai
@ 2022-12-01 11:25     ` Chen-Yu Tsai
  2022-12-16 13:35       ` Matthias Brugger
  2022-12-16 13:33     ` Matthias Brugger
  1 sibling, 1 reply; 9+ messages in thread
From: Chen-Yu Tsai @ 2022-12-01 11:25 UTC (permalink / raw)
  To: AngeloGioacchino Del Regno, matthias.bgg
  Cc: matthias.bgg, nancy.lin, linux-arm-kernel, linux-mediatek, linux-kernel

On Thu, Dec 1, 2022 at 7:20 PM Chen-Yu Tsai <wenst@chromium.org> wrote:
>
> On Mon, Nov 14, 2022 at 7:59 PM AngeloGioacchino Del Regno
> <angelogioacchino.delregno@collabora.com> wrote:
> >
> > Il 11/11/22 09:29, matthias.bgg@kernel.org ha scritto:
> > > From: Matthias Brugger <matthias.bgg@gmail.com>
> > >
> > > For backward compatibility we add the deprecated compatible.
> > >
> > > Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
> >
> > Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
> >
> > ...And tested on MT8195 Cherry Chromebook.
>
> This now seems like a bad idea. In the dtsi we have two nodes (vdosys0 and
> vdosys1) that both currently use the -mmsys compatible, which in the driver
> maps to vdosys0. So not only do we have vdosys1 incorrectly probing as
> vdosys0, we also have duplicate clks being registered and duplicate DRM
> pipelines. On my device vdosys1 ends up winning the duplicate clock race.
>
> I suggest just reverting this. The display stuff won't be useful unless
> the drivers are able to distinguish themselves from one another.

That and try to fix the vdosys0 node ASAP.

> Regards
> ChenYu

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

* Re: [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys
  2022-12-01 11:20   ` Chen-Yu Tsai
  2022-12-01 11:25     ` Chen-Yu Tsai
@ 2022-12-16 13:33     ` Matthias Brugger
  2022-12-16 13:53       ` Chen-Yu Tsai
  1 sibling, 1 reply; 9+ messages in thread
From: Matthias Brugger @ 2022-12-16 13:33 UTC (permalink / raw)
  To: Chen-Yu Tsai, AngeloGioacchino Del Regno, matthias.bgg
  Cc: nancy.lin, linux-arm-kernel, linux-mediatek, linux-kernel



On 01/12/2022 12:20, Chen-Yu Tsai wrote:
> On Mon, Nov 14, 2022 at 7:59 PM AngeloGioacchino Del Regno
> <angelogioacchino.delregno@collabora.com> wrote:
>>
>> Il 11/11/22 09:29, matthias.bgg@kernel.org ha scritto:
>>> From: Matthias Brugger <matthias.bgg@gmail.com>
>>>
>>> For backward compatibility we add the deprecated compatible.
>>>
>>> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
>>
>> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
>>
>> ...And tested on MT8195 Cherry Chromebook.
> 
> This now seems like a bad idea. In the dtsi we have two nodes (vdosys0 and
> vdosys1) that both currently use the -mmsys compatible, which in the driver
> maps to vdosys0. So not only do we have vdosys1 incorrectly probing as
> vdosys0, we also have duplicate clks being registered and duplicate DRM
> pipelines. On my device vdosys1 ends up winning the duplicate clock race.
> 

That's true, we should fix the DTS deleting vdosys1 node as it's not 
implemented. While at it we should also fix the compatible for vdosys0 as 
"mediatek,mt8195-mmsys" is now deprecated.

Would you mind to send a patch?

Regards,
Matthias

> I suggest just reverting this. The display stuff won't be useful unless
> the drivers are able to distinguish themselves from one another.
> 

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

* Re: [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys
  2022-12-01 11:25     ` Chen-Yu Tsai
@ 2022-12-16 13:35       ` Matthias Brugger
  2022-12-16 13:50         ` Chen-Yu Tsai
  0 siblings, 1 reply; 9+ messages in thread
From: Matthias Brugger @ 2022-12-16 13:35 UTC (permalink / raw)
  To: Chen-Yu Tsai, AngeloGioacchino Del Regno, matthias.bgg
  Cc: nancy.lin, linux-arm-kernel, linux-mediatek, linux-kernel



On 01/12/2022 12:25, Chen-Yu Tsai wrote:
> On Thu, Dec 1, 2022 at 7:20 PM Chen-Yu Tsai <wenst@chromium.org> wrote:
>>
>> On Mon, Nov 14, 2022 at 7:59 PM AngeloGioacchino Del Regno
>> <angelogioacchino.delregno@collabora.com> wrote:
>>>
>>> Il 11/11/22 09:29, matthias.bgg@kernel.org ha scritto:
>>>> From: Matthias Brugger <matthias.bgg@gmail.com>
>>>>
>>>> For backward compatibility we add the deprecated compatible.
>>>>
>>>> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
>>>
>>> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
>>>
>>> ...And tested on MT8195 Cherry Chromebook.
>>
>> This now seems like a bad idea. In the dtsi we have two nodes (vdosys0 and
>> vdosys1) that both currently use the -mmsys compatible, which in the driver
>> maps to vdosys0. So not only do we have vdosys1 incorrectly probing as
>> vdosys0, we also have duplicate clks being registered and duplicate DRM
>> pipelines. On my device vdosys1 ends up winning the duplicate clock race.
>>
>> I suggest just reverting this. The display stuff won't be useful unless
>> the drivers are able to distinguish themselves from one another.
> 
> That and try to fix the vdosys0 node ASAP.

I'm not sure what you mean? If there are any patches that are in my queue that 
needs attention, please let me know.

Regards,
Matthias

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

* Re: [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys
  2022-12-16 13:35       ` Matthias Brugger
@ 2022-12-16 13:50         ` Chen-Yu Tsai
  0 siblings, 0 replies; 9+ messages in thread
From: Chen-Yu Tsai @ 2022-12-16 13:50 UTC (permalink / raw)
  To: Matthias Brugger
  Cc: AngeloGioacchino Del Regno, matthias.bgg, nancy.lin,
	linux-arm-kernel, linux-mediatek, linux-kernel

On Fri, Dec 16, 2022 at 9:35 PM Matthias Brugger <matthias.bgg@gmail.com> wrote:
>
>
>
> On 01/12/2022 12:25, Chen-Yu Tsai wrote:
> > On Thu, Dec 1, 2022 at 7:20 PM Chen-Yu Tsai <wenst@chromium.org> wrote:
> >>
> >> On Mon, Nov 14, 2022 at 7:59 PM AngeloGioacchino Del Regno
> >> <angelogioacchino.delregno@collabora.com> wrote:
> >>>
> >>> Il 11/11/22 09:29, matthias.bgg@kernel.org ha scritto:
> >>>> From: Matthias Brugger <matthias.bgg@gmail.com>
> >>>>
> >>>> For backward compatibility we add the deprecated compatible.
> >>>>
> >>>> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
> >>>
> >>> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
> >>>
> >>> ...And tested on MT8195 Cherry Chromebook.
> >>
> >> This now seems like a bad idea. In the dtsi we have two nodes (vdosys0 and
> >> vdosys1) that both currently use the -mmsys compatible, which in the driver
> >> maps to vdosys0. So not only do we have vdosys1 incorrectly probing as
> >> vdosys0, we also have duplicate clks being registered and duplicate DRM
> >> pipelines. On my device vdosys1 ends up winning the duplicate clock race.
> >>
> >> I suggest just reverting this. The display stuff won't be useful unless
> >> the drivers are able to distinguish themselves from one another.
> >
> > That and try to fix the vdosys0 node ASAP.
>
> I'm not sure what you mean? If there are any patches that are in my queue that
> needs attention, please let me know.

It was more of a P.S. note.

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

* Re: [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys
  2022-12-16 13:33     ` Matthias Brugger
@ 2022-12-16 13:53       ` Chen-Yu Tsai
  0 siblings, 0 replies; 9+ messages in thread
From: Chen-Yu Tsai @ 2022-12-16 13:53 UTC (permalink / raw)
  To: Matthias Brugger
  Cc: AngeloGioacchino Del Regno, matthias.bgg, nancy.lin,
	linux-arm-kernel, linux-mediatek, linux-kernel

On Fri, Dec 16, 2022 at 9:33 PM Matthias Brugger <matthias.bgg@gmail.com> wrote:
>
>
>
> On 01/12/2022 12:20, Chen-Yu Tsai wrote:
> > On Mon, Nov 14, 2022 at 7:59 PM AngeloGioacchino Del Regno
> > <angelogioacchino.delregno@collabora.com> wrote:
> >>
> >> Il 11/11/22 09:29, matthias.bgg@kernel.org ha scritto:
> >>> From: Matthias Brugger <matthias.bgg@gmail.com>
> >>>
> >>> For backward compatibility we add the deprecated compatible.
> >>>
> >>> Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
> >>
> >> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
> >>
> >> ...And tested on MT8195 Cherry Chromebook.
> >
> > This now seems like a bad idea. In the dtsi we have two nodes (vdosys0 and
> > vdosys1) that both currently use the -mmsys compatible, which in the driver
> > maps to vdosys0. So not only do we have vdosys1 incorrectly probing as
> > vdosys0, we also have duplicate clks being registered and duplicate DRM
> > pipelines. On my device vdosys1 ends up winning the duplicate clock race.
> >
>
> That's true, we should fix the DTS deleting vdosys1 node as it's not
> implemented. While at it we should also fix the compatible for vdosys0 as
> "mediatek,mt8195-mmsys" is now deprecated.
>
> Would you mind to send a patch?

I'll be going on vacation shortly, and will be back after Christmas.

Reading the above, I assume you want two patches? One to drop the deprecated
compatible, and another to delete the vdosys1 node? And both should be
tag with fixes and backported?

I can take care of it after I get back. If someone wants to beat me to it,
feel free to do it.


ChenYu

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

end of thread, other threads:[~2022-12-16 13:53 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-11  8:29 [PATCH v2] soc: mediatek: Add deprecated compatible to mmsys matthias.bgg
2022-11-14 11:58 ` AngeloGioacchino Del Regno
2022-11-14 12:07   ` Matthias Brugger
2022-12-01 11:20   ` Chen-Yu Tsai
2022-12-01 11:25     ` Chen-Yu Tsai
2022-12-16 13:35       ` Matthias Brugger
2022-12-16 13:50         ` Chen-Yu Tsai
2022-12-16 13:33     ` Matthias Brugger
2022-12-16 13:53       ` Chen-Yu Tsai

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).