airoha: Add initial support AN7581
v2 cover airoha: Add initial support AN7581
This little series adds initial support for Airoha AN7581 SoC.
With the help of some backport patch, this use OF_UPSTREAM directly.
Posting this to have the targer and the very basic driver.
Ethernet, SNAND and eMMC support is already ready downstream and will be posted shortly after this gets approved.
Having the first driver ready permits to separately push dedicate series for SNAND, eMMC and Ethrnet as they all depends on basic support of clock and reset and nothing else.
Changes v2:
- Use OF_UPSTREAM directly
- Backport some patch for OF_UPSTREAM
- Make use of u-boot.dtsi files
- Fix defconfig
- Use pattern for MAINTAINERS file
- Correctly handle SYS_BOARD/SYS_CONFIG_NAME
- Drop config for header file
Christian Marangi (6):
airoha: Add initial support for Airoha AN7581 SoC
clk: airoha: Add support for Airoha AN7581 SoC clock
reset: airoha: Add driver for controlling reset line of AN7581
arm64: dts: airoha: en7581: Add Clock Controller node
dt-bindings: clock: drop NUM_CLOCKS define for EN7581
dt-bindings: clock: add ID for eMMC for EN7581
arch/arm/Kconfig | 9 + arch/arm/Makefile | 1 + arch/arm/dts/an7581-u-boot.dtsi | 18 + arch/arm/dts/en7581-evb-u-boot.dtsi | 11 + arch/arm/mach-airoha/Kconfig | 32 ++ arch/arm/mach-airoha/Makefile | 5 + arch/arm/mach-airoha/an7581/Makefile | 3 + arch/arm/mach-airoha/an7581/init.c | 47 ++ arch/arm/mach-airoha/cpu.c | 20 + board/airoha/an7581/MAINTAINERS | 5 + board/airoha/an7581/Makefile | 3 + board/airoha/an7581/an7581_rfb.c | 16 + configs/an7581_evb_defconfig | 78 +++ drivers/clk/Makefile | 1 + drivers/clk/airoha/Makefile | 3 + drivers/clk/airoha/clk-airoha.c | 454 ++++++++++++++++++ drivers/reset/Kconfig | 7 + drivers/reset/Makefile | 1 + drivers/reset/reset-airoha.c | 173 +++++++ .../include/dt-bindings/clock/en7523-clk.h | 2 +- dts/upstream/src/arm64/airoha/en7581.dtsi | 8 + include/configs/an7581.h | 19 + 22 files changed, 915 insertions(+), 1 deletion(-) create mode 100644 arch/arm/dts/an7581-u-boot.dtsi create mode 100644 arch/arm/dts/en7581-evb-u-boot.dtsi create mode 100644 arch/arm/mach-airoha/Kconfig create mode 100644 arch/arm/mach-airoha/Makefile create mode 100644 arch/arm/mach-airoha/an7581/Makefile create mode 100644 arch/arm/mach-airoha/an7581/init.c create mode 100644 arch/arm/mach-airoha/cpu.c create mode 100644 board/airoha/an7581/MAINTAINERS create mode 100644 board/airoha/an7581/Makefile create mode 100644 board/airoha/an7581/an7581_rfb.c create mode 100644 configs/an7581_evb_defconfig create mode 100644 drivers/clk/airoha/Makefile create mode 100644 drivers/clk/airoha/clk-airoha.c create mode 100644 drivers/reset/reset-airoha.c create mode 100644 include/configs/an7581.h
Signature · 1 line
2.48.1
PATCH v2 1/6 airoha: Add initial support for Airoha AN7581 SoC
Add initial support for Airoha AN7581 SoC. This adds the initial Kconfig and Makefile entry for the SoC, an U-Boot specific DTSI and initial config for it. Also add the initial code for CPU and RAM initialization.
--- arch/arm/Kconfig | 9 ++++ arch/arm/Makefile | 1 + arch/arm/dts/an7581-u-boot.dtsi | 18 +++++++ arch/arm/dts/en7581-evb-u-boot.dtsi | 11 ++++ arch/arm/mach-airoha/Kconfig | 32 ++++++++++++ arch/arm/mach-airoha/Makefile | 5 ++ arch/arm/mach-airoha/an7581/Makefile | 3 ++ arch/arm/mach-airoha/an7581/init.c | 47 +++++++++++++++++ arch/arm/mach-airoha/cpu.c | 20 +++++++ board/airoha/an7581/MAINTAINERS | 5 ++ board/airoha/an7581/Makefile | 3 ++ board/airoha/an7581/an7581_rfb.c | 16 ++++++ configs/an7581_evb_defconfig | 78 ++++++++++++++++++++++++++++ include/configs/an7581.h | 19 +++++++ 14 files changed, 267 insertions(+) create mode 100644 arch/arm/dts/an7581-u-boot.dtsi create mode 100644 arch/arm/dts/en7581-evb-u-boot.dtsi create mode 100644 arch/arm/mach-airoha/Kconfig create mode 100644 arch/arm/mach-airoha/Makefile create mode 100644 arch/arm/mach-airoha/an7581/Makefile create mode 100644 arch/arm/mach-airoha/an7581/init.c create mode 100644 arch/arm/mach-airoha/cpu.c create mode 100644 board/airoha/an7581/MAINTAINERS create mode 100644 board/airoha/an7581/Makefile create mode 100644 board/airoha/an7581/an7581_rfb.c create mode 100644 configs/an7581_evb_defconfig create mode 100644 include/configs/an7581.h
arch/arm/Kconfig +9 -0
@@ -600,6 +600,13 @@ choice prompt "Target select" default TARGET_HIKEY +config ARCH_AIROHA + bool "Airoha SoCs" + select DM + select OF_CONTROL + help + Support for the Airoha soc. + config ARCH_AT91 bool "Atmel AT91" select GPIO_EXTRA_HEADER
@@ -2251,6 +2258,8 @@ config SYS_KWD_CONFIG Path within the source directory to the kwbimage.cfg file to use when packaging the U-Boot image for use. +source "arch/arm/mach-airoha/Kconfig" + source "arch/arm/mach-apple/Kconfig" source "arch/arm/mach-aspeed/Kconfig"
arch/arm/Makefile +1 -0
@@ -51,6 +51,7 @@ PLATFORM_CPPFLAGS += $(arch-y) $(tune-y) # Machine directory name. This list is sorted alphanumerically # by CONFIG_* macro name. +machine-$(CONFIG_ARCH_AIROHA) += airoha machine-$(CONFIG_ARCH_APPLE) += apple machine-$(CONFIG_ARCH_ASPEED) += aspeed machine-$(CONFIG_ARCH_AT91) += at91
arch/arm/dts/an7581-u-boot.dtsi new file +18 -0
@@ -0,0 +1,18 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/ { + reserved-memory { + #address-cells = <2>; + #size-cells = <2>; + ranges; + + atf-reserved-memory@80000000 { + no-map; + reg = <0x0 0x80000000 0x0 0x40000>; + }; + }; +}; + +&uart1 { + bootph-all; +};
arch/arm/dts/en7581-evb-u-boot.dtsi new file +11 -0
@@ -0,0 +1,11 @@ +// SPDX-License-Identifier: GPL-2.0+ + +/ { + /* When running as a first-stage bootloader this isn't filled in automatically */ + memory@80000000 { + device_type = "memory"; + reg = <0x0 0x80000000 0x0 0x20000000>; + }; +}; + +#include "an7581-u-boot.dtsi"
arch/arm/mach-airoha/Kconfig new file +32 -0
@@ -0,0 +1,32 @@ +if ARCH_AIROHA + +config SYS_VENDOR + default "airoha" + +choice + prompt "Airoha board select" + +config TARGET_AN7581 + bool "Airoha AN7581 SoC" + select ARM64 + help + The Airoha EN7581 is a ARM-based SoC with a quad-core Cortex-A7 + including NEON and GPU, Mali-450 graphics, several DDR3 options, + crypto engine, built-in Wi-Fi / Bluetooth combo chip, JPEG decoder, + video interfaces supporting HDMI and MIPI, and video codec support. + Peripherals include Gigabit Ethernet, switch, USB3.0 and OTG, PCIe, + I2S, PCM, S/PDIF, UART, SPI, I2C, IR TX/RX, and PWM. + +endchoice + +config SYS_SOC + default "an7581" if TARGET_AN7581 + +config SYS_BOARD + default "an7581" if TARGET_AN7581 + +config SYS_CONFIG_NAME + default "an7581" if TARGET_AN7581 + +endif +
arch/arm/mach-airoha/Makefile new file +5 -0
@@ -0,0 +1,5 @@ +# SPDX-License-Identifier: GPL-2.0 + +obj-y += cpu.o + +obj-$(CONFIG_TARGET_AN7581) += an7581/
arch/arm/mach-airoha/an7581/Makefile new file +3 -0
@@ -0,0 +1,3 @@ +# SPDX-License-Identifier: GPL-2.0 + +obj-y += init.o
arch/arm/mach-airoha/an7581/init.c new file +47 -0
47 lines not on this page · raw message
arch/arm/mach-airoha/cpu.c new file +20 -0
@@ -0,0 +1,20 @@ +// SPDX-License-Identifier: GPL-2.0 + +#include <cpu_func.h> +#include <dm.h> +#include <init.h> +#include <wdt.h> +#include <dm/uclass-internal.h> + +int arch_cpu_init (void ) +{ +icache_enable (); + +return 0 ; +} + +void enable_caches (void ) +{ +/* Enable D-cache. I-cache is already enabled in start.S */ +dcache_enable (); +}
board/airoha/an7581/MAINTAINERS new file +5 -0
@@ -0,0 +1,5 @@ +AN7581 +M: Christian Marangi <[email protected]> +S: Maintained +N: airoha +N: an7581
board/airoha/an7581/Makefile new file +3 -0
@@ -0,0 +1,3 @@ +# SPDX-License-Identifier: GPL-2.0 + +obj-y += an7581_rfb.o
board/airoha/an7581/an7581_rfb.c new file +16 -0
@@ -0,0 +1,16 @@ +// SPDX-License-Identifier: GPL-2.0 +/* +* Author: Christian Marangi <[email protected]> +*/ + +#include <asm/global_data.h> + +DECLARE_GLOBAL_DATA_PTR ; + +int board_init (void ) +{ +/* address of boot parameters */ + gd->bd->bi_boot_params =CFG_SYS_SDRAM_BASE +0x100 ; + +return 0 ; +}
configs/an7581_evb_defconfig new file +78 -0
78 lines not on this page · raw message
include/configs/an7581.h new file +19 -0
@@ -0,0 +1,19 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* +* Configuration for Airoha AN7581 +*/ + +#ifndef __AN7581_H +#define __AN7581_H + +#include <linux/sizes.h> + +#define CFG_SYS_UBOOT_BASE CONFIG_TEXT_BASE + +#define CFG_SYS_INIT_RAM_ADDR CONFIG_TEXT_BASE +#define CFG_SYS_INIT_RAM_SIZE SZ_2M + +/* DRAM */ +#define CFG_SYS_SDRAM_BASE 0x80000000 + +#endif
Signature · 1 line
2.48.1
PATCH v2 2/6 clk: airoha: Add support for Airoha AN7581 SoC clock
In reply to Christian MarangiAdd support for Airoha AN7581 SoC clock driver. This mainly needed for eMMC support to correctly get the current clock applied.
Based on the Linux clk-en7523.c but majorly reworked for U-Boot that doesn't require CCF subsystem.
Major modification, support for set_rate, realtime get_rate and split for reset part to a different driver.
--- drivers/clk/Makefile | 1 + drivers/clk/airoha/Makefile | 3 + drivers/clk/airoha/clk-airoha.c | 438 ++++++++++++++++++++++++++++++++ 3 files changed, 442 insertions(+) create mode 100644 drivers/clk/airoha/Makefile create mode 100644 drivers/clk/airoha/clk-airoha.c
drivers/clk/Makefile +1 -0
@@ -14,6 +14,7 @@ obj-$(CONFIG_$(PHASE_)CLK_GPIO) += clk-gpio.o obj-$(CONFIG_$(PHASE_)CLK_STUB) += clk-stub.o obj-y += adi/ +obj-y += airoha/ obj-y += analogbits/ obj-y += imx/ obj-$(CONFIG_CLK_JH7110) += starfive/
drivers/clk/airoha/Makefile new file +3 -0
@@ -0,0 +1,3 @@ +# SPDX-License-Identifier: GPL-2.0 +# Core +obj-$(CONFIG_ARCH_AIROHA) += clk-airoha.o
drivers/clk/airoha/clk-airoha.c new file +438 -0
438 lines not on this page · raw message
Signature · 1 line
2.48.1
PATCH v2 3/6 reset: airoha: Add driver for controlling reset line of AN7581
In reply to Christian MarangiAdd driver for controlling the reset lines of AN7581. This is a detached version of the clock controller driver present in Linux only used to control reset lines. Driver gets loaded with the bind of the clock driver and doesn't require a compatible. This is needed as they share the same registers.
--- drivers/clk/airoha/clk-airoha.c | 16 +++ drivers/reset/Kconfig | 7 ++ drivers/reset/Makefile | 1 + drivers/reset/reset-airoha.c | 173 ++++++++++++++++++++++++++++++++ 4 files changed, 197 insertions(+) create mode 100644 drivers/reset/reset-airoha.c
drivers/clk/airoha/clk-airoha.c +16 -0
@@ -416,6 +416,21 @@ static int airoha_clk_probe(struct udevice *dev)return 0 ; } +static int airoha_clk_bind (struct udevice *dev) +{ +struct udevice *rst_dev; +int ret =0 ; + +if (CONFIG_IS_ENABLED (RESET_AIROHA )) { + ret =device_bind_driver_to_node (dev,"airoha-reset" ,"reset" , +dev_ofnode (dev), &rst_dev); +if (ret) +debug ("Warning: failed to bind reset controller\n" ); + } + +return ret; +} +static const struct airoha_clk_soc_data en7581_data = { .num_clocks =ARRAY_SIZE (en7581_base_clks), .descs = en7581_base_clks,
@@ -433,6 +448,7 @@ U_BOOT_DRIVER(airoha_clk) = { .id = UCLASS_CLK, .of_match = airoha_clk_ids, .probe = airoha_clk_probe, + .bind = airoha_clk_bind, .priv_auto = sizeof(struct airoha_clk_priv), .ops = &airoha_clk_ops, };
drivers/reset/Kconfig +7 -0
@@ -49,6 +49,13 @@ config TEGRA186_RESET Enable support for manipulating Tegra's on-SoC reset signals via IPC requests to the BPMP (Boot and Power Management Processor). +config RESET_AIROHA + bool "Reset controller driver for Airoha SoCs" + depends on DM_RESET && ARCH_AIROHA + default y + help + Support for reset controller on Airoha SoCs. + config RESET_TI_SCI bool "TI System Control Interface (TI SCI) reset driver" depends on DM_RESET && TI_SCI_PROTOCOL
drivers/reset/Makefile +1 -0
@@ -10,6 +10,7 @@ obj-$(CONFIG_STI_RESET) += sti-reset.o obj-$(CONFIG_STM32_RESET) += stm32-reset.o obj-$(CONFIG_TEGRA_CAR_RESET) += tegra-car-reset.o obj-$(CONFIG_TEGRA186_RESET) += tegra186-reset.o +obj-$(CONFIG_RESET_AIROHA) += reset-airoha.o obj-$(CONFIG_RESET_TI_SCI) += reset-ti-sci.o obj-$(CONFIG_RESET_HSDK) += reset-hsdk.o obj-$(CONFIG_RESET_BCM6345) += reset-bcm6345.o
drivers/reset/reset-airoha.c new file +173 -0
173 lines not on this page · raw message
Signature · 1 line
2.48.1
PATCH v2 4/6 arm64: dts: airoha: en7581: Add Clock Controller node
In reply to Christian MarangiAdd Clock Controller node for EN7581 SoC to correctly expose supported clock for any user in the SoC.
[ upstream commit: 7693017580e9be839fa5f27130bb6500f3597595 ]
--- dts/upstream/src/arm64/airoha/en7581.dtsi | 8 ++++++++ 1 file changed, 8 insertions(+)
dts/upstream/src/arm64/airoha/en7581.dtsi +8 -0
@@ -2,6 +2,7 @@ #include <dt-bindings/interrupt-controller/irq.h> #include <dt-bindings/interrupt-controller/arm-gic.h> +#include <dt-bindings/clock/en7523-clk.h> / { interrupt-parent = <&gic>;
@@ -142,6 +143,13 @@ interrupts = <GIC_PPI 9 IRQ_TYPE_LEVEL_LOW>; }; + scuclk: clock-controller@1fa20000 { + compatible = "airoha,en7581-scu"; + reg = <0x0 0x1fb00000 0x0 0x970>; + #clock-cells = <1>; + #reset-cells = <1>; + }; + uart1: serial@1fbf0000 { compatible = "ns16550"; reg = <0x0 0x1fbf0000 0x0 0x30>;
Signature · 1 line
2.48.1
PATCH v2 5/6 dt-bindings: clock: drop NUM_CLOCKS define for EN7581
In reply to Christian MarangiDrop NUM_CLOCKS define for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.
[ upstream commit: 02d3b7557ce28c373ea1e925ae16ab5988284313 ]
--- dts/upstream/include/dt-bindings/clock/en7523-clk.h | 2 -- 1 file changed, 2 deletions(-)
dts/upstream/include/dt-bindings/clock/en7523-clk.h +0 -2
@@ -12,6 +12,4 @@#define EN7523_CLK_CRYPTO 6#define EN7523_CLK_PCIE 7 -#define EN7523_NUM_CLOCKS 8 -#endif /* _DT_BINDINGS_CLOCK_AIROHA_EN7523_H_ */
Signature · 1 line
2.48.1
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Quoted 6 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Signed-off-by Christian Marangi <[email protected]>
Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Best regards,
Krzysztof
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Quoted 10 lines · Krzysztof Kozlowski
Quoted 6 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Signature · 1 line
Ansuel
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Quoted 6 lines · Christian Marangi
Quoted 5 lines · Krzysztof Kozlowski
Quoted 4 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.
Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
I expected OF_UPSTREAM to be taking the sources, not patches.
Quoted 9 lines
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Well, Ack is still not valid because I did not Ack exactly that change. It does not matter for the ack, but for Reviewed-by it would matter, because it is a statement (of oversight...). I cannot control what you put into patches taken out of kernel, but at least do not Cc me on that.
Best regards,
Krzysztof
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Quoted 24 lines · Krzysztof Kozlowski
Quoted 6 lines · Christian Marangi
Quoted 5 lines · Krzysztof Kozlowski
Quoted 4 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
I expected
OF_UPSTREAMto be taking the sources, not patches.Quoted 6 lines
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Quoted 8 lines
Quoted 3 lines
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Well, Ack is still not valid because I did not Ack exactly that change. It does not matter for the ack, but for Reviewed-by it would matter, because it is a statement (of oversight...). I cannot control what you put into patches taken out of kernel, but at least do not Cc me on that.
In specifics, yes, we should update doc/develop/devicetree/control.rst and maybe doc/develop/sending_patches.rst to use --suppress-cc=all for dts/upstream.
But in general, what do you expect people to be doing with content from devicetree-rebasing? We're doing some direct cherry-picks in between merging of the tags. I think it would be weird to be dropping the tags and un-attributing peoples work.
Signature · 1 line
Tom
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Quoted 34 lines · Tom Rini
Quoted 24 lines · Krzysztof Kozlowski
Quoted 6 lines · Christian Marangi
Quoted 5 lines · Krzysztof Kozlowski
Quoted 4 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
I expected
OF_UPSTREAMto be taking the sources, not patches.Quoted 6 lines
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Quoted 8 lines
Quoted 3 lines
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Well, Ack is still not valid because I did not Ack exactly that change. It does not matter for the ack, but for Reviewed-by it would matter, because it is a statement (of oversight...). I cannot control what you put into patches taken out of kernel, but at least do not Cc me on that.
Quoted 8 lines
In specifics, yes, we should update
doc/develop/devicetree/control.rstand maybedoc/develop/sending_patches.rstto use --suppress-cc=all for dts/upstream.But in general, what do you expect people to be doing with content from devicetree-rebasing? We're doing some direct cherry-picks in between merging of the tags. I think it would be weird to be dropping the tags and un-attributing peoples work.
I'm okay with my tags being kept for cherry-picked commits, since they show up with the subtree imports anyway, right? Doing some sort of [ upstream commit <sha> ] thing like linux-stable could be a good idea to make it obvious what the source is.
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
In reply to Tom RiniQuoted 34 lines · Tom Rini
Quoted 24 lines · Krzysztof Kozlowski
Quoted 6 lines · Christian Marangi
Quoted 5 lines · Krzysztof Kozlowski
Quoted 4 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
I expected
OF_UPSTREAMto be taking the sources, not patches.Quoted 6 lines
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Quoted 8 lines
Quoted 3 lines
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Well, Ack is still not valid because I did not Ack exactly that change. It does not matter for the ack, but for Reviewed-by it would matter, because it is a statement (of oversight...). I cannot control what you put into patches taken out of kernel, but at least do not Cc me on that.
Quoted 8 lines
In specifics, yes, we should update
doc/develop/devicetree/control.rstand maybedoc/develop/sending_patches.rstto use --suppress-cc=all for dts/upstream.But in general, what do you expect people to be doing with content from devicetree-rebasing? We're doing some direct cherry-picks in between merging of the tags. I think it would be weird to be dropping the tags and un-attributing peoples work.
I rather expected something like how kernel is importing dtc. You just list the commits you get. If you want the full git history, then I would expect simple git submodule. In both cases there will be no such patches on the lists.
For the Ack it does not matter, but I would feel uncomfortable if people were sending stripped and modified patches with my Rb tag.
Best regards,
Krzysztof
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Quoted 45 lines · Krzysztof Kozlowski
Quoted 34 lines · Tom Rini
Quoted 24 lines · Krzysztof Kozlowski
Quoted 6 lines · Christian Marangi
Quoted 5 lines · Krzysztof Kozlowski
Quoted 4 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
I expected
OF_UPSTREAMto be taking the sources, not patches.Quoted 6 lines
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Quoted 8 lines
Quoted 3 lines
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Well, Ack is still not valid because I did not Ack exactly that change. It does not matter for the ack, but for Reviewed-by it would matter, because it is a statement (of oversight...). I cannot control what you put into patches taken out of kernel, but at least do not Cc me on that.
Quoted 8 lines
In specifics, yes, we should update
doc/develop/devicetree/control.rstand maybedoc/develop/sending_patches.rstto use --suppress-cc=all for dts/upstream.But in general, what do you expect people to be doing with content from devicetree-rebasing? We're doing some direct cherry-picks in between merging of the tags. I think it would be weird to be dropping the tags and un-attributing peoples work.
Quoted 7 lines
I rather expected something like how kernel is importing dtc. You just list the commits you get. If you want the full git history, then I would expect simple git submodule. In both cases there will be no such patches on the lists.
For the Ack it does not matter, but I would feel uncomfortable if people were sending stripped and modified patches with my Rb tag.
I guess I'm confused. Looking at
https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
we're doing the normal thing of havig "[ upstream commit <sha>]" after the imported log. When I merge the subtree and tag it indeed gives what you're expecting too.
Signature · 1 line
Tom
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Quoted 51 lines · Tom Rini
Quoted 50 lines · Krzysztof Kozlowski
Quoted 34 lines · Tom Rini
Quoted 24 lines · Krzysztof Kozlowski
Quoted 6 lines · Christian Marangi
Quoted 5 lines · Krzysztof Kozlowski
Quoted 4 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
I expected
OF_UPSTREAMto be taking the sources, not patches.Quoted 6 lines
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Quoted 8 lines
Quoted 3 lines
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Well, Ack is still not valid because I did not Ack exactly that change. It does not matter for the ack, but for Reviewed-by it would matter, because it is a statement (of oversight...). I cannot control what you put into patches taken out of kernel, but at least do not Cc me on that.
Quoted 8 lines
In specifics, yes, we should update
doc/develop/devicetree/control.rstand maybedoc/develop/sending_patches.rstto use --suppress-cc=all for dts/upstream.But in general, what do you expect people to be doing with content from devicetree-rebasing? We're doing some direct cherry-picks in between merging of the tags. I think it would be weird to be dropping the tags and un-attributing peoples work.
I rather expected something like how kernel is importing dtc. You just list the commits you get. If you want the full git history, then I would expect simple git submodule. In both cases there will be no such patches on the lists.
Quoted 8 lines
Quoted 2 lines
For the Ack it does not matter, but I would feel uncomfortable if people were sending stripped and modified patches with my Rb tag.
I guess I'm confused. Looking at
https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
we're doing the normal thing of havig "[ upstream commit <sha>]" after the imported log. When I merge the subtree and tag it indeed gives what you're expecting too.
When you merge subtree, the patch is not modified and it lives in separate repo. No one sends them over lists, no one modifies them. Unlike here (even if modification did not happen, person was touching it so how can anyone be sure? That's not a scripted process).
Best regards,
Krzysztof
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Quoted 61 lines · Krzysztof Kozlowski
Quoted 51 lines · Tom Rini
Quoted 50 lines · Krzysztof Kozlowski
Quoted 34 lines · Tom Rini
Quoted 24 lines · Krzysztof Kozlowski
Quoted 6 lines · Christian Marangi
Quoted 5 lines · Krzysztof Kozlowski
Quoted 4 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
I expected
OF_UPSTREAMto be taking the sources, not patches.Quoted 6 lines
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Quoted 8 lines
Quoted 3 lines
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Well, Ack is still not valid because I did not Ack exactly that change. It does not matter for the ack, but for Reviewed-by it would matter, because it is a statement (of oversight...). I cannot control what you put into patches taken out of kernel, but at least do not Cc me on that.
Quoted 8 lines
In specifics, yes, we should update
doc/develop/devicetree/control.rstand maybedoc/develop/sending_patches.rstto use --suppress-cc=all for dts/upstream.But in general, what do you expect people to be doing with content from devicetree-rebasing? We're doing some direct cherry-picks in between merging of the tags. I think it would be weird to be dropping the tags and un-attributing peoples work.
I rather expected something like how kernel is importing dtc. You just list the commits you get. If you want the full git history, then I would expect simple git submodule. In both cases there will be no such patches on the lists.
Quoted 8 lines
Quoted 2 lines
For the Ack it does not matter, but I would feel uncomfortable if people were sending stripped and modified patches with my Rb tag.
I guess I'm confused. Looking at
https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
we're doing the normal thing of havig "[ upstream commit <sha>]" after the imported log. When I merge the subtree and tag it indeed gives what you're expecting too.
Quoted 4 lines
When you merge subtree, the patch is not modified and it lives in separate repo. No one sends them over lists, no one modifies them. Unlike here (even if modification did not happen, person was touching it so how can anyone be sure? That's not a scripted process).
We merge the subtree on tags, and people cherry-pick commits in between tags when needed. This is a case of the latter, which is why it says "[ upstream commit <sha> ]" in the commit message, which is the usual case.
Signature · 1 line
Tom
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Sorry for jumping in late in this thread as it is still using my old Linaro email ID which should be disabled by now.
Quoted 62 lines · Tom Rini
Quoted 61 lines · Krzysztof Kozlowski
Quoted 59 lines · Tom Rini
Quoted 45 lines · Krzysztof Kozlowski
Quoted 34 lines · Tom Rini
Quoted 24 lines · Krzysztof Kozlowski
Quoted 6 lines · Christian Marangi
Quoted 5 lines · Krzysztof Kozlowski
Quoted 4 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
I expected
OF_UPSTREAMto be taking the sources, not patches.Quoted 6 lines
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Quoted 8 lines
Quoted 3 lines
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Well, Ack is still not valid because I did not Ack exactly that change. It does not matter for the ack, but for Reviewed-by it would matter, because it is a statement (of oversight...). I cannot control what you put into patches taken out of kernel, but at least do not Cc me on that.
Quoted 8 lines
In specifics, yes, we should update
doc/develop/devicetree/control.rstand maybedoc/develop/sending_patches.rstto use --suppress-cc=all for dts/upstream.But in general, what do you expect people to be doing with content from devicetree-rebasing? We're doing some direct cherry-picks in between merging of the tags. I think it would be weird to be dropping the tags and un-attributing peoples work.
Quoted 7 lines
I rather expected something like how kernel is importing dtc. You just list the commits you get. If you want the full git history, then I would expect simple git submodule. In both cases there will be no such patches on the lists.
For the Ack it does not matter, but I would feel uncomfortable if people were sending stripped and modified patches with my Rb tag.
I guess I'm confused. Looking at
https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
we're doing the normal thing of havig "[ upstream commit <sha>]" after the imported log. When I merge the subtree and tag it indeed gives what you're expecting too.
Quoted 8 lines
Quoted 4 lines
When you merge subtree, the patch is not modified and it lives in separate repo. No one sends them over lists, no one modifies them. Unlike here (even if modification did not happen, person was touching it so how can anyone be sure? That's not a scripted process).
We merge the subtree on tags, and people cherry-pick commits in between tags when needed. This is a case of the latter, which is why it says "[ upstream commit <sha> ]" in the commit message, which is the usual case.
Although we have tooling to pick patches from devicetree-rebasing tree but I can see Krzysztof's concerns here. We can't be sure if developer has touched the cherry picked patch or not but I suppose there would be similar concerns for the stable backports for Linux too. So IMHO, it's really upto maintainer applying those cherry-picked patches to see if there is any difference from upstream.
However, there is an additional process change what we can do here is for the developer to list just the commit IDs for the patches to be cherry picked in dts/upstream in the cover letter. This way the maintainer can just directly use the tooling to cherry pick those patches before applying the patch-set.
Tooling already available for cherry-picking subtree commits as:
$ ./tools/update-subtree.sh pick dts <devicetree-rebasing-commit-id>
-Sumit
Re: [PATCH v2 5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
Quoted 88 lines · Sumit Garg
Sorry for jumping in late in this thread as it is still using my old Linaro email ID which should be disabled by now.
Quoted 62 lines · Tom Rini
Quoted 61 lines · Krzysztof Kozlowski
Quoted 59 lines · Tom Rini
Quoted 45 lines · Krzysztof Kozlowski
Quoted 34 lines · Tom Rini
Quoted 24 lines · Krzysztof Kozlowski
Quoted 6 lines · Christian Marangi
Quoted 5 lines · Krzysztof Kozlowski
Quoted 4 lines · Christian Marangi
Drop
NUM_CLOCKSdefine for EN7581 dts/upstream/src/include. This is not a binding and should not be placed here. Value is derived internally in the user driver.Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Signed-off-by Christian Marangi <[email protected]>Please drop my Ack. I have never acked such patch for uboot. If I did, it was by mistake - probably you CC-ed me for some reason.
Some explaination, uboot introduced the concept of upstream where they "import" linux patch for dts and dt-bindings.
I expected
OF_UPSTREAMto be taking the sources, not patches.Quoted 6 lines
This and the other patch are the exact upstream patch with only the path changed so I keep all the patch commit message with tags and added the
[ upstream commit ] thing.
Quoted 8 lines
Quoted 3 lines
Hope Tom can better suggest how this should be done. You were CC probably because the git send-email included you as present in the different tags.
Well, Ack is still not valid because I did not Ack exactly that change. It does not matter for the ack, but for Reviewed-by it would matter, because it is a statement (of oversight...). I cannot control what you put into patches taken out of kernel, but at least do not Cc me on that.
Quoted 8 lines
In specifics, yes, we should update
doc/develop/devicetree/control.rstand maybedoc/develop/sending_patches.rstto use --suppress-cc=all for dts/upstream.But in general, what do you expect people to be doing with content from devicetree-rebasing? We're doing some direct cherry-picks in between merging of the tags. I think it would be weird to be dropping the tags and un-attributing peoples work.
Quoted 7 lines
I rather expected something like how kernel is importing dtc. You just list the commits you get. If you want the full git history, then I would expect simple git submodule. In both cases there will be no such patches on the lists.
For the Ack it does not matter, but I would feel uncomfortable if people were sending stripped and modified patches with my Rb tag.
I guess I'm confused. Looking at
https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
we're doing the normal thing of havig "[ upstream commit <sha>]" after the imported log. When I merge the subtree and tag it indeed gives what you're expecting too.Quoted 8 lines
Quoted 4 lines
When you merge subtree, the patch is not modified and it lives in separate repo. No one sends them over lists, no one modifies them. Unlike here (even if modification did not happen, person was touching it so how can anyone be sure? That's not a scripted process).
We merge the subtree on tags, and people cherry-pick commits in between tags when needed. This is a case of the latter, which is why it says "[ upstream commit <sha> ]" in the commit message, which is the usual case.
Although we have tooling to pick patches from devicetree-rebasing tree but I can see Krzysztof's concerns here. We can't be sure if developer has touched the cherry picked patch or not but I suppose there would be similar concerns for the stable backports for Linux too. So IMHO, it's really upto maintainer applying those cherry-picked patches to see if there is any difference from upstream.
However, there is an additional process change what we can do here is for the developer to list just the commit IDs for the patches to be cherry picked in dts/upstream in the cover letter. This way the maintainer can just directly use the tooling to cherry pick those patches before applying the patch-set.
Quoted 3 lines
Tooling already available for cherry-picking subtree commits as:
$ ./tools/update-subtree.sh pick dts <devicetree-rebasing-commit-id>
For U-Boot at least, at the end of the day the cherry-picks are a temporary measure. We do pick up and merge each release tag in turn (and so yeah, I should grab the newest one already) and if the merge doesn't Just Work, I drop in the correct file from upstream to resolve the merge conflict.
Signature · 1 line
Tom
PATCH v2 6/6 dt-bindings: clock: add ID for eMMC for EN7581
In reply to Christian MarangiAdd ID for eMMC for EN7581. This is to control clock selection of eMMC between 200MHz and 150MHz.
[ upstream commit: 82108ad3285f58f314ad41398f44017c7dbe44de ]
--- dts/upstream/include/dt-bindings/clock/en7523-clk.h | 2 ++ 1 file changed, 2 insertions(+)
dts/upstream/include/dt-bindings/clock/en7523-clk.h +2 -0
@@ -12,4 +12,6 @@#define EN7523_CLK_CRYPTO 6#define EN7523_CLK_PCIE 7 +#define EN7581_CLK_EMMC 8 +#endif /* _DT_BINDINGS_CLOCK_AIROHA_EN7523_H_ */
Signature · 1 line
2.48.1
Re: [PATCH v2 6/6] dt-bindings: clock: add ID for eMMC for EN7581
Quoted 11 lines · Christian Marangi
Add ID for eMMC for EN7581. This is to control clock selection of eMMC between 200MHz and 150MHz.
Signed-off-by Christian Marangi <[email protected]>Acked-by Conor Dooley <[email protected]>Signed-off-by Stephen Boyd <[email protected]>[ upstream commit:
82108ad3285f58f314ad41398f44017c7dbe44de]--- dts/upstream/include/dt-bindings/clock/en7523-clk.h | 2 ++
I don't think Conor ever acked above change to "dts/upstream/" folder.
Best regards,
Krzysztof
On Fri, Mar 14, 2025 at 07:59:20PM +0100, Christian Marangi wrote:
`
Quoted 14 lines
This little series adds initial support for Airoha AN7581 SoC.
With the help of some backport patch, this use
OF_UPSTREAMdirectly.Posting this to have the targer and the very basic driver.
Ethernet, SNAND and eMMC support is already ready downstream and will be posted shortly after this gets approved.
Having the first driver ready permits to separately push dedicate series for SNAND, eMMC and Ethrnet as they all depends on basic support of clock and reset and nothing else.
Quoted 8 lines
Changes v2:
- UseOF_UPSTREAMdirectly
- Backport some patch forOF_UPSTREAM
- Make use ofu-boot.dtsifiles
- Fix defconfig
- Use pattern forMAINTAINERSfile
- Correctly handle SYS_BOARD/SYS_CONFIG_NAME
- Drop config for header file
This generally looks good, thanks.
Signature · 1 line
Tom
Quoted 25 lines · Tom Rini
On Fri, Mar 14, 2025 at 07:59:20PM +0100, Christian Marangi wrote:
`Quoted 14 lines
This little series adds initial support for Airoha AN7581 SoC.
With the help of some backport patch, this use
OF_UPSTREAMdirectly.Posting this to have the targer and the very basic driver.
Ethernet, SNAND and eMMC support is already ready downstream and will be posted shortly after this gets approved.
Having the first driver ready permits to separately push dedicate series for SNAND, eMMC and Ethrnet as they all depends on basic support of clock and reset and nothing else.
Quoted 8 lines
Changes v2:
- UseOF_UPSTREAMdirectly
- Backport some patch forOF_UPSTREAM
- Make use ofu-boot.dtsifiles
- Fix defconfig
- Use pattern forMAINTAINERSfile
- Correctly handle SYS_BOARD/SYS_CONFIG_NAME
- Drop config for header file
Quoted 2 lines
This generally looks good, thanks.
Hi Tom, may I ask status of this? I would like to continue with posting follow-up driver like mmc nand ethernet for this. Is it ok if I say this series is a dependency so I can start the review process for it?
Signature · 1 line
Ansuel
Quoted 1 line · Christian Marangi
This little series adds initial support for Airoha AN7581 SoC.
Very nice. Will you (or someone else) upstream or at least open-source ATF parts as well, similar to how Mediatek does it?
Quoted 5 lines · Andreas Gnau
Quoted 1 line · Christian Marangi
This little series adds initial support for Airoha AN7581 SoC.
Very nice. Will you (or someone else) upstream or at least open-source ATF parts as well, similar to how Mediatek does it?
It's planned. I have the source and I have permission to opesource it (there are lots of .o file but whatever)
It needs lots of love tho as they modified ATF fork A LOT. I'm giving priority on U-Boot currently.
Signature · 1 line
Ansuel
Quoted 8 lines · Christian Marangi
This little series adds initial support for Airoha AN7581 SoC.
With the help of some backport patch, this use
OF_UPSTREAMdirectly.Posting this to have the targer and the very basic driver.
[...]
Applied to u-boot/next, thanks!
[1/6] airoha: Add initial support for Airoha AN7581 SoC
commit: 793e327e2ca947a293c0eb5beb5eef27744385f0
[2/6] clk: airoha: Add support for Airoha AN7581 SoC clock
commit: d0b81afb5ec9d2d8a3f11bfc827f2f24c32d47ec
[3/6] reset: airoha: Add driver for controlling reset line of AN7581
commit: b02b8b767624a859a2776c11822119392702bbab
[4/6] arm64: dts: airoha: en7581: Add Clock Controller node
commit: 83972387a52712acf98e4827c0d09b72ea970088
[5/6] dt-bindings: clock: drop NUM_CLOCKS define for EN7581
commit: ea0d64adc67d270de27a092d7ff7bfce8780fefb
[6/6] dt-bindings: clock: add ID for eMMC for EN7581
commit: e00a318d64724a8fa1ed1ad56cf54edc1c295f3dSignature · 1 line
Tom