[PATCH v2 0/2] PCI: mediatek: Fixups for the IRQ handle routine and MT7622's class code

2017-12-20 Thread honghui.zhang
From: Honghui Zhang Two fixups for mediatek's host bridge: The first patch fixup the IRQ handle routine to avoid IRQ reentry which may exist for both MT2712 and MT7622. The second patch fixup class type for MT7622. Change Since v1: - Add the second patch. - Make

[PATCH v2 1/2] PCI: mediatek: Clear IRQ status after IRQ dispatched to avoid reentry

2017-12-20 Thread honghui.zhang
From: Honghui Zhang There maybe a same IRQ reentry scenario after IRQ received in current IRQ handle flow: EP device PCIe host driverEP driver 1. issue an IRQ 2. received IRQ 3. clear IRQ

[PATCH v2 0/2] PCI: mediatek: Fixups for the IRQ handle routine and MT7622's class code

2017-12-20 Thread honghui.zhang
From: Honghui Zhang Two fixups for mediatek's host bridge: The first patch fixup the IRQ handle routine to avoid IRQ reentry which may exist for both MT2712 and MT7622. The second patch fixup class type for MT7622. Change Since v1: - Add the second patch. - Make the first patch's commit

[PATCH v2 1/2] PCI: mediatek: Clear IRQ status after IRQ dispatched to avoid reentry

2017-12-20 Thread honghui.zhang
From: Honghui Zhang There maybe a same IRQ reentry scenario after IRQ received in current IRQ handle flow: EP device PCIe host driverEP driver 1. issue an IRQ 2. received IRQ 3. clear IRQ status

[PATCH v2 2/2] PCI: mediatek: Fixup class type for MT7622

2017-12-20 Thread honghui.zhang
From: Honghui Zhang The host bridge of MT7622 has hardware code the class code to an arbitrary, meaningless value, fix that. Signed-off-by: Honghui Zhang --- drivers/pci/host/pcie-mediatek.c | 12 1 file changed, 12 insertions(+) diff --git a/drivers/pci/host/pcie-mediatek.c

[PATCH v2 0/2] PCI: mediatek: Fixups for the IRQ handle routine and MT7622's class code

2017-12-20 Thread honghui.zhang
From: Honghui Zhang Two fixups for mediatek's host bridge: The first patch fixup the IRQ handle routine to avoid IRQ reentry which may exist for both MT2712 and MT7622. The second patch fixup class type for MT7622. Change Since v1: - Add the second patch. - Make

[PATCH v2 0/2] PCI: mediatek: Fixups for the IRQ handle routine and MT7622's class code

2017-12-20 Thread honghui.zhang
From: Honghui Zhang Two fixups for mediatek's host bridge: The first patch fixup the IRQ handle routine to avoid IRQ reentry which may exist for both MT2712 and MT7622. The second patch fixup class type for MT7622. Change Since v1: - Add the second patch. - Make the first patch's commit

[PATCH v2 2/2] PCI: mediatek: Fixup class type for MT7622

2017-12-20 Thread honghui.zhang
From: Honghui Zhang The host bridge of MT7622 has hardware code the class code to an arbitrary, meaningless value, fix that. Signed-off-by: Honghui Zhang --- drivers/pci/host/pcie-mediatek.c | 12 1 file changed, 12

[PATCH v2 2/2] PCI: mediatek: Fixup class type for MT7622

2017-12-20 Thread honghui.zhang
From: Honghui Zhang The host bridge of MT7622 has hardware code the class code to an arbitrary, meaningless value, fix that. Signed-off-by: Honghui Zhang --- drivers/pci/host/pcie-mediatek.c | 12 1 file changed, 12 insertions(+) diff --git a/drivers/pci/host/pcie-mediatek.c

[PATCH v2 1/2] PCI: mediatek: Clear IRQ status after IRQ dispatched to avoid reentry

2017-12-20 Thread honghui.zhang
From: Honghui Zhang There maybe a same IRQ reentry scenario after IRQ received in current IRQ handle flow: EP device PCIe host driverEP driver 1. issue an IRQ 2. received IRQ 3. clear IRQ

[PATCH v2 1/2] PCI: mediatek: Clear IRQ status after IRQ dispatched to avoid reentry

2017-12-20 Thread honghui.zhang
From: Honghui Zhang There maybe a same IRQ reentry scenario after IRQ received in current IRQ handle flow: EP device PCIe host driverEP driver 1. issue an IRQ 2. received IRQ 3. clear IRQ status

[PATCH] PCI: Mediatek: clear irq status after irq dispathed to avoid reentry

