diff mbox

[v3,11/12] arm64: dts: marvell: add sdhci support for Armada 7K/8K

Message ID 923c97f32a828b579756bf86946689ed54a0a174.1481279228.git-series.gregory.clement@free-electrons.com (mailing list archive)
State New, archived
Headers show

Commit Message

Gregory CLEMENT Dec. 9, 2016, 10:30 a.m. UTC
Also enable it on the Armada 7040 DB board

Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
---
 arch/arm64/boot/dts/marvell/armada-7040-db.dts |  7 +++++++
 arch/arm64/boot/dts/marvell/armada-ap806.dtsi  |  9 +++++++++
 2 files changed, 16 insertions(+)

Comments

Russell King (Oracle) Dec. 9, 2016, 8:07 p.m. UTC | #1
On Fri, Dec 09, 2016 at 11:30:07AM +0100, Gregory CLEMENT wrote:
> Also enable it on the Armada 7040 DB board
> 
> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com>

Hi,

Can this also be added to the cp110 on the 7k/8k SoCs as well, or does
it rely on other unmerged support?

Thanks.
Gregory CLEMENT Dec. 12, 2016, 4:37 p.m. UTC | #2
Hi Russell King,
 
 On ven., déc. 09 2016, Russell King - ARM Linux <linux@armlinux.org.uk> wrote:

> On Fri, Dec 09, 2016 at 11:30:07AM +0100, Gregory CLEMENT wrote:
>> Also enable it on the Armada 7040 DB board
>> 
>> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
>
> Hi,
>
> Can this also be added to the cp110 on the 7k/8k SoCs as well, or does
> it rely on other unmerged support?

I did not add this one because until now I had not the hardware setup
available to test it.

But at least I can add the ressources in the device tree and now I can
test it partially.

Gregory

>
> Thanks.
>
> -- 
> RMK's Patch system: http://www.armlinux.org.uk/developer/patches/
> FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up
> according to speedtest.net.
Russell King (Oracle) Dec. 12, 2016, 7:16 p.m. UTC | #3
On Mon, Dec 12, 2016 at 05:37:56PM +0100, Gregory CLEMENT wrote:
> Hi Russell King,
>  
>  On ven., déc. 09 2016, Russell King - ARM Linux <linux@armlinux.org.uk> wrote:
> 
> > On Fri, Dec 09, 2016 at 11:30:07AM +0100, Gregory CLEMENT wrote:
> >> Also enable it on the Armada 7040 DB board
> >> 
> >> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
> >
> > Hi,
> >
> > Can this also be added to the cp110 on the 7k/8k SoCs as well, or does
> > it rely on other unmerged support?
> 
> I did not add this one because until now I had not the hardware setup
> available to test it.
> 
> But at least I can add the ressources in the device tree and now I can
> test it partially.

There's another option: add the DT resources in a separate patch, send
it out for someone else to test.  When it comes back with a tested-by,
then it can be included along with the rest of the patch set.

I'd send something, but I don't know what the GIC interrupt number
would be without using the CP110's ICU (which isn't supported in
mainline yet.)  I've already tested your previous patch set (along with
ICU support + needed DT bits) on the SR Macchiatobin board... it seems
to work fine.
Thomas Petazzoni Dec. 12, 2016, 8:18 p.m. UTC | #4
Hello,

On Mon, 12 Dec 2016 19:16:51 +0000, Russell King - ARM Linux wrote:

> I'd send something, but I don't know what the GIC interrupt number
> would be without using the CP110's ICU (which isn't supported in
> mainline yet.)

For now, mainline relies on a static mapping of CP interrupts to GIC
interrupts, via an ICU configuration done in ATF. It's pretty
straightforward to figure out the CP interrupts to GIC interrupt
mapping if you have access to the ATF source code. If you don't, I can
provide the necessary details.

Best regards,

Thomas
Marcin Wojtas Dec. 12, 2016, 9:18 p.m. UTC | #5
Hi Gregory,

2016-12-12 20:16 GMT+01:00 Russell King - ARM Linux <linux@armlinux.org.uk>:
> On Mon, Dec 12, 2016 at 05:37:56PM +0100, Gregory CLEMENT wrote:
>> Hi Russell King,
>>
>>  On ven., déc. 09 2016, Russell King - ARM Linux <linux@armlinux.org.uk> wrote:
>>
>> > On Fri, Dec 09, 2016 at 11:30:07AM +0100, Gregory CLEMENT wrote:
>> >> Also enable it on the Armada 7040 DB board
>> >>
>> >> Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
>> >
>> > Hi,
>> >
>> > Can this also be added to the cp110 on the 7k/8k SoCs as well, or does
>> > it rely on other unmerged support?
>>
>> I did not add this one because until now I had not the hardware setup
>> available to test it.
>>
>> But at least I can add the ressources in the device tree and now I can
>> test it partially.
>
> There's another option: add the DT resources in a separate patch, send
> it out for someone else to test.  When it comes back with a tested-by,
> then it can be included along with the rest of the patch set.

I work on A7040-DB with SD slot from AP and CP eMMC. If you have the
board, you can use eMMC module from A3720-DB and plug it to CON11.
Some small soldering may be required. Anyway, you can also just let me
test it:)

Best regards,
Marcin
diff mbox

Patch

diff --git a/arch/arm64/boot/dts/marvell/armada-7040-db.dts b/arch/arm64/boot/dts/marvell/armada-7040-db.dts
index 070b589680c5..f7f978a12a49 100644
--- a/arch/arm64/boot/dts/marvell/armada-7040-db.dts
+++ b/arch/arm64/boot/dts/marvell/armada-7040-db.dts
@@ -146,3 +146,10 @@ 
 &cpm_usb3_1 {
 	status = "okay";
 };
+
+&sdhci0 {
+	status = "okay";
+	bus-width = <4>;
+	no-1-8-v;
+	non-removable;
+};
diff --git a/arch/arm64/boot/dts/marvell/armada-ap806.dtsi b/arch/arm64/boot/dts/marvell/armada-ap806.dtsi
index 7b6136182ad0..e812fb59fb80 100644
--- a/arch/arm64/boot/dts/marvell/armada-ap806.dtsi
+++ b/arch/arm64/boot/dts/marvell/armada-ap806.dtsi
@@ -229,6 +229,15 @@ 
 
 			};
 
+			sdhci0: sdhci@6e0000 {
+				compatible = "marvell,armada-7000-sdhci";
+				reg = <0x6e0000 0x300>;
+				interrupts = <GIC_SPI 16 IRQ_TYPE_LEVEL_HIGH>;
+				clock-names = "core";
+				clocks = <&cpm_syscon0 1 4>;
+				status = "disabled";
+			};
+
 			ap_syscon: system-controller@6f4000 {
 				compatible = "marvell,ap806-system-controller",
 					     "syscon";