[PATCH] MIPS: Loongson32: DeviceTree for Loongson-ls1c300

2023-07-29 Thread Du Huanpeng
Add DeviceTree files for Loongson-ls1c300 processor, currently only has below nodes. - reset-controller - watchdog - serial - clock-controller tool for generate header and dts: [1] https://github.com/hodcarrier/ls1c300_bsp/tree/master/dts Signed-off-by: Du Huanpeng --- arch/mips/Kconfig

Re: [PATCH v5 3/6] mips: add a ls1c300 based board

2023-07-29 Thread Du Huanpeng
On Fri, Jul 28, 2023 at 10:35:01AM -0400, Tom Rini wrote: > On Fri, Jul 28, 2023 at 10:59:16AM +0800, Du Huanpeng wrote: > > On Thu, Jul 27, 2023 at 03:05:28PM -0400, Tom Rini wrote: > > > On Wed, Jul 26, 2023 at 08:30:24PM +0800, Du Huanpeng wrote: > > > > > >

Re: [PATCH v5 3/6] mips: add a ls1c300 based board

2023-07-27 Thread Du Huanpeng
On Thu, Jul 27, 2023 at 03:05:28PM -0400, Tom Rini wrote: > On Wed, Jul 26, 2023 at 08:30:24PM +0800, Du Huanpeng wrote: > > > - devicetree for ls1c300 SoC and board this devicetree was writen from scratch, I read the SoC's manual and devicetree-specification-v0.3.pdf, and

[PATCH v5 6/6] mips: ls1c300: add reset support based on watchdog driver

2023-07-26 Thread Du Huanpeng
Signed-off-by: Du Huanpeng --- drivers/reset/Kconfig | 7 ++ drivers/reset/Makefile| 1 + drivers/reset/reset-lsmips.c | 118 ++ include/dt-bindings/reset/ls1c300-reset.h | 36 +++ 4 files changed, 162 insertions

[PATCH v5 5/6] mips: ls1c300: add watchdog support

2023-07-26 Thread Du Huanpeng
- watchdog driver for ls1c300 with devicetree support Signed-off-by: Du Huanpeng --- drivers/watchdog/Kconfig | 8 +++ drivers/watchdog/Makefile | 1 + drivers/watchdog/lsmips_wdt.c | 128 ++ 3 files changed, 137 insertions(+) create mode 100644

[PATCH v5 2/6] mips: ls1c300: add base support

2023-07-26 Thread Du Huanpeng
- pinmux setup functions for debug uart - lowlevel initialization: sdram, pll, spi, debug uart note that, this SoC have NO useable ram after reset, do not use nested call when doing lowlevel_init. Signed-off-by: Du Huanpeng --- arch/mips/mach-lsmips/cpu.c | 19 +++ arch/mips

[PATCH v5 4/6] mips: ls1c300: add clock driver

2023-07-26 Thread Du Huanpeng
I write a Excel sheet to calcate clock, technical manual also will be uploaded later [1]. [1] https://github.com/hodcarrier/ls1c300_bsp Signed-off-by: Du Huanpeng --- drivers/clk/Makefile| 1 + drivers/clk/lsmips/Makefile | 3 + drivers/clk/lsmips/clk

[PATCH v5 3/6] mips: add a ls1c300 based board

2023-07-26 Thread Du Huanpeng
- devicetree for ls1c300 SoC and board - setup debug uart pins Signed-off-by: Du Huanpeng --- arch/mips/dts/loongson32-ls1c300b.dtsi | 150 arch/mips/dts/ls1c300-eval.dts | 30 + board/loongson/ls1c300-eval/Kconfig | 12 ++ board/loongson/ls1c300

[PATCH v5 1/6] mips: initial build infrastructure for loongson SoCs

2023-07-26 Thread Du Huanpeng
details: https://www.loongson.cn/ https://github.com/hodcarrier/ls1c300_bsp Signed-off-by: Du Huanpeng --- MAINTAINERS| 15 + arch/mips/Kconfig | 11 arch/mips/Makefile | 1 + arch/mips/dts/Makefile

[PATCH v5 0/6] add loongson mips ls1c300 initial support

2023-07-26 Thread Du Huanpeng
ze() to detect ram size. 14. clk driver - create custom clock ops for PLL - remove debug code 15. - rebase to 59bffec43a657598b194b9eb30dc01eec06078c7 - remove CONFIG_SYS_MONITOR_BASE from include/configs/ Du Huanpeng (6): mips: initial build infrastructure for loongson SoCs mips: ls1c300: add b

[PATCH v4 6/6] mips: ls1c300: add reset support based on watchdog driver

2023-07-23 Thread Du Huanpeng
Signed-off-by: Du Huanpeng --- drivers/reset/Kconfig | 7 ++ drivers/reset/Makefile| 1 + drivers/reset/reset-lsmips.c | 118 ++ include/dt-bindings/reset/ls1c300-reset.h | 36 +++ 4 files changed, 162 insertions