2017-12-19 Thread honghui.zhang
From: Honghui Zhang There maybe a same irq reentry scenario after irq received in current irq handle flow: EP device PCIe host driverEP driver 1. issue an irq 2. received irq 3. clear irq

[PATCH] PCI: Mediatek: clear irq status after irq dispathed to avoid reentry

2017-12-19 Thread honghui.zhang
From: Honghui Zhang There maybe a same irq reentry scenario after irq received in current irq handle flow: EP device PCIe host driverEP driver 1. issue an irq 2. received irq 3. clear irq status

[PATCH] PCI: mediatek: take use of PCI_NUM_INTX

2017-08-29 Thread honghui.zhang
From: Honghui Zhang Switch from using a custom NUM_INTX macro to the generic PCI_NUM_INTX definition for the number of INTx interrupts. Signed-off-by: Honghui Zhang --- drivers/pci/host/pcie-mediatek.c | 5 ++--- 1 file changed, 2

[PATCH] PCI: mediatek: take use of PCI_NUM_INTX

2017-08-29 Thread honghui.zhang
From: Honghui Zhang Switch from using a custom NUM_INTX macro to the generic PCI_NUM_INTX definition for the number of INTx interrupts. Signed-off-by: Honghui Zhang --- drivers/pci/host/pcie-mediatek.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git

[PATCH v2 1/3] PCI: mediatek: Fix return value in case of error

2017-08-14 Thread honghui.zhang
From: Honghui Zhang In commit ae02a6dda285 ("PCI: mediatek: Add controller support for MT2712 and MT7622"), the function 'mtk_pcie_init_irq_domain', the pattern used to check and return error is: if (!var) { dev_err(...); return PTR_ERR(var); } The

[PATCH v2 1/3] PCI: mediatek: Fix return value in case of error

2017-08-14 Thread honghui.zhang
From: Honghui Zhang In commit ae02a6dda285 ("PCI: mediatek: Add controller support for MT2712 and MT7622"), the function 'mtk_pcie_init_irq_domain', the pattern used to check and return error is: if (!var) { dev_err(...); return PTR_ERR(var); } The return value in such case is

[PATCH v2 0/3] PCI: mediatek: Add MSI support for MT2712 and MT7622

2017-08-14 Thread honghui.zhang
From: Honghui Zhang MT2712 and MT7622's PCIe host controller support MSI, but only 32bit MSI address are supportted. It connect to GIC with the same IRQ number of INTx IRQ, so it shares the same IRQ with INTx IRQ. This patchset add MSI support for MT2712 and MT7622.

[PATCH v2 0/3] PCI: mediatek: Add MSI support for MT2712 and MT7622

2017-08-14 Thread honghui.zhang
From: Honghui Zhang MT2712 and MT7622's PCIe host controller support MSI, but only 32bit MSI address are supportted. It connect to GIC with the same IRQ number of INTx IRQ, so it shares the same IRQ with INTx IRQ. This patchset add MSI support for MT2712 and MT7622. Also do some code fixup and

[PATCH v2 3/3] PCI: mediatek: add msi support for MT2712 and MT7622

2017-08-14 Thread honghui.zhang
From: Honghui Zhang MT2712 and MT7622's PCIe host controller support MSI, but only 32bit MSI address are supportted. It connect to GIC with the same IRQ number of INTx IRQ, so it shares the same IRQ with INTx IRQ. This patch add MSI support for MT2712 and MT7622.

[PATCH v2 3/3] PCI: mediatek: add msi support for MT2712 and MT7622

2017-08-14 Thread honghui.zhang
From: Honghui Zhang MT2712 and MT7622's PCIe host controller support MSI, but only 32bit MSI address are supportted. It connect to GIC with the same IRQ number of INTx IRQ, so it shares the same IRQ with INTx IRQ. This patch add MSI support for MT2712 and MT7622. Signed-off-by: Honghui Zhang

[PATCH v2 2/3] PCI: mediatek: take use of bus->sysdata to get host private data

2017-08-14 Thread honghui.zhang
From: Honghui Zhang Commit ae02a6dda285 ("PCI: mediatek: Add controller support for MT2712 and MT7622") has put the mtk_pcie * into bus->sysdata, take advantage of that to get the private data and simplify the code. Signed-off-by: Honghui Zhang

[PATCH v2 2/3] PCI: mediatek: take use of bus->sysdata to get host private data

2017-08-14 Thread honghui.zhang
From: Honghui Zhang Commit ae02a6dda285 ("PCI: mediatek: Add controller support for MT2712 and MT7622") has put the mtk_pcie * into bus->sysdata, take advantage of that to get the private data and simplify the code. Signed-off-by: Honghui Zhang --- drivers/pci/host/pcie-mediatek.c | 3 +-- 1

