Add eMMC support to k3-am654-idk-linux-demo inmate which requires several device tree changes, and addition memory mappings open
Signed-off-by: Matt Ranostay <[email protected]> --- configs/arm64/dts/inmate-k3-am654-idk.dts | 36 +++++++++++++++++++++-- configs/arm64/k3-am654-idk-linux-demo.c | 18 ++++++++++-- 2 files changed, 50 insertions(+), 4 deletions(-) diff --git a/configs/arm64/dts/inmate-k3-am654-idk.dts b/configs/arm64/dts/inmate-k3-am654-idk.dts index 8e5066d3..a419d8d5 100644 --- a/configs/arm64/dts/inmate-k3-am654-idk.dts +++ b/configs/arm64/dts/inmate-k3-am654-idk.dts @@ -64,6 +64,30 @@ <GIC_PPI 10 IRQ_TYPE_LEVEL_LOW>; /* cnthpirq */ }; + sdhci0: mmc@4f80000 { + compatible = "ti,am654-sdhci-5.1"; + reg = <0x0 0x4f80000 0x0 0x260>, <0x0 0x4f90000 0x0 0x134>; + power-domains = <&k3_pds 47 1>; + clocks = <&k3_clks 47 0>, <&k3_clks 47 1>; + clock-names = "clk_ahb", "clk_xin"; + interrupts = <GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>; + mmc-ddr-1_8v; + mmc-hs200-1_8v; + ti,otap-del-sel-legacy = <0x0>; + ti,otap-del-sel-mmc-hs = <0x0>; + ti,otap-del-sel-sd-hs = <0x0>; + ti,otap-del-sel-sdr12 = <0x0>; + ti,otap-del-sel-sdr25 = <0x0>; + ti,otap-del-sel-sdr50 = <0x8>; + ti,otap-del-sel-sdr104 = <0x7>; + ti,otap-del-sel-ddr50 = <0x5>; + ti,otap-del-sel-ddr52 = <0x5>; + ti,otap-del-sel-hs200 = <0x5>; + ti,otap-del-sel-hs400 = <0x0>; + ti,trm-icp = <0x8>; + dma-coherent; + }; + cbass_main: interconnect@100000 { compatible = "simple-bus"; #address-cells = <2>; @@ -122,7 +146,7 @@ interrupts = <GIC_SPI 565 IRQ_TYPE_LEVEL_HIGH>; clock-frequency = <96000000>; current-speed = <115200>; - power-domains = <&k3_pds 149>; + power-domains = <&k3_pds 149 1>; }; cbass_wakeup: interconnect@42040000 { @@ -145,7 +169,7 @@ k3_pds: power-controller { compatible = "ti,sci-pm-domain"; - #power-domain-cells = <1>; + #power-domain-cells = <2>; }; k3_clks: clocks { @@ -162,3 +186,11 @@ }; }; }; + +&sdhci0 { + /* eMMC */ + non-removable; + ti,driver-strength-ohm = <50>; + bus-width = <8>; + disable-wp; +}; diff --git a/configs/arm64/k3-am654-idk-linux-demo.c b/configs/arm64/k3-am654-idk-linux-demo.c index d03fd4cd..4fc23e0b 100644 --- a/configs/arm64/k3-am654-idk-linux-demo.c +++ b/configs/arm64/k3-am654-idk-linux-demo.c @@ -23,7 +23,7 @@ struct { struct jailhouse_cell_desc cell; __u64 cpus[1]; - struct jailhouse_memory mem_regions[12]; + struct jailhouse_memory mem_regions[13]; struct jailhouse_irqchip irqchips[3]; struct jailhouse_pci_device pci_devices[1]; } __attribute__((packed)) config = { @@ -79,6 +79,20 @@ struct { .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE | JAILHOUSE_MEM_IO, }, + /* sdhci0 */ { + .phys_start = 0x4f80000, + .virt_start = 0x4f80000, + .size = 0x1000, + .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE | + JAILHOUSE_MEM_IO, + }, + /* sdhci0 */ { + .phys_start = 0x4f90000, + .virt_start = 0x4f90000, + .size = 0x1000, + .flags = JAILHOUSE_MEM_READ | JAILHOUSE_MEM_WRITE | + JAILHOUSE_MEM_IO, + }, /* main sproxy target_data host_id=A53_3 */ { .phys_start = 0x3240f000, .virt_start = 0x3240f000, @@ -120,7 +134,7 @@ struct { .address = 0x01800000, .pin_base = 160, .pin_bitmap = { - 1 << (190 - 160), 0x0, 0x00, 0, + 1 << (168 - 160) | 1 << (190 - 160), 0x00, 0x00, 0, }, }, { -- 2.25.1 -- You received this message because you are subscribed to the Google Groups "Jailhouse" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jailhouse-dev/20220304021615.2862-2-mranostay%40ti.com.
