qcom: ipq40xx: Add basic board/dts support for IPQ40XX SoC
Subsystems (6)
PATCH v3 1/1 qcom: ipq40xx: Add basic board/dts support for IPQ40XX SoC
Add initial dts files and SoC support for IPQ40XX
---
Changes in v2:
- Added devicetree bindings documentation
Changes in v3:
- Split 'gcnt' into a separate patch
- Added the new entries to Makefiles, Kconfig & board.c in sorted order
- Used "qcom,ipq40xx" instead of "qcom,ipq40xx-r3pc" in board.c
Documentation/devicetree/bindings/qcom.txt | 16 ++++++ arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts | 33 ++++++++++++ arch/arm/boot/dts/qcom-ipq40xx.dtsi | 81 ++++++++++++++++++++++++++++++ arch/arm/configs/ipq_defconfig | 1 + arch/arm/mach-qcom/Kconfig | 4 ++ arch/arm/mach-qcom/board.c | 1 + 7 files changed, 137 insertions(+) create mode 100644 Documentation/devicetree/bindings/qcom.txt create mode 100644 arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts create mode 100644 arch/arm/boot/dts/qcom-ipq40xx.dtsi
Documentation/devicetree/bindings/qcom.txt new file +16 -0
@@ -0,0 +1,16 @@ +Qualcomm IPQ device tree bindings +--------------------------------- + +System on Chip + +Device tree must specify which SoC it uses, with one of the +following compatible strings + + "qcom,ipq40xx" + +Platform + +Device tree must specify which Platform it uses, with one of the +following compatible strings + + "qcom,ipq40xx-r3pc"
arch/arm/boot/dts/Makefile +1 -0
@@ -474,6 +474,7 @@ dtb-$(CONFIG_ARCH_QCOM) += \ qcom-apq8074-dragonboard.dtb \ qcom-apq8084-ifc6540.dtb \ qcom-apq8084-mtp.dtb \ + qcom-ipq40xx-r3pc.dtb \ qcom-ipq8064-ap148.dtb \ qcom-msm8660-surf.dtb \ qcom-msm8960-cdp.dtb \
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +33 -0
@@ -0,0 +1,33 @@ +/* Copyright (c) 2014, The Linux Foundation. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 and + * only version 2 as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#include "qcom-ipq40xx.dtsi" + +/ { + model = "Qualcomm Technologies, Inc. IPQ40XX R3PC"; + compatible = "qcom,ipq40xx-r3pc", "qcom,ipq40xx"; + + memory { + device_type = "memory"; + reg = <0x80000000 0x20000000>; /* 512MB */ + }; + + chosen { + bootargs = "root=/dev/ram rw init=/init console=ttyMSM0,115200n8 initrd=0x82000000,0x000E2246"; + }; + + soc { + serial at 78b0000 { + status = "ok"; + }; + }; +};
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +81 -0
81 lines not on this page · raw message
arch/arm/configs/ipq_defconfig +1 -0
@@ -21,6 +21,7 @@ CONFIG_ARCH_QCOM=y CONFIG_ARCH_MSM8X60=y CONFIG_ARCH_MSM8960=y CONFIG_ARCH_MSM8974=y +CONFIG_ARCH_IPQ40XX=y CONFIG_ARCH_IPQ8064=y CONFIG_SMP=y CONFIG_PREEMPT=y
arch/arm/mach-qcom/Kconfig +4 -0
@@ -22,6 +22,10 @@ config ARCH_MSM8974 bool "Enable support for MSM8974" select HAVE_ARM_ARCH_TIMER +config ARCH_IPQ40XX + bool "Enable support for IPQ40XX" + select HAVE_ARM_ARCH_TIMER + config ARCH_IPQ8064 bool "Enable support for IPQ806x" select CLKSRC_QCOM
arch/arm/mach-qcom/board.c +1 -0
@@ -18,6 +18,7 @@ static const char * const qcom_dt_match[] __initconst = {"qcom,apq8064" ,"qcom,apq8074-dragonboard" ,"qcom,apq8084" , +"qcom,ipq40xx" ,"qcom,ipq8062" ,"qcom,ipq8064" , "qcom,msm8660-surf",
Signature · 1 line
1.8.2.1
Quoted 2 lines · Varadarajan Narayanan
Add initial dts files and SoC support for IPQ40XX
So far we haven't added any Xs in the model names for our SoC support. Even for IPQ806X, we have it as IPQ8064 as the config name with IPQ806x in the help text because there's IPQ8062 out there. So I guess it should be IPQ4019 or something?
Quoted 14 lines
Signed-off-by Varadarajan Narayanan <[email protected]>---
Documentation/devicetree/bindings/qcom.txt new file +6
-0@@ -0,0 +1,16 @@ +Qualcomm IPQ device tree bindings +--------------------------------- + +System on Chip + +Device tree must specify which SoC it uses, with one of the
Documentation/devicetree/bindings/qcom.txt line 16
Quoted 10 lines
Documentation/devicetree/bindings/qcom.txt new file +10
-0+following compatible strings + + "qcom,ipq40xx" + +Platform + +Device tree must specify which Platform it uses, with one of the +following compatible strings + + "qcom,ipq40xx-r3pc"
This file is not complete and I don't see any other silicon vendors doing this, so please drop the entire file.
Quoted 12 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +6
-0@@ -0,0 +1,33 @@ +/* Copyright (c) 2014, The Linux Foundation. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 and + * only version 2 as published by the Free Software Foundation. + *
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 16
Quoted 10 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +10
-0+ * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#include "qcom-ipq40xx.dtsi" + +/ { + model = "Qualcomm Technologies, Inc. IPQ40XX R3PC";
Same here, we should know what model number is on the board.
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 22
Quoted 6 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +6
-0+ compatible = "qcom,ipq40xx-r3pc", "qcom,ipq40xx"; + + memory { + device_type = "memory"; + reg = <0x80000000 0x20000000>; /* 512MB */ + };
Doesn't the bootloader fill the memory node for us? Why do we need this?
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 26
Quoted 4 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +4
-0+ + chosen { + bootargs = "root=/dev/ram rw init=/init console=ttyMSM0,115200n8 initrd=0x82000000,0x000E2246"; + };
Please don't add bootargs. Use stdout-path for the console part and everything else should be done by the bootloader or is the defaults.
Quoted 23 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +7
-0+ + soc { + serial at 78b0000 { + status = "ok"; + }; + }; +};arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +10
-0@@ -0,0 +1,81 @@ +/* + * Copyright (c) 2014, The Linux Foundation. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 and + * only version 2 as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 20
Quoted 10 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +10
-0+ * GNU General Public License for more details. + */ + +/dts-v1/; + +#include "skeleton.dtsi" + +/ { + model = "Qualcomm Technologies, Inc. IPQ40XX"; + compatible = "qcom,ipq40xx";
These two should also be specific and drop the Xs. Same goes for the file name.
Quoted 35 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +35
-0+ interrupt-parent = <&intc>; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + cpu at 0 { + device_type = "cpu"; + compatible = "arm,cortex-a7"; + reg = <0x0>; + }; + + cpu at 1 { + device_type = "cpu"; + compatible = "arm,cortex-a7"; + reg = <0x1>; + }; + + cpu at 2 { + device_type = "cpu"; + compatible = "arm,cortex-a7"; + reg = <0x2>; + }; + + cpu at 3 { + device_type = "cpu"; + compatible = "arm,cortex-a7"; + reg = <0x3>; + }; + }; + + soc { + #address-cells = <1>; + #size-cells = <1>; + ranges; + compatible = "simple-bus";
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 65
Quoted 10 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +10
-0+ + intc: interrupt-controller at b000000 { + compatible = "qcom,msm-qgic2"; + interrupt-controller; + #interrupt-cells = <3>; + reg = <0x0b000000 0x1000>, + <0x0b002000 0x1000>; + }; + + timer {
This node is not a child of the SoC node. It should be at the root level.
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 71
Quoted 6 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +6
-0+ compatible = "arm,armv7-timer"; + interrupts = <1 2 0xf08>, + <1 3 0xf08>, + <1 4 0xf08>, + <1 1 0xf08>; + clock-frequency = <20833333>;
Drop this clock-frequency part if you can. The hardware should properly report the frequency.
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 78
Quoted 7 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +7
-0+ }; + + serial at 78b0000 { + compatible = "qcom,msm-uartdm-v1.4", "qcom,msm-uartdm"; + reg = <0x78b0000 0x200>; + interrupts = <0 108 0>; + status = "disabled";
Don't you need some clocks here?
Quoted 8 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +3
-0+ }; + }; +};arch/arm/configs/ipq_defconfig +0
-0
arch/arm/configs/ipq_defconfig CONFIG_ARCH_QCOM=y · line 27
Quoted 7 lines
arch/arm/configs/ipq_defconfig +1
-0@@ -21,6 +21,7 @@ CONFIG_ARCH_QCOM=y CONFIG_ARCH_MSM8X60=y CONFIG_ARCH_MSM8960=y CONFIG_ARCH_MSM8974=y +CONFIG_ARCH_IPQ40XX=y CONFIG_ARCH_IPQ8064=y CONFIG_SMP=y CONFIG_PREEMPT=y
This hunk should be in a separate patch.
Quoted 21 lines
arch/arm/mach-qcom/Kconfig +4
-0@@ -22,6 +22,10 @@ config ARCH_MSM8974 bool "Enable support for MSM8974" select HAVE_ARM_ARCH_TIMER +config ARCH_IPQ40XX + bool "Enable support for IPQ40XX" + select HAVE_ARM_ARCH_TIMER + config ARCH_IPQ8064 bool "Enable support for IPQ806x" select CLKSRC_QCOMarch/arm/mach-qcom/board.c +0
-0
arch/arm/mach-qcom/board.c static const char * const qcom_dt_match[] __initconst = { · line 24
Quoted 7 lines
arch/arm/mach-qcom/board.c +1
-0@@ -18,6 +18,7 @@ static const char * const qcom_dt_match[] __initconst = {"qcom,apq8064" ,"qcom,apq8074-dragonboard" ,"qcom,apq8084" , +"qcom,ipq40xx" ,"qcom,ipq8062" ,"qcom,ipq8064" , "qcom,msm8660-surf",
And these two should also go as a separate patch.
Signature · 2 lines
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project
Quoted 8 lines · Stephen Boyd
Quoted 2 lines · Varadarajan Narayanan
Add initial dts files and SoC support for IPQ40XX
So far we haven't added any Xs in the model names for our SoC support. Even for IPQ806X, we have it as IPQ8064 as the config name with IPQ806x in the help text because there's IPQ8062 out there. So I guess it should be IPQ4019 or something?
Will rename it as IPQ4019
Quoted 19 lines
Quoted 19 lines
Signed-off-by Varadarajan Narayanan <[email protected]>---
Documentation/devicetree/bindings/qcom.txt new file +11
-0@@ -0,0 +1,16 @@ +Qualcomm IPQ device tree bindings +--------------------------------- + +System on Chip + +Device tree must specify which SoC it uses, with one of the +following compatible strings + + "qcom,ipq40xx" + +Platform
Quoted 8 lines
Documentation/devicetree/bindings/qcom.txt line 16
Quoted 5 lines
Documentation/devicetree/bindings/qcom.txt new file +5
-0+ +Device tree must specify which Platform it uses, with one of the +following compatible strings + + "qcom,ipq40xx-r3pc"This file is not complete and I don't see any other silicon vendors doing this, so please drop the entire file.
Ok.
Quoted 16 lines
Quoted 16 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +10
-0@@ -0,0 +1,33 @@ +/* Copyright (c) 2014, The Linux Foundation. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 and + * only version 2 as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details.
Quoted 8 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 16
Quoted 6 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +6
-0+ */ + +#include "qcom-ipq40xx.dtsi" + +/ { + model = "Qualcomm Technologies, Inc. IPQ40XX R3PC";Same here, we should know what model number is on the board.
Ok.
Quoted 10 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 22
Quoted 6 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +6
-0+ compatible = "qcom,ipq40xx-r3pc", "qcom,ipq40xx"; + + memory { + device_type = "memory"; + reg = <0x80000000 0x20000000>; /* 512MB */ + };Doesn't the bootloader fill the memory node for us? Why do we need this?
Quoted 8 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 26
Quoted 4 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +4
-0+ + chosen { + bootargs = "root=/dev/ram rw init=/init console=ttyMSM0,115200n8 initrd=0x82000000,0x000E2246"; + };Please don't add bootargs. Use stdout-path for the console part and everything else should be done by the bootloader or is the defaults.
Since this is for the emulation platform, we don't have the bootloader.
Quoted 28 lines
Quoted 28 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +7
-0+ + soc { + serial at 78b0000 { + status = "ok"; + }; + }; +};arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +15
-0@@ -0,0 +1,81 @@ +/* + * Copyright (c) 2014, The Linux Foundation. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 and + * only version 2 as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +/dts-v1/; +
Quoted 8 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 20
Quoted 5 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +5
-0+#include "skeleton.dtsi" + +/ { + model = "Qualcomm Technologies, Inc. IPQ40XX"; + compatible = "qcom,ipq40xx";These two should also be specific and drop the Xs. Same goes for the file name.
Ok.
Quoted 40 lines
Quoted 40 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +40
-0+ interrupt-parent = <&intc>; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + cpu at 0 { + device_type = "cpu"; + compatible = "arm,cortex-a7"; + reg = <0x0>; + }; + + cpu at 1 { + device_type = "cpu"; + compatible = "arm,cortex-a7"; + reg = <0x1>; + }; + + cpu at 2 { + device_type = "cpu"; + compatible = "arm,cortex-a7"; + reg = <0x2>; + }; + + cpu at 3 { + device_type = "cpu"; + compatible = "arm,cortex-a7"; + reg = <0x3>; + }; + }; + + soc { + #address-cells = <1>; + #size-cells = <1>; + ranges; + compatible = "simple-bus"; + + intc: interrupt-controller at b000000 { + compatible = "qcom,msm-qgic2"; + interrupt-controller; + #interrupt-cells = <3>;
Quoted 8 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 65
Quoted 5 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +5
-0+ reg = <0x0b000000 0x1000>, + <0x0b002000 0x1000>; + }; + + timer {This node is not a child of the SoC node. It should be at the root level.
Ok.
Quoted 9 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 71
Quoted 6 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +6
-0+ compatible = "arm,armv7-timer"; + interrupts = <1 2 0xf08>, + <1 3 0xf08>, + <1 4 0xf08>, + <1 1 0xf08>; + clock-frequency = <20833333>;Drop this clock-frequency part if you can. The hardware should properly report the frequency.
Cannot drop this. This is the ref-clock frequency. For the chip it is 48MHz, for emulation is ~20MHz. Similar to
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/arch/arm/boot/dts/qcom-msm8974.dtsi#n89
Quoted 9 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 78
Quoted 7 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +7
-0+ }; + + serial at 78b0000 { + compatible = "qcom,msm-uartdm-v1.4", "qcom,msm-uartdm"; + reg = <0x78b0000 0x200>; + interrupts = <0 108 0>; + status = "disabled";Don't you need some clocks here?
Yes, will get updated in subsequent patches.
Quoted 9 lines
Quoted 9 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +3
-0+ }; + }; +};arch/arm/configs/ipq_defconfig +0
-0@@ -21,6 +21,7 @@ CONFIG_ARCH_QCOM=y CONFIG_ARCH_MSM8X60=y
Quoted 8 lines
arch/arm/configs/ipq_defconfig CONFIG_ARCH_QCOM=y · line 27
Quoted 6 lines
arch/arm/configs/ipq_defconfig +1
-0CONFIG_ARCH_MSM8960=y CONFIG_ARCH_MSM8974=y +CONFIG_ARCH_IPQ40XX=y CONFIG_ARCH_IPQ8064=y CONFIG_SMP=y CONFIG_PREEMPT=yThis hunk should be in a separate patch.
Ok.
Quoted 22 lines
Quoted 22 lines
arch/arm/mach-qcom/Kconfig +4
-0@@ -22,6 +22,10 @@ config ARCH_MSM8974 bool "Enable support for MSM8974" select HAVE_ARM_ARCH_TIMER +config ARCH_IPQ40XX + bool "Enable support for IPQ40XX" + select HAVE_ARM_ARCH_TIMER + config ARCH_IPQ8064 bool "Enable support for IPQ806x" select CLKSRC_QCOMarch/arm/mach-qcom/board.c +0
-0@@ -18,6 +18,7 @@ static const char * const qcom_dt_match[] __initconst = {"qcom,apq8064" , "qcom,apq8074-dragonboard",
Quoted 8 lines
arch/arm/mach-qcom/board.c static const char * const qcom_dt_match[] __initconst = { · line 24
Quoted 6 lines
arch/arm/mach-qcom/board.c +1
-0"qcom,apq8084" , +"qcom,ipq40xx" ,"qcom,ipq8062" ,"qcom,ipq8064" , "qcom,msm8660-surf",And these two should also go as a separate patch.
Ok.
Thanks
Varada
Quoted 9 lines
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel at lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Quoted 22 lines · Varadarajan Narayanan
Quoted 12 lines · Stephen Boyd
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 22
Quoted 6 lines · Varadarajan Narayanan
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +6
-0+ compatible = "qcom,ipq40xx-r3pc", "qcom,ipq40xx"; + + memory { + device_type = "memory"; + reg = <0x80000000 0x20000000>; /* 512MB */ + };Doesn't the bootloader fill the memory node for us? Why do we need this?
Quoted 8 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 26
Quoted 4 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +4
-0+ + chosen { + bootargs = "root=/dev/ram rw init=/init console=ttyMSM0,115200n8 initrd=0x82000000,0x000E2246"; + };Please don't add bootargs. Use stdout-path for the console part and everything else should be done by the bootloader or is the defaults.
Quoted 1 line
Since this is for the emulation platform, we don't have the bootloader.
Why are we upstreaming an emulation platform?
I assume you have some sort of scripts or something to load the kernel image into the emulator, so those scripts could go and modify the dtb in place to populate the initrd and commandline. If you need pointers on that feel free to contact me directly.
Quoted 11 lines
Quoted 10 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 71
Quoted 7 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +6
-0+ compatible = "arm,armv7-timer"; + interrupts = <1 2 0xf08>, + <1 3 0xf08>, + <1 4 0xf08>, + <1 1 0xf08>; + clock-frequency = <20833333>;Drop this clock-frequency part if you can. The hardware should properly report the frequency.
Quoted 3 lines
Cannot drop this. This is the ref-clock frequency. For the chip it is 48MHz, for emulation is ~20MHz. Similar to
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/arch/arm/boot/dts/qcom-msm8974.dtsi#n89
And the hardware is not emulated properly to report the actual frequency that the timer is running at? That's sad.
At the least, this should be in the board specific dtsi file instead of the SoC specific file, because it's a board quirk.
Signature · 2 lines
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project
Quoted 23 lines · Stephen Boyd
Quoted 22 lines · Varadarajan Narayanan
Quoted 20 lines · Stephen Boyd
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 22
Quoted 6 lines · Varadarajan Narayanan
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +6
-0+ compatible = "qcom,ipq40xx-r3pc", "qcom,ipq40xx"; + + memory { + device_type = "memory"; + reg = <0x80000000 0x20000000>; /* 512MB */ + };Doesn't the bootloader fill the memory node for us? Why do we need this?
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts line 26
Quoted 4 lines
arch/arm/boot/dts/qcom-ipq40xx-r3pc.dts new file +4
-0+ + chosen { + bootargs = "root=/dev/ram rw init=/init console=ttyMSM0,115200n8 initrd=0x82000000,0x000E2246"; + };Please don't add bootargs. Use stdout-path for the console part and everything else should be done by the bootloader or is the defaults.
Quoted 3 lines
Quoted 1 line
Since this is for the emulation platform, we don't have the bootloader.
Why are we upstreaming an emulation platform?
Ok, will skip this.
-Varada
Quoted 29 lines
I assume you have some sort of scripts or something to load the kernel image into the emulator, so those scripts could go and modify the dtb in place to populate the initrd and commandline. If you need pointers on that feel free to contact me directly.
Quoted 11 lines
Quoted 10 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi line 71
Quoted 7 lines
arch/arm/boot/dts/qcom-ipq40xx.dtsi new file +6
-0+ compatible = "arm,armv7-timer"; + interrupts = <1 2 0xf08>, + <1 3 0xf08>, + <1 4 0xf08>, + <1 1 0xf08>; + clock-frequency = <20833333>;Drop this clock-frequency part if you can. The hardware should properly report the frequency.
Quoted 3 lines
Cannot drop this. This is the ref-clock frequency. For the chip it is 48MHz, for emulation is ~20MHz. Similar to
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/arch/arm/boot/dts/qcom-msm8974.dtsi#n89And the hardware is not emulated properly to report the actual frequency that the timer is running at? That's sad.
At the least, this should be in the board specific dtsi file instead of the SoC specific file, because it's a board quirk.
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project