[PATCH] PCI: mediatek: add msi support for mt2712 and mt7622

2017-08-11 Thread honghui.zhang
From: Honghui Zhang MT2712 and MT7622's PCIe host controller support 32bit address MSI, and it connect to GIC with the same IRQ number of INTx IRQ, so it shares the same IRQ with INTx IRQ. This patch adds MSI support for MT2712 and MT7622. Signed-off-by: Honghui

[PATCH] PCI: mediatek: add msi support for mt2712 and mt7622

2017-08-11 Thread honghui.zhang
From: Honghui Zhang MT2712 and MT7622's PCIe host controller support 32bit address MSI, and it connect to GIC with the same IRQ number of INTx IRQ, so it shares the same IRQ with INTx IRQ. This patch adds MSI support for MT2712 and MT7622. Signed-off-by: Honghui Zhang ---

[PATCH v4 1/7] PCI: mediatek: Using readl_poll_timeout to wait Gen2 training

2017-08-10 Thread honghui.zhang
From: Ryder Lee Wait Gen2 training by using readl_poll_timeout() calls, and simplify the hardware assert logical by merge it into the new interface mtk_pcie_startup_port. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang

[PATCH v4 1/7] PCI: mediatek: Using readl_poll_timeout to wait Gen2 training

2017-08-10 Thread honghui.zhang
From: Ryder Lee Wait Gen2 training by using readl_poll_timeout() calls, and simplify the hardware assert logical by merge it into the new interface mtk_pcie_startup_port. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang --- drivers/pci/host/pcie-mediatek.c | 52

[PATCH v4 4/7] PCI: mediatek: switch to use platform_get_resource_byname()

2017-08-10 Thread honghui.zhang
From: Ryder Lee This is a transitional patch. We currently use platfarm_get_resource() for retrieving the IOMEM resources, but there might be some chips don't have subsys/shared registers part, which depends on platform design, and these will be introduced in further

[PATCH v4 4/7] PCI: mediatek: switch to use platform_get_resource_byname()

2017-08-10 Thread honghui.zhang
From: Ryder Lee This is a transitional patch. We currently use platfarm_get_resource() for retrieving the IOMEM resources, but there might be some chips don't have subsys/shared registers part, which depends on platform design, and these will be introduced in further patches. Switch this

[PATCH v4 5/7] dt-bindings: PCI: rename and cleanup MediaTek binding text

2017-08-10 Thread honghui.zhang
From: Ryder Lee In order to accommodate other SoC generations, this patch updates filename to make it more generic, regroups specific properties by SoCs, and removes redundant descriptions. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang

[PATCH v4 5/7] dt-bindings: PCI: rename and cleanup MediaTek binding text

2017-08-10 Thread honghui.zhang
From: Ryder Lee In order to accommodate other SoC generations, this patch updates filename to make it more generic, regroups specific properties by SoCs, and removes redundant descriptions. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang Acked-by: Rob Herring ---

[PATCH v4 3/7] PCI: mediatek: Add a structure to abstract the controller generations

2017-08-10 Thread honghui.zhang
From: Honghui Zhang Introduce a structure "mtk_pcie_soc" to abstract the differences between controller generations, and the .startup() hook is used to encapsulate some SoC-dependent related setting. In doing so, the common code which will be reused by future chips.

[PATCH v4 3/7] PCI: mediatek: Add a structure to abstract the controller generations

2017-08-10 Thread honghui.zhang
From: Honghui Zhang Introduce a structure "mtk_pcie_soc" to abstract the differences between controller generations, and the .startup() hook is used to encapsulate some SoC-dependent related setting. In doing so, the common code which will be reused by future chips. Signed-off-by: Ryder Lee

[PATCH v4 7/7] dt-bindings: PCI: add support for mt2712 and mt7622

2017-08-10 Thread honghui.zhang
From: Ryder Lee Add controller support for mt2712/mt7622 and update related properities. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang Acked-by: Rob Herring ---

[PATCH v4 7/7] dt-bindings: PCI: add support for mt2712 and mt7622

2017-08-10 Thread honghui.zhang
From: Ryder Lee Add controller support for mt2712/mt7622 and update related properities. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang Acked-by: Rob Herring --- .../devicetree/bindings/pci/mediatek-pcie.txt | 168 - 1 file changed, 161 insertions(+), 7

[PATCH v4 6/7] PCI: mediatek: Add controller support for mt2712 and mt7622