[PATCH v4 5/6] mips: ls1c300: add watchdog support

2023-07-23 Thread Du Huanpeng
Signed-off-by: Du Huanpeng --- drivers/watchdog/Kconfig | 8 +++ drivers/watchdog/Makefile | 1 + drivers/watchdog/lsmips_wdt.c | 128 ++ 3 files changed, 137 insertions(+) create mode 100644 drivers/watchdog/lsmips_wdt.c diff --git a/drivers

[PATCH v4 4/6] mips: ls1c300: add clock driver

2023-07-23 Thread Du Huanpeng
Signed-off-by: Du Huanpeng --- drivers/clk/Makefile| 1 + drivers/clk/lsmips/Makefile | 3 + drivers/clk/lsmips/clk-ls1c300.c| 180 include/dt-bindings/clock/ls1c300-clk.h | 18 +++ 4 files changed, 202 insertions(+) create

[PATCH v4 3/6] mips: add a ls1c300 based board

2023-07-23 Thread Du Huanpeng
Signed-off-by: Du Huanpeng --- arch/mips/dts/loongson32-ls1c300b.dtsi | 150 arch/mips/dts/ls1c300-eval.dts | 30 + board/loongson/ls1c300-eval/Kconfig | 12 ++ board/loongson/ls1c300-eval/MAINTAINERS | 7 ++ board/loongson/ls1c300-eval/Makefile

[PATCH v4 2/6] mips: ls1c300: add base support

2023-07-23 Thread Du Huanpeng
Signed-off-by: Du Huanpeng --- arch/mips/mach-lsmips/cpu.c | 19 +++ arch/mips/mach-lsmips/include/mach/serial.h | 16 +++ arch/mips/mach-lsmips/ls1c300/gpio.c | 66 + arch/mips/mach-lsmips/ls1c300/init.c | 62 arch/mips/mach-lsmips

[PATCH v4 1/6] mips: initial build infrastructure for loongson SoCs

2023-07-23 Thread Du Huanpeng
details: https://www.loongson.cn/ https://github.com/hodcarrier/ls1c300_bsp Signed-off-by: Du Huanpeng --- MAINTAINERS| 15 + Makefile | 1 + arch/mips/Kconfig | 11 arch/mips/Makefile

[PATCH v4 0/6] add loongson mips ls1c300 initial support

2023-07-23 Thread Du Huanpeng
custom clock ops for PLL - remove debug code 15. - rebase to 59bffec43a657598b194b9eb30dc01eec06078c7 - remove CONFIG_SYS_MONITOR_BASE from include/configs/ Du Huanpeng (6): mips: initial build infrastructure for loongson SoCs mips: ls1c300: add base support mips: add a ls1c300 based board

[PATCH] mips: dts: mt7620: rename nodes to generic names

2022-08-26 Thread Du Huanpeng
/devicetree-org/devicetree-specification/releases/tag/v0.3 Signed-off-by: Du Huanpeng --- arch/mips/dts/mt7620.dtsi | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/arch/mips/dts/mt7620.dtsi b/arch/mips/dts/mt7620.dtsi index 03a80b7a70..27a7fbdef2 100644

[PATCH] mips: dts: mt7620: rename nodes to generic names

2022-04-21 Thread Du Huanpeng
/devicetree-org/devicetree-specification/releases/tag/v0.3 Signed-off-by: Du Huanpeng --- arch/mips/dts/mt7620.dtsi | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/arch/mips/dts/mt7620.dtsi b/arch/mips/dts/mt7620.dtsi index 03a80b7a70..27a7fbdef2 100644

[PATCH v3] mips: dts: add initial support for ls1c300 SoC

2022-04-18 Thread Du Huanpeng
details: https://www.loongson.cn/ introduce base support for the ls1c300 SoC. - debug UART2 - serial console - clock - watchdog - sysreset - many uarts Signed-off-by: Du Huanpeng --- Changelog for v3: - change cpu clock id from CLK_CPU to CLK_CPU_THROT - migrate all APB dev's clock

[PATCH] tools: add boot/ to .gitignore

2022-04-07 Thread Du Huanpeng
/tools/boot/ is a build product. Add it to .gitignore Signed-off-by: Du Huanpeng --- tools/.gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/.gitignore b/tools/.gitignore index a88453f64d..d3a93ff294 100644 --- a/tools/.gitignore +++ b/tools/.gitignore @@ -36,3 +36,4

Re: [RFC PATCH] mips: dts: add initial support for ls1c300 SoC

2022-04-06 Thread Du Huanpeng
hi, On Thu, Mar 31, 2022 at 01:24:31AM +0200, Daniel Schwierzeck wrote: > Am Mittwoch, dem 30.03.2022 um 03:30 +0800 schrieb Du Huanpeng: > > Loongson 1C is a cost-effective SOC chip for industrial control and > > the Internet of Things. The Loongson 1C includes a floating-point

