public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: Matthias Brugger <matthias.bgg@gmail.com>
To: Enric Balletbo i Serra <enric.balletbo@collabora.com>,
	Chun-Kuang Hu <chunkuang.hu@kernel.org>
Cc: Nicolas Boichat <drinkcat@chromium.org>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	"moderated list:ARM/Mediatek SoC support"
	<linux-mediatek@lists.infradead.org>,
	Yongqiang Niu <yongqiang.niu@mediatek.com>,
	Hsin-Yi Wang <hsinyi@chromium.org>, CK Hu <ck.hu@mediatek.com>,
	Collabora Kernel ML <kernel@collabora.com>,
	Linux ARM <linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH 4/4] soc: mediatek: mmsys: Use an array for setting the routing registers
Date: Thu, 8 Oct 2020 12:53:31 +0200	[thread overview]
Message-ID: <d46f09a9-22bf-da68-5629-f080f7804b92@gmail.com> (raw)
In-Reply-To: <580ecdf4-a686-f14c-a230-7f87f0c8cde5@collabora.com>



On 08/10/2020 09:49, Enric Balletbo i Serra wrote:
> Hi Chun-Kuang,
> 
> On 8/10/20 2:01, Chun-Kuang Hu wrote:
>> Hi, Enric:
>>
>> Enric Balletbo i Serra <enric.balletbo@collabora.com> 於 2020年10月7日 週三 上午3:33寫道:
>>>
>>> From: CK Hu <ck.hu@mediatek.com>
>>>
>>> Actually, setting the registers for routing, use multiple 'if-else' for different
>>> routes, but this code would be more and more complicated while we
>>> support more and more SoCs. Change that and use a table per SoC so the
>>> code will be more portable and clear.
>>>
>>> Signed-off-by: CK Hu <ck.hu@mediatek.com>
>>> Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
>>> ---
>>>
>>>   drivers/soc/mediatek/mtk-mmsys.c | 393 +++++++++++++++++--------------
>>>   1 file changed, 210 insertions(+), 183 deletions(-)
>>>
>>
>> [snip]
>>
>>>
>>>   static const struct mtk_mmsys_driver_data mt2701_mmsys_driver_data = {
>>> @@ -93,10 +115,6 @@ static const struct mtk_mmsys_driver_data mt6797_mmsys_driver_data = {
>>>          .clk_driver = "clk-mt6797-mm",
>>>   };
>>>
>>> -static const struct mtk_mmsys_driver_data mt8173_mmsys_driver_data = {
>>> -       .clk_driver = "clk-mt8173-mm",
>>> -};
>>> -
>>>   static const struct mtk_mmsys_driver_data mt8183_mmsys_driver_data = {
>>>          .clk_driver = "clk-mt8183-mm",
>>>   };
>>> @@ -106,180 +124,192 @@ struct mtk_mmsys {
>>>          const struct mtk_mmsys_driver_data *data;
>>>   };
>>>
>>
>> [snip]
>>
>>> +static const struct mtk_mmsys_driver_data mt8173_mmsys_driver_data = {
>>> +       .clk_driver = "clk-mt8173-mm",
>>> +       .routes = mt8173_mmsys_routing_table,
>>> +       .num_routes = ARRAY_SIZE(mt8173_mmsys_routing_table),
>>> +};
>>>
>>
>> I remove my Reviewed-by tag. You does not set routes for mt2701 and
>> mt2712, but these two SoC need that. Maybe now they use the same table
>> as mt8173.
>>
> 
> I did that on purpose as explained in the cover letter, and asked for someone
> with the hardware to provide me a working routing table. But, if you think the
> same routing should work on those devices I'm fine to use the same for all the
> current devices. I don't have that hardware, so anyway, will need to test.
> 

But you could deduce the routes needed by having a look into the components in 
mtk_drm_drv.c, correct?
Well see my other email, but defining them twice sounds like not a good approach 
to me.

Regards,
Matthias

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2020-10-08 10:55 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-06 19:33 [PATCH 0/4] soc: mediatek: Prepare MMSYS for DDP routing using tables Enric Balletbo i Serra
2020-10-06 19:33 ` [PATCH 1/4] soc / drm: mediatek: Move DDP component defines into mtk-mmsys.h Enric Balletbo i Serra
2020-11-27 23:35   ` Matthias Brugger
2020-10-06 19:33 ` [PATCH 2/4] soc: mediatek: mmsys: Use devm_platform_ioremap_resource() Enric Balletbo i Serra
2020-10-06 23:21   ` Chun-Kuang Hu
2020-10-07  0:01     ` Chun-Kuang Hu
2020-11-27 23:35   ` Matthias Brugger
2020-10-06 19:33 ` [PATCH 3/4] soc: mediatek: mmsys: Create struct mtk_mmsys to store context data Enric Balletbo i Serra
2020-10-06 23:24   ` Chun-Kuang Hu
2020-10-07  0:00     ` Chun-Kuang Hu
2020-10-06 19:33 ` [PATCH 4/4] soc: mediatek: mmsys: Use an array for setting the routing registers Enric Balletbo i Serra
2020-10-07  0:02   ` Chun-Kuang Hu
2020-10-08  0:01   ` Chun-Kuang Hu
2020-10-08  7:49     ` Enric Balletbo i Serra
2020-10-08 10:53       ` Matthias Brugger [this message]
2020-10-08 10:22   ` Matthias Brugger
2020-10-11  2:22     ` Chun-Kuang Hu
2020-10-15 13:32       ` Enric Balletbo i Serra
2020-11-04 10:43 ` [PATCH 0/4] soc: mediatek: Prepare MMSYS for DDP routing using tables Enric Balletbo i Serra

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=d46f09a9-22bf-da68-5629-f080f7804b92@gmail.com \
    --to=matthias.bgg@gmail.com \
    --cc=chunkuang.hu@kernel.org \
    --cc=ck.hu@mediatek.com \
    --cc=drinkcat@chromium.org \
    --cc=enric.balletbo@collabora.com \
    --cc=hsinyi@chromium.org \
    --cc=kernel@collabora.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=yongqiang.niu@mediatek.com \
    /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