2017-08-10 Thread honghui.zhang
From: Ryder Lee MT2712 and MT7622 using a new IP block of Gen2 controller which has two root ports and shares the same probing flow with MT2701/MT7623. Both MT2712 and MT7622 have the same per-port control registers, but there are slight differences between them: MT7622

[PATCH v4 6/7] PCI: mediatek: Add controller support for mt2712 and mt7622

2017-08-10 Thread honghui.zhang
From: Ryder Lee MT2712 and MT7622 using a new IP block of Gen2 controller which has two root ports and shares the same probing flow with MT2701/MT7623. Both MT2712 and MT7622 have the same per-port control registers, but there are slight differences between them: MT7622 has more clocks than

[PATCH v4 2/7] PCI: mediatek: make the parameter and function names more accurate

2017-08-10 Thread honghui.zhang
From: Honghui Zhang Rename "port->index" to "port->slot" since the ports are hardwired at PCI_SLOT. Also rename "mtk_pcie_parse_ports" to "mtk_pcie_parse_port" since it parses one port each time. No functional change in this patch. Signed-off-by: Honghui Zhang

[PATCH v4 2/7] PCI: mediatek: make the parameter and function names more accurate

2017-08-10 Thread honghui.zhang
From: Honghui Zhang Rename "port->index" to "port->slot" since the ports are hardwired at PCI_SLOT. Also rename "mtk_pcie_parse_ports" to "mtk_pcie_parse_port" since it parses one port each time. No functional change in this patch. Signed-off-by: Honghui Zhang ---

[PATCH v4 0/7] PCI: MediaTek: Add host controller support for mt2712 and mt7622

2017-08-10 Thread honghui.zhang
From: Honghui Zhang MediaTek's PCIe host controller has two generation HWs, MT2712 and MT7622 using the new generation HW, which has two root ports. They share most probing flow with MT2701/MT7623. But the read/write config space logical is different. The per-port

[PATCH v4 0/7] PCI: MediaTek: Add host controller support for mt2712 and mt7622

2017-08-10 Thread honghui.zhang
From: Honghui Zhang MediaTek's PCIe host controller has two generation HWs, MT2712 and MT7622 using the new generation HW, which has two root ports. They share most probing flow with MT2701/MT7623. But the read/write config space logical is different. The per-port registers must be touched for

[PATCH v3 1/6] PCI: mediatek: Using readl_poll_timeout to wait Gen2 training

2017-08-04 Thread honghui.zhang
From: Ryder Lee Wait Gen2 training by using readl_poll_timeout() calls, and simplify the hardware assert logical by merge it into the new interface mtk_pcie_startup_ports. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang

[PATCH v3 1/6] PCI: mediatek: Using readl_poll_timeout to wait Gen2 training

2017-08-04 Thread honghui.zhang
From: Ryder Lee Wait Gen2 training by using readl_poll_timeout() calls, and simplify the hardware assert logical by merge it into the new interface mtk_pcie_startup_ports. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang --- drivers/pci/host/pcie-mediatek.c | 52

[PATCH v3 2/6] PCI: mediatek: Add a structure to abstract the controller generations

2017-08-04 Thread honghui.zhang
From: Honghui Zhang Introduce a structure "mtk_pcie_soc" to abstract the differences between controller generations, and the .startup() hook is used to encapsulate some SoC-dependent related setting. In doing so, the common code which will be reused by future chips.

[PATCH v3 2/6] PCI: mediatek: Add a structure to abstract the controller generations

2017-08-04 Thread honghui.zhang
From: Honghui Zhang Introduce a structure "mtk_pcie_soc" to abstract the differences between controller generations, and the .startup() hook is used to encapsulate some SoC-dependent related setting. In doing so, the common code which will be reused by future chips. Signed-off-by: Ryder Lee

[PATCH v3 6/6] dt-bindings: PCI: add support for new generation controller

2017-08-04 Thread honghui.zhang
From: Ryder Lee Add support for MediaTek new generation controller and update related properities. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang Acked-by: Rob Herring ---

[PATCH v3 6/6] dt-bindings: PCI: add support for new generation controller

2017-08-04 Thread honghui.zhang
From: Ryder Lee Add support for MediaTek new generation controller and update related properities. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang Acked-by: Rob Herring --- .../devicetree/bindings/pci/mediatek-pcie.txt | 168 - 1 file changed, 161

[PATCH v3 5/6] PCI: mediatek: Add new generation controller support