[RFC PATCH v2] mips: dts: add initial support for ls1c300 SoC

2022-04-05 Thread Du Huanpeng
details: https://www.loongson.cn/ introduce base support for the ls1c300 SoC. - debug UART2 - serial console - clock - watchdog - sysreset - many uarts Signed-off-by: Du Huanpeng --- Changelog for v2: 1. dtsi: add status disabled for uart0 ~ uart11 remove bootargs from chosen

[PATCH] Makefile: add endian link flag to u-boot-elf.o

2022-03-30 Thread Du Huanpeng
From: Du Huanpeng fix compile error when using a little-endian to build with configs: sfr_nb4-ser_ram_defconfig comtrend_wap5813n_ram_defconfig comtrend_ar5387un_ram_defconfig comtrend_ct5361_ram_defconfig comtrend_vr3032u_ram_defconfig

[RFC PATCH] mips: dts: add initial support for ls1c300 SoC

2022-03-29 Thread Du Huanpeng
details: https://www.loongson.cn/ introduce base support for the ls1c300 SoC. - debug UART2 - serial console - clock - watchdog - sysreset - many uarts Signed-off-by: Du Huanpeng --- arch/mips/Kconfig | 25 +++ arch/mips/Makefile| 1

[PATCH] spl: add %z support for tiny-printf

2022-02-14 Thread Du Huanpeng
the %zx format are used in spl from files below: lib/lzma/LzmaTools.c common/malloc_simple.c it results output like "... 0xx", "size=x" output, treat '%z' as '%l' to support `ssize_t' type. Signed-off-by: Du Huanpeng --- lib/tiny-printf.c | 2 +

[PATCH] mips: mtmips: Kconfig: select options used in SPL

2021-02-17 Thread Du Huanpeng
error. add minmal options needed by compile. Signed-off-by: Du Huanpeng --- arch/mips/mach-mtmips/Kconfig | 4 1 file changed, 4 insertions(+) diff --git a/arch/mips/mach-mtmips/Kconfig b/arch/mips/mach-mtmips/Kconfig index 8756cadb..d6ae3a0 100644 --- a/arch/mips/mach-mtmips/Kconfig +++ b

[PATCH] MIPS: introduce `REL_LA' to get label runtime address

2020-11-14 Thread Du Huanpeng
replace PTR_LA in the very begining, e.g. in arch/mips/cpu/start.S arch/mips/lib/cache_init.S to write position independence code. this is helpfull for make single binary can be loaded to different ram/rom addresses. FIXME: only tested on 32 bit system Signed-off-by: Du Huanpeng

[PATCH] gpio: mt7621: remove dependce SOC_MT7628 of MT7621_GPIO

2020-11-01 Thread Du Huanpeng
the help says it is for "MT7621 compatible" GPIOs, but in this Kconfig it depends on MT7628 SoC. this will prevent other SoC to use this driver. Signed-off-by: Du Huanpeng --- drivers/gpio/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpio/Kconfig

[PATCH] mips: dts: tweak codingstyle for adding new boards

2020-10-11 Thread Du Huanpeng
Signed-off-by: Du Huanpeng --- arch/mips/dts/Makefile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/arch/mips/dts/Makefile b/arch/mips/dts/Makefile index dc85901..c07bbc5 100644 --- a/arch/mips/dts/Makefile +++ b/arch/mips/dts/Makefile @@ -1,8 +1,7 @@ # SPDX-License

[U-Boot] [PATCH] Makefile: add a symbol link tags for ctags

2015-05-04 Thread Du Huanpeng
Signed-off-by: Du Huanpeng --- Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/Makefile b/Makefile index bd4abab..68eff1a 100644 --- a/Makefile +++ b/Makefile @@ -1228,6 +1228,7 @@ FINDFLAGS := -L tags ctags: ctags -w -o ctags `$(FIND) $(FINDFLAGS) $(TAG_SUBDIRS

Re: [U-Boot] DECLARE_GLOBAL_DATA_PTR : move from source to Makefile

2014-10-31 Thread Kevin Du Huanpeng
25852 (+86)137 190 74147 2014-10-31 15:22 GMT+08:00 Masahiro Yamada : > Hi Kevin. > > > On Fri, 31 Oct 2014 13:04:38 +0800 > Kevin Du Huanpeng wrote: > >> Hi, all, >> I find this macro is found anywhere in the source, nearly one thousand >> in the source, looks

[U-Boot] DECLARE_GLOBAL_DATA_PTR : move from source to Makefile

2014-10-30 Thread Kevin Du Huanpeng
lude/linux/kconfig.h \ + -include $(srctree)/arch/$(ARCH)/include/asm/global_data.h - - - - ... Du Huanpeng (+86)13719074147 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot