[PATCH v3 7/7] arm64: dts: mt8192: Add devapc node

2021-04-09 Thread Nina Wu
From: Nina Wu Add devapc nodes to mt8192. Signed-off-by: Nina Wu --- This patch depends on "Add dt-bindings of MT8192 clocks" [1] and "Add mt8192 clock controllers" [2] [1] https://patchwork.kernel.org/project/linux-mediatek/patch/20210324104110.13383-7-chun-jie.c...@medi

[PATCH v3 6/7] soc: mediatek: devapc: support mt8192

2021-04-09 Thread Nina Wu
From: Nina Wu Add compatible to support mt8192. Signed-off-by: Nina Wu --- drivers/soc/mediatek/mtk-devapc.c | 16 1 file changed, 16 insertions(+) diff --git a/drivers/soc/mediatek/mtk-devapc.c b/drivers/soc/mediatek/mtk-devapc.c index bdc8fe9..84dd6a2 100644 --- a/drivers

[PATCH v3 5/7] soc: mediatek: devapc: add debug register for new IC support

2021-04-09 Thread Nina Wu
From: Nina Wu There are 3 debug info registers in new ICs while in legacy ones, we have only 2. We add a 'version' field in compatible data to decide how we extract the debug info. Signed-off-by: Nina Wu --- drivers/soc/mediatek/mtk-devapc.c | 43 +++ 1

[PATCH v3 4/7] soc: mediatek: devapc: rename register variable infra_base

2021-04-09 Thread Nina Wu
From: Nina Wu For new ICs, there are multiple devapc HWs for different subsys. For example, there is devapc respectively for infra, peri, peri2, etc. So we rename the variable 'infra_base' to 'base' for code readability. Signed-off-by: Nina Wu --- drivers/soc/mediatek/mtk-devapc.c | 24

[PATCH v3 3/7] soc: mediatek: devapc: add shared flag to IRQ

2021-04-09 Thread Nina Wu
From: Nina Wu For new ICs, there are multiple devapc HWs for different subsys. They all share the same IRQ number. Signed-off-by: Nina Wu --- drivers/soc/mediatek/mtk-devapc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/soc/mediatek/mtk-devapc.c b/drivers/soc

[PATCH v3 2/7] soc: mediatek: devapc: get 'vio_idx_num' info from DT

2021-04-09 Thread Nina Wu
From: Nina Wu For new ICs, there are multiple devapc HWs for different subsys. The number of devices controlled by each devapc (i.e. 'vio_idx_num') will be set in DT for per devapc node. On the other hand, for old ICs which have only one devapc HW, the 'vio_idx_num' info is set in compatible

[PATCH v3 1/7] dt-bindings: devapc: Add 'vio-idx-num' field to support mt8192

2021-04-09 Thread Nina Wu
From: Nina Wu For new ICs, there are multiple devapc HWs for different subsys. We add a field 'vio-idx-num' in DT to indicate the number of devices controlled by each devapc. To be backward compatible with old ICs which have only one devapc HW, this field is not required. The 'vio-idx-num' info

Re: [PATCH v2 1/6] dt-bindings: devapc: Update bindings

2021-04-08 Thread Nina Wu
Hi, Rob On Thu, 2021-04-08 at 15:43 -0500, Rob Herring wrote: > On Thu, Apr 01, 2021 at 02:38:02PM +0800, Nina Wu wrote: > > From: Nina Wu > > Every change is an 'update'. Perhaps mention mt8192 in the subject. > OK. I will try to make it clear in the next version. > &g

Re: [PATCH v2 6/6] soc: mediatek: devapc: support mt8192

2021-04-08 Thread Nina Wu
Hi, Matthias On Tue, 2021-04-06 at 15:55 +0200, Matthias Brugger wrote: > > On 01/04/2021 08:38, Nina Wu wrote: > > From: Nina Wu > > > > Add compatible to support mt8192. > > > > Signed-off-by: Nina Wu > > --- > > > Looks good, I'd like

Re: [PATCH v2 5/6] soc: mediatek: devapc: add debug register for new IC support

2021-04-08 Thread Nina Wu
Hi, Matthias On Tue, 2021-04-06 at 15:53 +0200, Matthias Brugger wrote: > > On 01/04/2021 08:38, Nina Wu wrote: > > From: Nina Wu > > > > There are 3 debug info registers in new ICs while in legacy ones, > > we have only 2. When dumping the debug info, we need

Re: [PATCH v2 4/6] soc: mediatek: devapc: rename variable for new IC support

2021-04-07 Thread Nina Wu
> Other then that looks good to me. > OK. I will fix it in the next version. Thanks > On 01/04/2021 08:38, Nina Wu wrote: > > From: Nina Wu > > > > For new ICs, there are multiple devapc HWs for different subsys. > > For example, there is devapc respectively fo

Re: [PATCH v2 2/6] soc: mediatek: devapc: move 'vio_idx_num' info to DT

2021-04-07 Thread Nina Wu
Hi, Matthias On Tue, 2021-04-06 at 15:41 +0200, Matthias Brugger wrote: > > On 01/04/2021 08:38, Nina Wu wrote: > > From: Nina Wu > > > > For new ICs, there are multiple devapc HWs for different subsys. > > The number of devices controlled by each devapc (i.e.

[PATCH v2 6/6] soc: mediatek: devapc: support mt8192

2021-04-01 Thread Nina Wu
From: Nina Wu Add compatible to support mt8192. Signed-off-by: Nina Wu --- drivers/soc/mediatek/mtk-devapc.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/drivers/soc/mediatek/mtk-devapc.c b/drivers/soc/mediatek/mtk-devapc.c index af55c01..a5c15b5 100644 --- a/drivers

[PATCH v2 4/6] soc: mediatek: devapc: rename variable for new IC support

2021-04-01 Thread Nina Wu
From: Nina Wu For new ICs, there are multiple devapc HWs for different subsys. For example, there is devapc respectively for infra, peri, peri2, etc. So we rename the variable 'infra_base' to 'base' for code readability. Signed-off-by: Nina Wu --- drivers/soc/mediatek/mtk-devapc.c | 24

[PATCH v2 5/6] soc: mediatek: devapc: add debug register for new IC support

2021-04-01 Thread Nina Wu
From: Nina Wu There are 3 debug info registers in new ICs while in legacy ones, we have only 2. When dumping the debug info, we need to check first if the 3rd debug register exists and then we can konw how to decipher the debug info. Signed-off-by: Nina Wu --- drivers/soc/mediatek/mtk

[PATCH v2 3/6] soc: mediatek: devapc: add shared flag to IRQ

2021-04-01 Thread Nina Wu
From: Nina Wu For new ICs, there are multiple devapc HWs for different subsys. They all share the same IRQ number. Signed-off-by: Nina Wu --- drivers/soc/mediatek/mtk-devapc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/soc/mediatek/mtk-devapc.c b/drivers/soc

[PATCH v2 2/6] soc: mediatek: devapc: move 'vio_idx_num' info to DT

2021-04-01 Thread Nina Wu
From: Nina Wu For new ICs, there are multiple devapc HWs for different subsys. The number of devices controlled by each devapc (i.e. 'vio_idx_num' in the code) varies. We move this info from compatible data to DT so that we do not need to add n compatible for a certain IC which has n devapc HWs

[PATCH v2 1/6] dt-bindings: devapc: Update bindings

2021-04-01 Thread Nina Wu
From: Nina Wu To support newer hardware architecture of devapc, update device tree bindings. Signed-off-by: Nina Wu --- Documentation/devicetree/bindings/soc/mediatek/devapc.yaml | 8 1 file changed, 8 insertions(+) diff --git a/Documentation/devicetree/bindings/soc/mediatek

Re: [PATCH 1/2] dt-bindings: devapc: Update bindings

2021-03-29 Thread Nina Wu
Hi, Matthias On Mon, 2021-03-29 at 13:16 +0200, Matthias Brugger wrote: > > On 26/03/2021 08:31, Nina Wu wrote: > > From: Nina Wu > > > > To support newer hardware architecture of devapc, > > update device tree bindings. > > > > Signed-off-by: Nina Wu

Re: [PATCH 2/2] soc: mediatek: Add mt8192 devapc driver

2021-03-29 Thread Nina Wu
hich actually adds support for the new SoC. > > More comments below. > Thanks for the advice. I will try to split it in the next version. > > On 26/03/2021 08:31, Nina Wu wrote: > > From: Nina Wu > > > > The hardware architecture of mt8192 devapc is slightly

Re: [PATCH 1/2] dt-bindings: devapc: Update bindings

2021-03-28 Thread Nina Wu
Hi, Rob On Fri, 2021-03-26 at 13:58 -0600, Rob Herring wrote: > On Fri, Mar 26, 2021 at 03:31:10PM +0800, Nina Wu wrote: > > From: Nina Wu > > > > To support newer hardware architecture of devapc, > > update device tree bindings. > > > > Signed-off-b

Re: [PATCH 1/2] dt-bindings: devapc: Update bindings

2021-03-28 Thread Nina Wu
Hi, Chun-Kuang On Sat, 2021-03-27 at 00:18 +0800, Chun-Kuang Hu wrote: > Hi, Nina: > > Nina Wu 於 2021年3月26日 週五 下午3:34寫道: > > > > From: Nina Wu > > > > To support newer hardware architecture of devapc, > > update device tree bindings. > > > >

Re: [PATCH 1/2] dt-bindings: devapc: Update bindings

2021-03-28 Thread Nina Wu
: > On Fri, 26 Mar 2021 15:31:10 +0800, Nina Wu wrote: > > From: Nina Wu > > > > To support newer hardware architecture of devapc, > > update device tree bindings. > > > > Signed-off-by: Nina Wu > > --- > > .../devicetree/bindings/soc/mediatek/de

[PATCH 2/2] soc: mediatek: Add mt8192 devapc driver

2021-03-26 Thread Nina Wu
From: Nina Wu The hardware architecture of mt8192 devapc is slightly different from that of the previous IC. We add necessary extensions to support mt8192 and be back-compatible with other ICs. Signed-off-by: Nina Wu --- drivers/soc/mediatek/mtk-devapc.c | 213

[PATCH 1/2] dt-bindings: devapc: Update bindings

2021-03-26 Thread Nina Wu
From: Nina Wu To support newer hardware architecture of devapc, update device tree bindings. Signed-off-by: Nina Wu --- .../devicetree/bindings/soc/mediatek/devapc.yaml | 41 ++ 1 file changed, 41 insertions(+) diff --git a/Documentation/devicetree/bindings/soc/mediatek