2017-08-04 Thread honghui.zhang
From: Ryder Lee MediaTek's PCIe host controller has two generation HWs, the new generation HW has two root ports, it shares most probing flow with the legacy controller. But the read/write config space logical is different from the legacy controller. The per-port register

[PATCH v3 5/6] PCI: mediatek: Add new generation controller support

2017-08-04 Thread honghui.zhang
From: Ryder Lee MediaTek's PCIe host controller has two generation HWs, the new generation HW has two root ports, it shares most probing flow with the legacy controller. But the read/write config space logical is different from the legacy controller. The per-port register must be touched for

[PATCH v3 4/6] dt-bindings: PCI: rename and cleanup MediaTek binding text

2017-08-04 Thread honghui.zhang
From: Ryder Lee In order to accommodate other SoC generations, this patch updates filename to make it more generic, regroups specific properties by SoCs, and removes redundant descriptions. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang

[PATCH v3 4/6] dt-bindings: PCI: rename and cleanup MediaTek binding text

2017-08-04 Thread honghui.zhang
From: Ryder Lee In order to accommodate other SoC generations, this patch updates filename to make it more generic, regroups specific properties by SoCs, and removes redundant descriptions. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang Acked-by: Rob Herring ---

[PATCH v3 3/6] PCI: mediatek: switch to use platform_get_resource_byname()

2017-08-04 Thread honghui.zhang
From: Ryder Lee This is a transitional patch. We currently use platfarm_get_resource() for retrieving the IOMEM resources, but there might be some chips don't have subsys/shared registers part, which depends on platform design, and these will be introduced in further

[PATCH v3 3/6] PCI: mediatek: switch to use platform_get_resource_byname()

2017-08-04 Thread honghui.zhang
From: Ryder Lee This is a transitional patch. We currently use platfarm_get_resource() for retrieving the IOMEM resources, but there might be some chips don't have subsys/shared registers part, which depends on platform design, and these will be introduced in further patches. Switch this

[PATCH v3 0/6] PCI: MediaTek: Add support for new generation host controller

2017-08-04 Thread honghui.zhang
From: Honghui Zhang MediaTek's PCIe host controller has two generation HWs, the new generation HW has two root ports, it shares most probing flow with the legacy controller. But the read/write config space logical is different from the legacy controller. The per-port

[PATCH v3 0/6] PCI: MediaTek: Add support for new generation host controller

2017-08-04 Thread honghui.zhang
From: Honghui Zhang MediaTek's PCIe host controller has two generation HWs, the new generation HW has two root ports, it shares most probing flow with the legacy controller. But the read/write config space logical is different from the legacy controller. The per-port register must be touched for

[PATCH v3 3/4] dt-bindings: mediatek: add descriptions for larbid

2017-08-03 Thread honghui.zhang
From: Honghui Zhang This patch add larbid descritptions for mediatek's gen1 smi larb hardware. Acked-by: Rob Herring Signed-off-by: Honghui Zhang --- .../bindings/memory-controllers/mediatek,smi-larb.txt | 15

[PATCH v3 3/4] dt-bindings: mediatek: add descriptions for larbid

2017-08-03 Thread honghui.zhang
From: Honghui Zhang This patch add larbid descritptions for mediatek's gen1 smi larb hardware. Acked-by: Rob Herring Signed-off-by: Honghui Zhang --- .../bindings/memory-controllers/mediatek,smi-larb.txt | 15 +++ 1 file changed, 15 insertions(+) diff --git

[PATCH v3 1/4] memory: mtk-smi: Use of_device_get_match_data helper

2017-08-03 Thread honghui.zhang
From: Honghui Zhang Replace custom code with generic helper to retrieve driver data. Signed-off-by: Honghui Zhang --- drivers/memory/mtk-smi.c | 14 ++ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git

[PATCH v3 4/4] arm: dts: mediatek: add larbid property for larb

2017-08-03 Thread honghui.zhang
From: Honghui Zhang Add mediatek's hardware id information for smi larb. Signed-off-by: Honghui Zhang --- arch/arm/boot/dts/mt2701.dtsi | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/boot/dts/mt2701.dtsi

[PATCH v3 4/4] arm: dts: mediatek: add larbid property for larb

2017-08-03 Thread honghui.zhang
From: Honghui Zhang Add mediatek's hardware id information for smi larb. Signed-off-by: Honghui Zhang --- arch/arm/boot/dts/mt2701.dtsi | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/boot/dts/mt2701.dtsi b/arch/arm/boot/dts/mt2701.dtsi index f1efdc6..d95bfe0 100644 ---

[PATCH v3 1/4] memory: mtk-smi: Use of_device_get_match_data helper

2017-08-03 Thread honghui.zhang
From: Honghui Zhang Replace custom code with generic helper to retrieve driver data. Signed-off-by: Honghui Zhang --- drivers/memory/mtk-smi.c | 14 ++ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/drivers/memory/mtk-smi.c b/drivers/memory/mtk-smi.c index

[PATCH v3 0/4] Add larbid init routine for mediatek's gen1 smi larb driver

2017-08-03 Thread honghui.zhang
From: Honghui Zhang Mediatek's gen1 smi need the hardware larb-id to identify the offset for the register which controls whether enable iommu for this larb. In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larbid was used without properly

[PATCH v3 0/4] Add larbid init routine for mediatek's gen1 smi larb driver

2017-08-03 Thread honghui.zhang
From: Honghui Zhang Mediatek's gen1 smi need the hardware larb-id to identify the offset for the register which controls whether enable iommu for this larb. In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larbid was used without properly initialized. This patchset

[PATCH v3 2/4] memory: mtk-smi: add larbid handle routine

2017-08-03 Thread honghui.zhang
From: Honghui Zhang In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larb->larbid was added but not initialized. Mediatek's gen1 smi need this hardware larbid information to get the register offset which controls whether enable iommu for

[PATCH v3 2/4] memory: mtk-smi: add larbid handle routine

2017-08-03 Thread honghui.zhang
From: Honghui Zhang In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larb->larbid was added but not initialized. Mediatek's gen1 smi need this hardware larbid information to get the register offset which controls whether enable iommu for this larb. This patch add the

[PATCH v2 2/3] dt-bindings: mediatek: add descriptions for larbid

2017-07-28 Thread honghui.zhang
From: Honghui Zhang This patch add larbid descritptions for mediatek's gen1 smi larb hardware. Signed-off-by: Honghui Zhang --- .../bindings/memory-controllers/mediatek,smi-larb.txt | 15 +++ 1 file changed, 15

[PATCH v2 1/3] memory: mtk-smi: add larbid handle routine

2017-07-28 Thread honghui.zhang
From: Honghui Zhang In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larb->larbid was added but not initialized. Mediatek's gen1 smi need this hardware larbid information to get the register offset which controls whether enable iommu for

[PATCH v2 2/3] dt-bindings: mediatek: add descriptions for larbid

2017-07-28 Thread honghui.zhang
From: Honghui Zhang This patch add larbid descritptions for mediatek's gen1 smi larb hardware. Signed-off-by: Honghui Zhang --- .../bindings/memory-controllers/mediatek,smi-larb.txt | 15 +++ 1 file changed, 15 insertions(+) diff --git

[PATCH v2 1/3] memory: mtk-smi: add larbid handle routine

2017-07-28 Thread honghui.zhang
From: Honghui Zhang In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larb->larbid was added but not initialized. Mediatek's gen1 smi need this hardware larbid information to get the register offset which controls whether enable iommu for this larb. This patch add the

[PATCH v2 3/3] arm: dts: mediatek: add larbid property for larb

2017-07-28 Thread honghui.zhang
From: Honghui Zhang Add mediatek's hardware id information for smi larb. Signed-off-by: Honghui Zhang --- arch/arm/boot/dts/mt2701.dtsi | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/boot/dts/mt2701.dtsi

[PATCH v2 3/3] arm: dts: mediatek: add larbid property for larb

2017-07-28 Thread honghui.zhang
From: Honghui Zhang Add mediatek's hardware id information for smi larb. Signed-off-by: Honghui Zhang --- arch/arm/boot/dts/mt2701.dtsi | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/boot/dts/mt2701.dtsi b/arch/arm/boot/dts/mt2701.dtsi index f1efdc6..2cddbec 100644 ---

[PATCH v2 0/3] Add larbid init routine for mediatek's gen1 smi larb driver

2017-07-28 Thread honghui.zhang
From: Honghui Zhang Mediatek's gen1 smi need the hardware larbid to identify the offset for the register which controls whether enable iommu for this larb. In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larbid was used without properly

[PATCH v2 0/3] Add larbid init routine for mediatek's gen1 smi larb driver

2017-07-28 Thread honghui.zhang
From: Honghui Zhang Mediatek's gen1 smi need the hardware larbid to identify the offset for the register which controls whether enable iommu for this larb. In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larbid was used without properly initialized. This patchset

[PATCH v2 5/5] dt-bindings: PCI: add support for new generation controller

2017-07-26 Thread honghui.zhang
From: Ryder Lee Add support for MediaTek new generation controller and update related properities. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang --- .../devicetree/bindings/pci/mediatek-pcie.txt | 168

[PATCH v2 5/5] dt-bindings: PCI: add support for new generation controller

2017-07-26 Thread honghui.zhang
From: Ryder Lee Add support for MediaTek new generation controller and update related properities. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang --- .../devicetree/bindings/pci/mediatek-pcie.txt | 168 - 1 file changed, 161 insertions(+), 7 deletions(-) diff

[PATCH v2 2/5] PCI: mediatek: switch to use platform_get_resource_byname()

2017-07-26 Thread honghui.zhang
From: Ryder Lee This is a transitional patch. We currently use platfarm_get_resource() for retrieving the IOMEM resources, but there might be some chips don't have subsys/shared registers part, which depends on platform design, and these will be introduced in further

[PATCH v2 2/5] PCI: mediatek: switch to use platform_get_resource_byname()

2017-07-26 Thread honghui.zhang
From: Ryder Lee This is a transitional patch. We currently use platfarm_get_resource() for retrieving the IOMEM resources, but there might be some chips don't have subsys/shared registers part, which depends on platform design, and these will be introduced in further patches. Switch this

[PATCH v2 5/5] dt-bindings: PCI: add support for new generation controller

2017-07-26 Thread honghui.zhang
From: Ryder Lee Add support for MediaTek new generation controller and update related properities. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang --- .../devicetree/bindings/pci/mediatek-pcie.txt | 168

[PATCH v2 5/5] dt-bindings: PCI: add support for new generation controller

2017-07-26 Thread honghui.zhang
From: Ryder Lee Add support for MediaTek new generation controller and update related properities. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang --- .../devicetree/bindings/pci/mediatek-pcie.txt | 168 - 1 file changed, 161 insertions(+), 7 deletions(-) diff

[PATCH v2 4/5] PCI: mediatek: Add new generation controller support

2017-07-26 Thread honghui.zhang
From: Ryder Lee Add support for new Gen2 controller which has two root ports and shares the probing flow with legacy controller. Currently this IP block can be found on MT7622/MT2712. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang

[PATCH v2 3/5] dt-bindings: PCI: rename and cleanup MediaTek binding text

2017-07-26 Thread honghui.zhang
From: Ryder Lee In order to accommodate other SoC generations, this patch updates filename to make it more generic, regroups specific properties by SoCs, and removes redundant descriptions. Signed-off-by: Ryder Lee ---

[PATCH v2 4/5] PCI: mediatek: Add new generation controller support

2017-07-26 Thread honghui.zhang
From: Ryder Lee Add support for new Gen2 controller which has two root ports and shares the probing flow with legacy controller. Currently this IP block can be found on MT7622/MT2712. Signed-off-by: Ryder Lee Signed-off-by: Honghui Zhang --- drivers/pci/host/Kconfig | 5 +-

[PATCH v2 3/5] dt-bindings: PCI: rename and cleanup MediaTek binding text

2017-07-26 Thread honghui.zhang
From: Ryder Lee In order to accommodate other SoC generations, this patch updates filename to make it more generic, regroups specific properties by SoCs, and removes redundant descriptions. Signed-off-by: Ryder Lee --- ...{mediatek,mt7623-pcie.txt => mediatek-pcie.txt} | 29

[PATCH v2 1/5] PCI: mediatek: Add a structure to abstract the controller generations

2017-07-26 Thread honghui.zhang
From: Ryder Lee Introduce a structure "mtk_pcie_soc" to abstract the differences between controller generations, and the .startup() hook is used to encapsulate some SoC-dependent related setting. In doing so, the common code which will be reused by future chips. In

[PATCH v2 1/5] PCI: mediatek: Add a structure to abstract the controller generations

2017-07-26 Thread honghui.zhang
From: Ryder Lee Introduce a structure "mtk_pcie_soc" to abstract the differences between controller generations, and the .startup() hook is used to encapsulate some SoC-dependent related setting. In doing so, the common code which will be reused by future chips. In addition, we change the

[PATCH v2 0/5] PCI: MediaTek: Add support for new generation host controller

2017-07-26 Thread honghui.zhang
From: Honghui Zhang MediaTek's PCIe host controller has two generation HWs, the new generation HW has two root ports, it shares most probing flow with the legacy controller. But the read/write config space logical is different from the lagacy controller. This patchset

[PATCH v2 0/5] PCI: MediaTek: Add support for new generation host controller

2017-07-26 Thread honghui.zhang
From: Honghui Zhang MediaTek's PCIe host controller has two generation HWs, the new generation HW has two root ports, it shares most probing flow with the legacy controller. But the read/write config space logical is different from the lagacy controller. This patchset abstract the common probing

[PATCH 0/3] Add larbid init routine for mediatek's gen1 smi larb driver

2017-07-26 Thread honghui.zhang
From: Honghui Zhang Mediatek's gen1 smi need the hardware larbid to identify the offset for the register which controls whether enable iommu for this larb. In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larbid was used without properly

[PATCH 0/3] Add larbid init routine for mediatek's gen1 smi larb driver

2017-07-26 Thread honghui.zhang
From: Honghui Zhang Mediatek's gen1 smi need the hardware larbid to identify the offset for the register which controls whether enable iommu for this larb. In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larbid was used without properly initialized. This patchset

[PATCH 3/3] arm: dts: mediatek: add larbid property for larb

2017-07-26 Thread honghui.zhang
From: Honghui Zhang Add mediatek's hardware id information for smi larb. Signed-off-by: Honghui Zhang --- arch/arm/boot/dts/mt2701.dtsi | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/boot/dts/mt2701.dtsi

[PATCH 1/3] memory: mtk-smi: add larbid init routine

2017-07-26 Thread honghui.zhang
From: Honghui Zhang In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larb->larbid was added but not initialized. Mediatek's gen1 smi need this hardware larbid information to get the register offset which controls whether enable iommu for

[PATCH 3/3] arm: dts: mediatek: add larbid property for larb

2017-07-26 Thread honghui.zhang
From: Honghui Zhang Add mediatek's hardware id information for smi larb. Signed-off-by: Honghui Zhang --- arch/arm/boot/dts/mt2701.dtsi | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/boot/dts/mt2701.dtsi b/arch/arm/boot/dts/mt2701.dtsi index f1efdc6..2cddbec 100644 ---

[PATCH 1/3] memory: mtk-smi: add larbid init routine

2017-07-26 Thread honghui.zhang
From: Honghui Zhang In the commit 3c8f4ad85c4b ("memory/mediatek: add support for mt2701"), the larb->larbid was added but not initialized. Mediatek's gen1 smi need this hardware larbid information to get the register offset which controls whether enable iommu for this larb. This patch add the

[PATCH 2/3] dt-bindings: mediatek: add descriptions for larbid

2017-07-26 Thread honghui.zhang
From: Honghui Zhang This patch add larbid descritptions for mediatek's gen1 smi larb hardware. Signed-off-by: Honghui Zhang --- .../bindings/memory-controllers/mediatek,smi-larb.txt | 15 +++ 1 file changed, 15

[PATCH 2/3] dt-bindings: mediatek: add descriptions for larbid

2017-07-26 Thread honghui.zhang
From: Honghui Zhang This patch add larbid descritptions for mediatek's gen1 smi larb hardware. Signed-off-by: Honghui Zhang --- .../bindings/memory-controllers/mediatek,smi-larb.txt | 15 +++ 1 file changed, 15 insertions(+) diff --git

[PATCH v2] memory: mtk-smi: Use of_device_get_match_data helper

2017-07-26 Thread honghui.zhang
From: Honghui Zhang Replace custom code with generic helper to retrieve driver data. Signed-off-by: Honghui Zhang --- drivers/memory/mtk-smi.c | 14 ++ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git

[PATCH v2] memory: mtk-smi: Use of_device_get_match_data helper

2017-07-26 Thread honghui.zhang
From: Honghui Zhang Replace custom code with generic helper to retrieve driver data. Signed-off-by: Honghui Zhang --- drivers/memory/mtk-smi.c | 14 ++ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/drivers/memory/mtk-smi.c b/drivers/memory/mtk-smi.c index

[PATCH] memory: mtk-smi: Use of_device_get_match_data helper

2017-07-26 Thread honghui.zhang
From: Honghui Zhang Replace custom code with generic helper to retrieve driver data. Signed-off-by: Honghui Zhang --- drivers/memory/mtk-smi.c | 18 -- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git

[PATCH] memory: mtk-smi: Use of_device_get_match_data helper

2017-07-26 Thread honghui.zhang
From: Honghui Zhang Replace custom code with generic helper to retrieve driver data. Signed-off-by: Honghui Zhang --- drivers/memory/mtk-smi.c | 18 -- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/drivers/memory/mtk-smi.c b/drivers/memory/mtk-smi.c index

[PATCH] memory: mtk-smi: Use of_device_get_match_data helper

2017-07-26 Thread honghui.zhang
From: Honghui Zhang Replace custom code with generic helper to retrieve driver data. Signed-off-by: Honghui Zhang --- drivers/memory/mtk-smi.c | 14 ++ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git

<    1   2   3   4   >