Re: [PATCH] configs: rockchip: rock5a: enable environment

2024-03-05 Thread Trevor Woerner
On Tue 2024-03-05 @ 10:17:10 AM, Jonas Karlman wrote:
> Hi,
> 
> On 2024-03-05 06:40, Eugen Hristev wrote:
> > On 3/5/24 04:10, Trevor Woerner wrote:
> >> Following the pattern of other Rockchip devices, enable the U-Boot
> >> environment to be stored in MMC. This patch specifically assumes the
> >> environment will be stored on the SDcard.
> >>
> >> Signed-off-by: Trevor Woerner 
> >> ---
> >>  configs/rock5a-rk3588s_defconfig | 3 +++
> >>  1 file changed, 3 insertions(+)
> >>
> >> diff --git a/configs/rock5a-rk3588s_defconfig 
> >> b/configs/rock5a-rk3588s_defconfig
> >> index a6471a519514..ac6411667d9a 100644
> >> --- a/configs/rock5a-rk3588s_defconfig
> >> +++ b/configs/rock5a-rk3588s_defconfig
> >> @@ -8,6 +8,7 @@ CONFIG_SPL_LIBGENERIC_SUPPORT=y
> >>  CONFIG_NR_DRAM_BANKS=2
> >>  CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
> >>  CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0xc0
> >> +CONFIG_ENV_SIZE=0x8000
> >>  CONFIG_DEFAULT_DEVICE_TREE="rk3588s-rock-5a"
> >>  CONFIG_ROCKCHIP_RK3588=y
> >>  CONFIG_SPL_ROCKCHIP_COMMON_BOARD=y
> >> @@ -48,6 +49,8 @@ CONFIG_CMD_REGULATOR=y
> >>  CONFIG_SPL_OF_CONTROL=y
> >>  CONFIG_OF_LIVE=y
> >>  CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks 
> >> assigned-clock-rates assigned-clock-parents"
> >> +CONFIG_ENV_IS_IN_MMC=y
> >> +CONFIG_SYS_MMC_ENV_DEV=1
> >>  CONFIG_SPL_DM_SEQ_ALIAS=y
> >>  CONFIG_SPL_REGMAP=y
> >>  CONFIG_SPL_SYSCON=y
> > 
> > 
> > Hi Trevor,
> > 
> > What will happen if there is no Sd-Card, and we boot from eMMC or SPI flash 
> > ?
> 
> Agree, we should not blindly enable env and expect that it can be stored
> on sd-card. If anything, it should preferably be saved/loaded from the
> device where TPL/SPL was booted from.
> 
> Personally I always run my devices with ENV_IS_NOWHERE, with standard
> boot and extlinux or efi as the preferred way to boot, I do not see why
> normal end-users with a single OS really have a need for a saved env,
> please educate me :-)

I am the maintainer of the meta-rockchip Yocto layer[1]. Yocto uses a
nifty tool called 'wic' to layout images (dos/gpt partitioning, optionally
formatting partitions, optionally installing things into those partitions)[2].
The partitioning layout that we follow is the one that is recommended by
Rockchip itself[3] with 2 exceptions:
- we don't hide any of the partitions from the partition table
- we've combined /boot into the root partition (for reasons I'll explain
  later)

Under the Rockchip partitioning, the U-Boot environment is stored in partition
5, at offset 0x0003.f800, and has a size of 0x.8000.

I don't own every Rockchip board, but I have a bunch of them (thanks to some
generous donations!). I've created a spreadsheet that lists the ones supported
by meta-rockchip and their environment variable U-Boot configurations
(locations, offsets, sizes). Most of them follow the Rockchip recommended
partitioning layout with regards to storing the environment. This set of
patches closes that gap, at least for the ones supported by meta-rockchip.

One of the things that I want to do next with meta-rockchip is to provide
an easy way for users to enable some sort of A/B OTA update strategy.
Currently, enabling an A/B update mechanism for any board (Rockchip or not)
is a non-trivial exercise. Every A/B update mechanism that I've looked at
requires (among other things) the bootloader to be able to store/retrieve
its environment from U-Boot itself (obviously) and also from Linux userspace
since it is the bootloader that ultimately boots from either the A or the B
partition. I'm specifically focused on rauc, but all the A/B update mechanisms
I've looked at have this same requirement.

Users who don't care for A/B updates can simply use meta-rockchip as-is, those
who want an A/B strategy would simply enable a setting or two in their Yocto
config and meta-rockchip would take care of the details, regardless of which
Rockchip board they're using.

I've combined /boot into the root partition since it makes A/B updates easier.
Otherwise in order to work it would actually be an Aboot+Aroot/Bboot+Broot
mechanism, which is clumsy. Also since U-Boot is stored in partition by
itself, the only thing in the /boot partition is the U-Boot boot mechanism
(boot script, extlinux, etc), the Linux kernel, and the DTB (or fitImage). In
general it's better to keep the kernel and the root filesystem in sync, so
having a separate /boot partition is clumsy for no gain.

The other nice thing about wic is that it allows us to store random data
(or filesystems) in t

[PATCH] configs: rockchip: rock5b: enable environment

2024-03-04 Thread Trevor Woerner
Following the pattern of other Rockchip devices, enable the U-Boot
environment to be stored in MMC. This patch specifically assumes the
environment will be stored on the SDcard.

Signed-off-by: Trevor Woerner 
---
 configs/rock5b-rk3588_defconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/configs/rock5b-rk3588_defconfig b/configs/rock5b-rk3588_defconfig
index 0595325e8107..64a242003aa1 100644
--- a/configs/rock5b-rk3588_defconfig
+++ b/configs/rock5b-rk3588_defconfig
@@ -60,6 +60,8 @@ CONFIG_CMD_REGULATOR=y
 CONFIG_SPL_OF_CONTROL=y
 CONFIG_OF_LIVE=y
 CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks 
assigned-clock-rates assigned-clock-parents"
+CONFIG_ENV_IS_IN_MMC=y
+CONFIG_SYS_MMC_ENV_DEV=1
 CONFIG_SPL_DM_SEQ_ALIAS=y
 CONFIG_SPL_REGMAP=y
 CONFIG_SPL_SYSCON=y
-- 
2.43.0.76.g1a87c842ece3



[PATCH] configs: rockchip: rock5a: enable environment

2024-03-04 Thread Trevor Woerner
Following the pattern of other Rockchip devices, enable the U-Boot
environment to be stored in MMC. This patch specifically assumes the
environment will be stored on the SDcard.

Signed-off-by: Trevor Woerner 
---
 configs/rock5a-rk3588s_defconfig | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/configs/rock5a-rk3588s_defconfig b/configs/rock5a-rk3588s_defconfig
index a6471a519514..ac6411667d9a 100644
--- a/configs/rock5a-rk3588s_defconfig
+++ b/configs/rock5a-rk3588s_defconfig
@@ -8,6 +8,7 @@ CONFIG_SPL_LIBGENERIC_SUPPORT=y
 CONFIG_NR_DRAM_BANKS=2
 CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0xc0
+CONFIG_ENV_SIZE=0x8000
 CONFIG_DEFAULT_DEVICE_TREE="rk3588s-rock-5a"
 CONFIG_ROCKCHIP_RK3588=y
 CONFIG_SPL_ROCKCHIP_COMMON_BOARD=y
@@ -48,6 +49,8 @@ CONFIG_CMD_REGULATOR=y
 CONFIG_SPL_OF_CONTROL=y
 CONFIG_OF_LIVE=y
 CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks 
assigned-clock-rates assigned-clock-parents"
+CONFIG_ENV_IS_IN_MMC=y
+CONFIG_SYS_MMC_ENV_DEV=1
 CONFIG_SPL_DM_SEQ_ALIAS=y
 CONFIG_SPL_REGMAP=y
 CONFIG_SPL_SYSCON=y
-- 
2.43.0.76.g1a87c842ece3



[PATCH] configs: rockchip: rock3a: enable environment

2024-03-04 Thread Trevor Woerner
Following the pattern of other Rockchip devices, enable the U-Boot
environment to be stored in MMC. This patch specifically assumes the
environment will be stored on the SDcard.

Signed-off-by: Trevor Woerner 
---
 configs/rock-3a-rk3568_defconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/configs/rock-3a-rk3568_defconfig b/configs/rock-3a-rk3568_defconfig
index 28d157dbd7a7..44158a4d34f1 100644
--- a/configs/rock-3a-rk3568_defconfig
+++ b/configs/rock-3a-rk3568_defconfig
@@ -58,6 +58,8 @@ CONFIG_CMD_REGULATOR=y
 CONFIG_SPL_OF_CONTROL=y
 CONFIG_OF_LIVE=y
 CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks 
assigned-clock-rates assigned-clock-parents"
+CONFIG_ENV_IS_IN_MMC=y
+CONFIG_SYS_MMC_ENV_DEV=1
 CONFIG_SPL_DM_SEQ_ALIAS=y
 CONFIG_SPL_REGMAP=y
 CONFIG_SPL_SYSCON=y
-- 
2.43.0.76.g1a87c842ece3



[PATCH] configs: rockchip: rock-pi-s: enable environment

2024-03-04 Thread Trevor Woerner
Following the pattern of other Rockchip devices, enable the U-Boot environment
to be stored in MMC. This patch specifically assumes the environment will be
stored on the SDcard.

Signed-off-by: Trevor Woerner 
---
 configs/rock-pi-s-rk3308_defconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/configs/rock-pi-s-rk3308_defconfig 
b/configs/rock-pi-s-rk3308_defconfig
index 9908a4b4f457..af2cddcc2553 100644
--- a/configs/rock-pi-s-rk3308_defconfig
+++ b/configs/rock-pi-s-rk3308_defconfig
@@ -54,7 +54,9 @@ CONFIG_EFI_PARTITION_ENTRIES_NUMBERS=64
 CONFIG_SPL_OF_CONTROL=y
 CONFIG_OF_LIVE=y
 CONFIG_OF_SPL_REMOVE_PROPS="pinctrl-0 pinctrl-names clock-names 
interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
+CONFIG_ENV_IS_IN_MMC=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
+CONFIG_SYS_MMC_ENV_DEV=1
 CONFIG_REGMAP=y
 CONFIG_SYSCON=y
 CONFIG_CLK=y
-- 
2.43.0.76.g1a87c842ece3



Re: [PATCH 0/2] rockchip: Fix ethernet on Radxa ROCK Pi E v1.21

2024-01-18 Thread Trevor Woerner
Hi Jonas,

On Thu 2024-01-18 @ 07:19:44 AM, Jonas Karlman wrote:
> Ethernet on a Radxa ROCK Pi E v1.21 with a RTL8211F ethernet PHY
> currently fails with the following message:
> 
>   Could not get PHY for ethernet@ff54: addr -1
> 
> This happens because the ethernet PHY is never reset before a phy-id is
> read back from the MDIO bus.
> 
> This series fixes this issue by calling eth_phy_set_mdio_bus() from the
> designware ethernet driver to issue a PHY reset before the phy_connect()
> call.
> 
> With the driver change and DM_ETH_PHY and PHY_REALTEK enabled the PHY
> can be identified and etherent works:
> 
>   => mdio list
>   ethernet@ff54:
>   1 - RealTek RTL8211F <--> ethernet@ff54
> 
> This was tested with and without the DM_MDIO option enabled. Decided to
> leave it disabled in this series.

This works great, thank you! As you suspected, both boards/PHYs work fine now
work under Linux (in addition to U-Boot).

Tested-By: Trevor Woerner 

> Jonas Karlman (2):
>   net: designware: Reset eth phy before phy connect
>   rockchip: rk3328-rock-pi-e: Enable DM_ETH_PHY and PHY_REALTEK
> 
>  configs/rock-pi-e-rk3328_defconfig | 2 ++
>  drivers/net/designware.c   | 7 +++
>  2 files changed, 9 insertions(+)
> 
> -- 
> 2.43.0
> 


Re: [PATCH] am33xx: ignore return value from usb_ether_init()

2023-09-13 Thread Trevor Woerner
On Wed, Sep 13, 2023 at 2:32 PM Tom Rini  wrote:

> On Wed, Sep 13, 2023 at 08:50:49AM -0400, Trevor Woerner wrote:
>
> > Can this get added to the next release? I don't see it in -next.
>
> I was going to pick this up for v2024.01 (i.e. the next branch)
> soon'ish.
>

Awesome, thanks! :-)


Re: [PATCH] am33xx: ignore return value from usb_ether_init()

2023-09-13 Thread Trevor Woerner
Can this get added to the next release? I don't see it in -next.

On Thu, Aug 31, 2023 at 6:15 AM Michal Suchánek  wrote:

> Hello,
>
> On Wed, Aug 30, 2023 at 10:49:50PM -0400, Trevor Woerner wrote:
> > In 2cb43ef1c223 ("usb: ether: Fix error handling in usb_ether_init") the
> error
> > handling of usb_ether_init() was changed. Not a single other call site
> of this
> > function checks its return value, therefore follow suit in the am33xx
> code.
>
> then there is the question what point is there in having a return value
> in this function at all.
>
> Anyway, it's fine to not check the return value in the caller if there
> is no use for the error.
>
> Reviewed-by: Michal Suchánek 
>
> >
> > Do not cause the boot to halt if the usb gadget ethernet initialization
> fails:
> >
> >   initcall sequence 9ffdbd84 failed at call 808024b9 (err=-19)
> >   ### ERROR ### Please RESET the board ###
> >
> > Signed-off-by: Trevor Woerner 
> > ---
> >  arch/arm/mach-omap2/am33xx/board.c | 6 +-
> >  1 file changed, 1 insertion(+), 5 deletions(-)
> >
> > diff --git a/arch/arm/mach-omap2/am33xx/board.c
> b/arch/arm/mach-omap2/am33xx/board.c
> > index ecc0a592e993..8f772310a1a7 100644
> > --- a/arch/arm/mach-omap2/am33xx/board.c
> > +++ b/arch/arm/mach-omap2/am33xx/board.c
> > @@ -270,11 +270,7 @@ int arch_misc_init(void)
> >   return ret;
> >
> >  #if defined(CONFIG_DM_ETH) && defined(CONFIG_USB_ETHER)
> > - ret = usb_ether_init();
> > - if (ret) {
> > - pr_err("USB ether init failed\n");
> > - return ret;
> > - }
> > + usb_ether_init();
> >  #endif
> >
> >   return 0;
> > --
> > 2.41.0.327.gaa9166bcc0ba
> >
>


Re: [PATCH] ARM: dts: am335x-pocketbeagle: choose tick-timer

2023-09-09 Thread Trevor Woerner
On Fri 2023-09-08 @ 12:36:17 PM, Nishanth Menon wrote:
> On 11:25-20230830, Trevor Woerner wrote:
> > Commit 4b2be78ab66c ("time: Fix get_ticks being non-monotonic")
> > requires '/chosen/tick-timer' in device-tree. Otherwise we get:
> > 
> > U-Boot 2023.07.02 (Jul 11 2023 - 15:20:44 +)
> > 
> > CPU  : AM335X-GP rev 2.1
> > Model: TI AM335x PocketBeagle
> > DRAM:  512 MiB
> > Core:  154 devices, 16 uclasses, devicetree: separate
> > Could not initialize timer (err -19)
> > 
> > resetting ...
> > 
> > Suggested-by: Pierre Lebleu 
> > Signed-off-by: Trevor Woerner 
> > ---
> >  arch/arm/dts/am335x-pocketbeagle.dts | 1 +
> >  1 file changed, 1 insertion(+)
> > 
> > diff --git a/arch/arm/dts/am335x-pocketbeagle.dts 
> > b/arch/arm/dts/am335x-pocketbeagle.dts
> > index b379e3a5570d..02e3aac56064 100644
> > --- a/arch/arm/dts/am335x-pocketbeagle.dts
> > +++ b/arch/arm/dts/am335x-pocketbeagle.dts
> > @@ -15,6 +15,7 @@
> >  
> > chosen {
> > stdout-path = &uart0;
> > +   tick-timer = &timer2;
> > };
> >  
> > leds {
> > -- 
> > 2.41.0.327.gaa9166bcc0ba
> > 
> 
> Does enabling CONFIG_SYS_ARCH_TIMER solve this?

Enabling CONFIG_SYS_ARCH_TIMER causes the following compile error:

| arm-oe-linux-gnueabi-ld.bfd: arch/arm/cpu/armv7/arch_timer.o: in 
function `timer_init':
| 
/z/build-master/pocketbeagle/build/tmp-glibc/work/pocketbeagle-oe-linux-gnueabi/u-boot/2023.07.02/git/arch/arm/cpu/armv7/arch_timer.c:29:
 multiple definition of `timer_init'; 
arch/arm/mach-omap2/timer.o:/z/build-master/pocketbeagle/build/tmp-glibc/work/pocketbeagle-oe-linux-gnueabi/u-boot/2023.07.02/git/arch/arm/mach-omap2/timer.c:44:
 first defined here
| arm-oe-linux-gnueabi-ld.bfd: arch/arm/cpu/armv7/arch_timer.o: in 
function `get_ticks':
| 
/z/build-master/pocketbeagle/build/tmp-glibc/work/pocketbeagle-oe-linux-gnueabi/u-boot/2023.07.02/git/arch/arm/cpu/armv7/arch_timer.c:44:
 multiple definition of `get_ticks'; 
arch/arm/mach-omap2/timer.o:/z/build-master/pocketbeagle/build/tmp-glibc/work/pocketbeagle-oe-linux-gnueabi/u-boot/2023.07.02/git/arch/arm/mach-omap2/timer.c:97:
 first defined here
| arm-oe-linux-gnueabi-ld.bfd: arch/arm/cpu/armv7/arch_timer.o: in 
function `get_tbclk':
| 
/z/build-master/pocketbeagle/build/tmp-glibc/work/pocketbeagle-oe-linux-gnueabi/u-boot/2023.07.02/git/arch/arm/cpu/armv7/arch_timer.c:63:
 multiple definition of `get_tbclk'; 
arch/arm/mach-omap2/timer.o:/z/build-master/pocketbeagle/build/tmp-glibc/work/pocketbeagle-oe-linux-gnueabi/u-boot/2023.07.02/git/arch/arm/mach-omap2/timer.c:108:
 first defined here

Without CONFIG_SYS_ARCH_TIMER, the functions timer_init(), get_ticks(), and
get_tbclk() are defined in arch/arm/mach-omap2/timer.c. When
CONFIG_SYS_ARCH_TIMER is defined, it also pulls in the file
arch/arm/cpu/armv7/arch_timer.c.

There is a config option, CONFIG_TIMER, that controls the inclusion of
arch/arm/mach-omap2/timer.c, but it is unconditional during SPL:

arch/arm/mach-omap2/Makefile
...
 12 ifeq ($(CONFIG_TIMER),)
 13 obj-y   += timer.o
 14 else
 15 ifdef CONFIG_SPL_BUILD
 16 obj-y   += timer.o
 17 endif
 18 endif
...

So whether CONFIG_TIMER is defined or not, a compile error will result if
CONFIG_SYS_ARCH_TIMER is also defined.

Getting the code to compile with CONFIG_SYS_ARCH_TIMER would require a deeper
reworking of the configuration/Make logic in order to swap out the functions
in arch/arm/mach-omap2/timer.c for the ones in
arch/arm/cpu/armv7/arch_timer.c. The definitions of those functions in both
those locations are quite different, so even after getting the build to work
there's no guarantee the arch functions would work.

Best regards,
Trevor


[PATCH] am33xx: ignore return value from usb_ether_init()

2023-08-30 Thread Trevor Woerner
In 2cb43ef1c223 ("usb: ether: Fix error handling in usb_ether_init") the error
handling of usb_ether_init() was changed. Not a single other call site of this
function checks its return value, therefore follow suit in the am33xx code.

Do not cause the boot to halt if the usb gadget ethernet initialization fails:

initcall sequence 9ffdbd84 failed at call 808024b9 (err=-19)
### ERROR ### Please RESET the board ###

Signed-off-by: Trevor Woerner 
---
 arch/arm/mach-omap2/am33xx/board.c | 6 +-
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/arch/arm/mach-omap2/am33xx/board.c 
b/arch/arm/mach-omap2/am33xx/board.c
index ecc0a592e993..8f772310a1a7 100644
--- a/arch/arm/mach-omap2/am33xx/board.c
+++ b/arch/arm/mach-omap2/am33xx/board.c
@@ -270,11 +270,7 @@ int arch_misc_init(void)
return ret;
 
 #if defined(CONFIG_DM_ETH) && defined(CONFIG_USB_ETHER)
-   ret = usb_ether_init();
-   if (ret) {
-   pr_err("USB ether init failed\n");
-   return ret;
-   }
+   usb_ether_init();
 #endif
 
return 0;
-- 
2.41.0.327.gaa9166bcc0ba



[PATCH] ARM: dts: am335x-pocketbeagle: choose tick-timer

2023-08-30 Thread Trevor Woerner
Commit 4b2be78ab66c ("time: Fix get_ticks being non-monotonic")
requires '/chosen/tick-timer' in device-tree. Otherwise we get:

U-Boot 2023.07.02 (Jul 11 2023 - 15:20:44 +)

CPU  : AM335X-GP rev 2.1
Model: TI AM335x PocketBeagle
DRAM:  512 MiB
Core:  154 devices, 16 uclasses, devicetree: separate
Could not initialize timer (err -19)

resetting ...

Suggested-by: Pierre Lebleu 
Signed-off-by: Trevor Woerner 
---
 arch/arm/dts/am335x-pocketbeagle.dts | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/dts/am335x-pocketbeagle.dts 
b/arch/arm/dts/am335x-pocketbeagle.dts
index b379e3a5570d..02e3aac56064 100644
--- a/arch/arm/dts/am335x-pocketbeagle.dts
+++ b/arch/arm/dts/am335x-pocketbeagle.dts
@@ -15,6 +15,7 @@
 
chosen {
stdout-path = &uart0;
+   tick-timer = &timer2;
};
 
leds {
-- 
2.41.0.327.gaa9166bcc0ba



Re: rock960c

2021-07-12 Thread Trevor Woerner
On Mon 2021-07-12 @ 07:54:44 AM, Peter Robinson wrote:
> On Tue, Jul 6, 2021 at 8:03 AM Trevor Woerner  wrote:
> >
> > Hi,
> >
> > I was hoping that one day support would be added for the rockchip rock960c
> > board (from the 96boards series, 
> > https://www.96boards.org/product/rock960c/).
> > NOTE: this board is different from the rock960 board (aka rock960 a/b) that 
> > is
> > currently supported.
> >
> > Schematics and datasheets aren't easy to come by. A while back someone
> > mentioned that the only difference between the rock960 a/b and the rock960c 
> > is
> > that the rock960c uses different SDRAM (LPDDR4 instead of LPDDR3). Searching
> > around on the Internet it would appear that the rock960c uses the same SDRAM
> > as the rock-pi-4 devices (maybe?).
> 
> I don't think it has a USB-C port, nor a onboard eMMC, although from
> memory it does have a header.

It does have a USB-C port (although I'm using the separate 12V plug for power)
but you're right about the rest (it doesn't have onboard eMMC, but does have a
header if the user wants to populate one).

> > The actual SDRAM on the board is H9HCNNN4KUML-HRNMN, but I can't find a
> > datasheet for it anywhere, not even on Hynix's website.
> >
> > I tried creating a rock960c device by copying the rock960 things. The one
> > change I made was that my rk3399-rock960c-u-boot.dtsi file has:
> >
> > #include "rk3399-sdram-lpddr4-100.dtsi"
> >
> > (which is what the rock-pi-4 is using) instead of:
> >
> > #include "rk3399-sdram-lpddr3-2GB-1600.dtsi"
> 
> You'll probably need to add/update a DDR line in the config file as well.

Okay, I'll take a second look.

> > (which is what rk3399-rock960-u-boot.dtsi is using). Unfortunately this
> > doesn't succeed. The TPL is invoked, then there's nothing else on the 
> > console:
> >
> > U-Boot TPL 2021.04 (Jun 30 2021 - 18:16:57)
> >
> > I then tried building and using the vendor-supplied u-boot fork for the
> > rock960c which is found here:
> >
> > git://github.com/96rocks/u-boot.git
> >
> > but it is quite old (U-Boot 2017.09) and pre-dates the TPL/idbloader things.
> > If I understand things correctly, the vendor branch only builds u-boot and 
> > the
> > spl, I then need to mash in some sort of binary ddr file to the spl to get a
> > working first-stage bootloader (?). I'm unclear how to take the build output
> > from the vendor branch and create a working bootloader to load on my sdcard
> > (the only docs for the rk3399 in that branch are generic and don't refer to
> > things that come out of the build for the rock960c).
> 
> I personally wouldn't waste your time with the vendor one, I would
> think everything needed is already upstream for the core support.

Agreed. The vendor branch is so old I don't think it is useful anymore. Best
to just start with U-Boot master and tweak from there.

> > In any case, if anyone has any any tips etc I'd appreciate it :-)
> 
> There's not an upstream dts either, which probably isn't a big issue
> for the basics. I don't remember whether or not if I have a revC of
> these boards somewhere, I can't promise timing wise but if I get a
> moment I'll see if I can work out if I have one.

Sounds good, thanks! :-)


Re: [PATCH] get_maintainer.pl: update from Linux kernel v5.13-rc6

2021-07-08 Thread Trevor Woerner
ping?

Tom, have you had a chance to try out this update?

On Tue, Jun 15, 2021 at 3:30 AM Trevor Woerner  wrote:

> Update U-Boot's version of scripts/get_maintainer.pl to sync it up with
> the
> latest changes to the Linux kernel's version of the same script.
>
> The last sync was with Linux kernel version v4.16. The commits to the
> kernel's
> get_maintainer.pl since then (starting with the most recent) are:
>
> 6343f6b71f83 get_maintainer: exclude MAINTAINERS file(s) from
> --git-fallback
> cdfe2d220476 get_maintainer: add test for file in VCS
> e33c9fe8b80c get_maintainer: fix unexpected behavior for
> path/to//file (double slashes)
> 0c78c0137621 get_maintainer: add email addresses from .yaml files
> 0ef82fcefb99 scripts/get_maintainer.pl: deprioritize old Fixes:
> addresses
> ef0c08192ac0 get_maintainer: remove uses of P: for maintainer name
> 2f5bd343694e scripts/get_maintainer.pl: add signatures from
> Fixes:  lines in commit message
> 49662503e8e4 get_maintainer: add ability to skip moderated mailing
> lists
> 0fbd75fd7fee get_maintainer: allow option --mpath  to
> read all files in 
> 5f0baf95b1ed get_maintainer.pl: add -mpath= for
> MAINTAINERS file location
> 31bb82c9caa9 get_maintainer: allow usage outside of kernel tree
> 0455c74788fd get_maintainer: improve patch recognition
>     882ea1d64eb3 scripts: use SPDX tag in get_maintainer and checkpatch
>
> Signed-off-by: Trevor Woerner 
> ---
>  scripts/get_maintainer.pl | 204 +-
>  1 file changed, 134 insertions(+), 70 deletions(-)
>
> diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
> index e3b41616c9..81116e215e 100755
> --- a/scripts/get_maintainer.pl
> +++ b/scripts/get_maintainer.pl
> @@ -1,4 +1,6 @@
>  #!/usr/bin/env perl
> +# SPDX-License-Identifier: GPL-2.0
> +#
>  # (c) 2007, Joe Perches 
>  #   created from checkpatch.pl
>  #
> @@ -7,8 +9,6 @@
>  #
>  # usage: perl scripts/get_maintainer.pl [OPTIONS] 
>  #perl scripts/get_maintainer.pl [OPTIONS] -f 
> -#
> -# Licensed under the terms of the GNU GPL License version 2
>
>  use warnings;
>  use strict;
> @@ -19,6 +19,7 @@ my $V = '0.26';
>  use Getopt::Long qw(:config no_auto_abbrev);
>  use Cwd;
>  use File::Find;
> +use File::Spec::Functions;
>
>  my $cur_path = fastgetcwd() . '/';
>  my $lk_path = "./";
> @@ -26,7 +27,9 @@ my $email = 1;
>  my $email_usename = 1;
>  my $email_maintainer = 1;
>  my $email_reviewer = 1;
> +my $email_fixes = 1;
>  my $email_list = 1;
> +my $email_moderated_list = 1;
>  my $email_subscriber_list = 0;
>  my $email_git_penguin_chiefs = 0;
>  my $email_git = 0;
> @@ -48,24 +51,31 @@ my $output_roles = 0;
>  my $output_rolestats = 1;
>  my $output_section_maxlen = 50;
>  my $scm = 0;
> +my $tree = 1;
>  my $web = 0;
>  my $subsystem = 0;
>  my $status = 0;
>  my $letters = "";
>  my $keywords = 1;
>  my $sections = 0;
> -my $file_emails = 0;
> +my $email_file_emails = 0;
>  my $from_filename = 0;
>  my $pattern_depth = 0;
>  my $self_test = undef;
>  my $version = 0;
>  my $help = 0;
> -my $find_maintainer_files = 1;
> -
> +my $find_maintainer_files = 0;
> +my $maintainer_path;
>  my $vcs_used = 0;
>
>  my $exit = 0;
>
> +my @files = ();
> +my @fixes = ();# If a patch description includes
> Fixes: lines
> +my @range = ();
> +my @keyword_tvi = ();
> +my @file_emails = ();
> +
>  my %commit_author_hash;
>  my %commit_signer_hash;
>
> @@ -245,6 +255,8 @@ if (!GetOptions(
> 'r!' => \$email_reviewer,
> 'n!' => \$email_usename,
> 'l!' => \$email_list,
> +   'fixes!' => \$email_fixes,
> +   'moderated!' => \$email_moderated_list,
> 's!' => \$email_subscriber_list,
> 'multiline!' => \$output_multiline,
> 'roles!' => \$output_roles,
> @@ -253,14 +265,16 @@ if (!GetOptions(
> 'subsystem!' => \$subsystem,
> 'status!' => \$status,
> 'scm!' => \$scm,
> +   'tree!' => \$tree,
> 'web!' => \$web,
> 'letters=s' => \$letters,
> 'pattern-depth=i' => \$pattern_depth,
> 'k|keywords!' => \$keywords,
> &

Re: [ANN] U-Boot v2021.07 released

2021-07-06 Thread Trevor Woerner
On Tue, Jul 6, 2021 at 9:06 AM Tom Rini  wrote:

> On Tue, Jul 06, 2021 at 02:41:45AM -0400, Trevor Woerner wrote:
> > On Mon, Jul 5, 2021 at 11:13 AM Tom Rini  wrote:
> >
> > > It is release day and here is the v2021.07 release.
> > >
> > > The merge window is once again open and I plan to tag -rc1 on Monday,
> > > July 26th, bi-weekly -rcs thereafter and final release on October 4th,
> > > 2021.
> > >
> > > I am merging the next branch to master shortly and will send a separate
> > > email when that is done.
> > >
> >
> > Is there something I forgot to do in order to get my lpc32xx series in?
> > https://patchwork.ozlabs.org/project/uboot/list/?series=248264
>
> A good question.  I had hoped to get a chance to pickup platform stuff
> for next, but did not.  My plan right now is:
> - General CI updates (now in)
> - Update to gcc-11/clang-11 (I know clang-12 is out, but, one step at a
>   time) which I'm testing now.
> - Platform updates
> - Kick-around how USB_HOST is used, to deal with the DM_USB migration
>   deadline warning for Nokia N900
> - Platform removals
>

Great, thanks for the update :-)


rock960c

2021-07-06 Thread Trevor Woerner
Hi,

I was hoping that one day support would be added for the rockchip rock960c
board (from the 96boards series, https://www.96boards.org/product/rock960c/).
NOTE: this board is different from the rock960 board (aka rock960 a/b) that is
currently supported.

Schematics and datasheets aren't easy to come by. A while back someone
mentioned that the only difference between the rock960 a/b and the rock960c is
that the rock960c uses different SDRAM (LPDDR4 instead of LPDDR3). Searching
around on the Internet it would appear that the rock960c uses the same SDRAM
as the rock-pi-4 devices (maybe?).

The actual SDRAM on the board is H9HCNNN4KUML-HRNMN, but I can't find a
datasheet for it anywhere, not even on Hynix's website.

I tried creating a rock960c device by copying the rock960 things. The one
change I made was that my rk3399-rock960c-u-boot.dtsi file has:

#include "rk3399-sdram-lpddr4-100.dtsi"

(which is what the rock-pi-4 is using) instead of:

#include "rk3399-sdram-lpddr3-2GB-1600.dtsi"

(which is what rk3399-rock960-u-boot.dtsi is using). Unfortunately this
doesn't succeed. The TPL is invoked, then there's nothing else on the console:

U-Boot TPL 2021.04 (Jun 30 2021 - 18:16:57)

I then tried building and using the vendor-supplied u-boot fork for the
rock960c which is found here:

git://github.com/96rocks/u-boot.git

but it is quite old (U-Boot 2017.09) and pre-dates the TPL/idbloader things.
If I understand things correctly, the vendor branch only builds u-boot and the
spl, I then need to mash in some sort of binary ddr file to the spl to get a
working first-stage bootloader (?). I'm unclear how to take the build output
from the vendor branch and create a working bootloader to load on my sdcard
(the only docs for the rk3399 in that branch are generic and don't refer to
things that come out of the build for the rock960c).

In any case, if anyone has any any tips etc I'd appreciate it :-)

Best regards,
Trevor


Re: [ANN] U-Boot v2021.07 released

2021-07-05 Thread Trevor Woerner
On Mon, Jul 5, 2021 at 11:13 AM Tom Rini  wrote:

> It is release day and here is the v2021.07 release.
>
> The merge window is once again open and I plan to tag -rc1 on Monday,
> July 26th, bi-weekly -rcs thereafter and final release on October 4th,
> 2021.
>
> I am merging the next branch to master shortly and will send a separate
> email when that is done.
>

Is there something I forgot to do in order to get my lpc32xx series in?
https://patchwork.ozlabs.org/project/uboot/list/?series=248264


[PATCH] get_maintainer.pl: update from Linux kernel v5.13-rc6

2021-06-15 Thread Trevor Woerner
Update U-Boot's version of scripts/get_maintainer.pl to sync it up with the
latest changes to the Linux kernel's version of the same script.

The last sync was with Linux kernel version v4.16. The commits to the kernel's
get_maintainer.pl since then (starting with the most recent) are:

6343f6b71f83 get_maintainer: exclude MAINTAINERS file(s) from 
--git-fallback
cdfe2d220476 get_maintainer: add test for file in VCS
e33c9fe8b80c get_maintainer: fix unexpected behavior for path/to//file 
(double slashes)
0c78c0137621 get_maintainer: add email addresses from .yaml files
0ef82fcefb99 scripts/get_maintainer.pl: deprioritize old Fixes: 
addresses
ef0c08192ac0 get_maintainer: remove uses of P: for maintainer name
2f5bd343694e scripts/get_maintainer.pl: add signatures from Fixes: 
 lines in commit message
49662503e8e4 get_maintainer: add ability to skip moderated mailing lists
0fbd75fd7fee get_maintainer: allow option --mpath  to read 
all files in 
5f0baf95b1ed get_maintainer.pl: add -mpath= for 
MAINTAINERS file location
31bb82c9caa9 get_maintainer: allow usage outside of kernel tree
0455c74788fd get_maintainer: improve patch recognition
882ea1d64eb3 scripts: use SPDX tag in get_maintainer and checkpatch

Signed-off-by: Trevor Woerner 
---
 scripts/get_maintainer.pl | 204 +-
 1 file changed, 134 insertions(+), 70 deletions(-)

diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
index e3b41616c9..81116e215e 100755
--- a/scripts/get_maintainer.pl
+++ b/scripts/get_maintainer.pl
@@ -1,4 +1,6 @@
 #!/usr/bin/env perl
+# SPDX-License-Identifier: GPL-2.0
+#
 # (c) 2007, Joe Perches 
 #   created from checkpatch.pl
 #
@@ -7,8 +9,6 @@
 #
 # usage: perl scripts/get_maintainer.pl [OPTIONS] 
 #perl scripts/get_maintainer.pl [OPTIONS] -f 
-#
-# Licensed under the terms of the GNU GPL License version 2
 
 use warnings;
 use strict;
@@ -19,6 +19,7 @@ my $V = '0.26';
 use Getopt::Long qw(:config no_auto_abbrev);
 use Cwd;
 use File::Find;
+use File::Spec::Functions;
 
 my $cur_path = fastgetcwd() . '/';
 my $lk_path = "./";
@@ -26,7 +27,9 @@ my $email = 1;
 my $email_usename = 1;
 my $email_maintainer = 1;
 my $email_reviewer = 1;
+my $email_fixes = 1;
 my $email_list = 1;
+my $email_moderated_list = 1;
 my $email_subscriber_list = 0;
 my $email_git_penguin_chiefs = 0;
 my $email_git = 0;
@@ -48,24 +51,31 @@ my $output_roles = 0;
 my $output_rolestats = 1;
 my $output_section_maxlen = 50;
 my $scm = 0;
+my $tree = 1;
 my $web = 0;
 my $subsystem = 0;
 my $status = 0;
 my $letters = "";
 my $keywords = 1;
 my $sections = 0;
-my $file_emails = 0;
+my $email_file_emails = 0;
 my $from_filename = 0;
 my $pattern_depth = 0;
 my $self_test = undef;
 my $version = 0;
 my $help = 0;
-my $find_maintainer_files = 1;
-
+my $find_maintainer_files = 0;
+my $maintainer_path;
 my $vcs_used = 0;
 
 my $exit = 0;
 
+my @files = ();
+my @fixes = ();# If a patch description includes 
Fixes: lines
+my @range = ();
+my @keyword_tvi = ();
+my @file_emails = ();
+
 my %commit_author_hash;
 my %commit_signer_hash;
 
@@ -245,6 +255,8 @@ if (!GetOptions(
'r!' => \$email_reviewer,
'n!' => \$email_usename,
'l!' => \$email_list,
+   'fixes!' => \$email_fixes,
+   'moderated!' => \$email_moderated_list,
's!' => \$email_subscriber_list,
'multiline!' => \$output_multiline,
'roles!' => \$output_roles,
@@ -253,14 +265,16 @@ if (!GetOptions(
'subsystem!' => \$subsystem,
'status!' => \$status,
'scm!' => \$scm,
+   'tree!' => \$tree,
'web!' => \$web,
'letters=s' => \$letters,
'pattern-depth=i' => \$pattern_depth,
'k|keywords!' => \$keywords,
'sections!' => \$sections,
-   'fe|file-emails!' => \$file_emails,
+   'fe|file-emails!' => \$email_file_emails,
'f|file' => \$from_filename,
'find-maintainer-files' => \$find_maintainer_files,
+   'mpath|maintainer-path=s' => \$maintainer_path,
'self-test:s' => \$self_test,
'v|version' => \$version,
'h|help|usage' => \$help,
@@ -317,7 +331,7 @@ if ($email &&
 die "$P: Please select at least 1 email option\n";
 }
 
-if (!top_of_kernel_tree($lk_path)) {
+if ($tree 

Re: [PATCH] scripts/get_maintainer.pl: obey ignore list

2021-06-11 Thread Trevor Woerner
Hi Tom,

On Fri 2021-06-11 @ 10:23:01 AM, Tom Rini wrote:
> On Thu, Jun 10, 2021 at 11:37:27PM -0400, Trevor Woerner wrote:
> 
> > If the user creates a .get_maintainer.ignore file, make sure it is consulted
> > and obeyed for *all* emails discovered by the script.
> > 
> > Signed-off-by: Trevor Woerner 
> > ---
> >  scripts/get_maintainer.pl | 1 +
> >  1 file changed, 1 insertion(+)
> > 
> > diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
> > index e3b41616c9..8c0fb8656e 100755
> > --- a/scripts/get_maintainer.pl
> > +++ b/scripts/get_maintainer.pl
> > @@ -2435,6 +2435,7 @@ sub merge_email {
> >  
> >  for (@_) {
> > my ($address, $role) = @$_;
> > +   next if (ignore_email_address($address));
> > if (!$saw{$address}) {
> > if ($output_roles) {
> > push(@lines, "$address ($role)");
> 
> This got me to check and see that yes, our copy of get_maintainers.pl is
> out of date from Linux.  And in fact, a re-sync will let us add a
> .get_maintainer.conf file and use upstream a lot more closely as it now
> has logic to find all MAINTAINERS files in a tree.
> 
> But this change isn't upstream.  Please work with Joe Perches upstream
> to get this change accepted and it'll flow down to us and not get
> overwritten when I forget it was an intentional change :)  Thanks!

Thanks for the tip!

I ran my patches through the kernel's latest get_maintainer.pl script and it
correctly removes email entries that are listed in my ~/.get_maintainer.ignore
file without any changes required. Therefore a re-sync would appear to fix the
issue I found.

I can take a look at the re-sync if you wish? It's unclear to me whether
you're looking into the re-sync or not.

Best regards,
Trevor


[PATCH] scripts/get_maintainer.pl: obey ignore list

2021-06-10 Thread Trevor Woerner
If the user creates a .get_maintainer.ignore file, make sure it is consulted
and obeyed for *all* emails discovered by the script.

Signed-off-by: Trevor Woerner 
---
 scripts/get_maintainer.pl | 1 +
 1 file changed, 1 insertion(+)

diff --git a/scripts/get_maintainer.pl b/scripts/get_maintainer.pl
index e3b41616c9..8c0fb8656e 100755
--- a/scripts/get_maintainer.pl
+++ b/scripts/get_maintainer.pl
@@ -2435,6 +2435,7 @@ sub merge_email {
 
 for (@_) {
my ($address, $role) = @$_;
+   next if (ignore_email_address($address));
if (!$saw{$address}) {
if ($output_roles) {
push(@lines, "$address ($role)");
-- 
2.30.0.rc0



[PATCH v2 7/8] Kconfig: convert CONFIG_SYS_I2C_LPC32XX

2021-06-10 Thread Trevor Woerner
Convert the CONFIG_SYS_I2C_LPC32XX configuration symbol from an include
directive to a Kconfig value.

Signed-off-by: Trevor Woerner 

---

Changes in v2:
- added

 configs/devkit3250_defconfig | 1 +
 configs/work_92105_defconfig | 1 +
 drivers/i2c/Kconfig  | 6 ++
 include/configs/devkit3250.h | 1 -
 include/configs/work_92105.h | 1 -
 scripts/config_whitelist.txt | 1 -
 6 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/configs/devkit3250_defconfig b/configs/devkit3250_defconfig
index 9ae70f7d46..c0354bce1a 100644
--- a/configs/devkit3250_defconfig
+++ b/configs/devkit3250_defconfig
@@ -38,6 +38,7 @@ CONFIG_CMD_JFFS2=y
 CONFIG_ENV_IS_IN_NAND=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
 CONFIG_VERSION_VARIABLE=y
+CONFIG_SYS_I2C_LPC32XX=y
 # CONFIG_MMC is not set
 CONFIG_MTD=y
 CONFIG_MTD_NOR_FLASH=y
diff --git a/configs/work_92105_defconfig b/configs/work_92105_defconfig
index e9605adedd..507f24fc37 100644
--- a/configs/work_92105_defconfig
+++ b/configs/work_92105_defconfig
@@ -42,6 +42,7 @@ CONFIG_DOS_PARTITION=y
 CONFIG_ENV_IS_IN_NAND=y
 CONFIG_SYS_REDUNDAND_ENVIRONMENT=y
 CONFIG_VERSION_VARIABLE=y
+CONFIG_SYS_I2C_LPC32XX=y
 # CONFIG_MMC is not set
 CONFIG_MTD=y
 CONFIG_MTD_RAW_NAND=y
diff --git a/drivers/i2c/Kconfig b/drivers/i2c/Kconfig
index 57a4efb88e..674faddfa4 100644
--- a/drivers/i2c/Kconfig
+++ b/drivers/i2c/Kconfig
@@ -169,6 +169,12 @@ config SYS_I2C_IMX_LPI2C
help
  Add support for the NXP i.MX LPI2C driver.
 
+config SYS_I2C_LPC32XX
+   bool "LPC32XX I2C driver"
+   depends on ARCH_LPC32XX
+   help
+ Enable support for the LPC32xx I2C driver.
+
 config SYS_I2C_MESON
bool "Amlogic Meson I2C driver"
depends on DM_I2C && ARCH_MESON
diff --git a/include/configs/devkit3250.h b/include/configs/devkit3250.h
index 921a38c01e..465d9ce8e9 100644
--- a/include/configs/devkit3250.h
+++ b/include/configs/devkit3250.h
@@ -41,7 +41,6 @@
  * I2C
  */
 #define CONFIG_SYS_I2C
-#define CONFIG_SYS_I2C_LPC32XX
 #define CONFIG_SYS_I2C_SPEED   10
 
 /*
diff --git a/include/configs/work_92105.h b/include/configs/work_92105.h
index 076a1b065e..d498c8f3bc 100644
--- a/include/configs/work_92105.h
+++ b/include/configs/work_92105.h
@@ -47,7 +47,6 @@
  * I2C driver
  */
 
-#define CONFIG_SYS_I2C_LPC32XX
 #define CONFIG_SYS_I2C
 #define CONFIG_SYS_I2C_SPEED 35
 
diff --git a/scripts/config_whitelist.txt b/scripts/config_whitelist.txt
index 13281bf6b1..60ec9834f9 100644
--- a/scripts/config_whitelist.txt
+++ b/scripts/config_whitelist.txt
@@ -2543,7 +2543,6 @@ CONFIG_SYS_I2C_INIT_BOARD
 CONFIG_SYS_I2C_LDI_ADDR
 CONFIG_SYS_I2C_LM75_ADDR
 CONFIG_SYS_I2C_LM90_ADDR
-CONFIG_SYS_I2C_LPC32XX
 CONFIG_SYS_I2C_LPC32XX_SLAVE
 CONFIG_SYS_I2C_LPC32XX_SPEED
 CONFIG_SYS_I2C_MAC1_BUS
-- 
2.30.0.rc0



[PATCH v2 8/8] lpc32xx: ea-lpc3250devkitv2: enable i2c (DM)

2021-06-10 Thread Trevor Woerner
Enable a DMed i2c driver for the ea-lpc3250devkitv2 board.
Include some sample commands/output for testing.

Signed-off-by: Trevor Woerner 

---

Changes in v2:
- added

 board/ea/ea-lpc3250devkitv2/README.rst| 54 +++
 .../ea-lpc3250devkitv2/ea-lpc3250devkitv2.c   |  4 ++
 configs/ea-lpc3250devkitv2_defconfig  |  3 ++
 3 files changed, 61 insertions(+)

diff --git a/board/ea/ea-lpc3250devkitv2/README.rst 
b/board/ea/ea-lpc3250devkitv2/README.rst
index 56b5d0dbb1..1b78000331 100644
--- a/board/ea/ea-lpc3250devkitv2/README.rst
+++ b/board/ea/ea-lpc3250devkitv2/README.rst
@@ -4,6 +4,7 @@ ToC:
 - Introduction
 - Booting
 - Debugging
+- i2c
 
 
 Introduction
@@ -130,3 +131,56 @@ dongle from Olimex successfully as follows:
# openocd \
-f interface/ftdi/olimex-arm-usb-ocd-h.cfg \
-f board/phytec_lpc3250.cfg
+
+
+i2c
+===
+Some of the LEDs on the board are connected via an I/O Expander (PCA9532) that
+is attached to the i2c1 bus. Here is a sample session of toggling some of
+these LEDs via i2c in U-Boot:
+
+show the existing i2c busses:
+   EA-LPC3250v2=> i2c bus
+   Bus 0:  i2c@300
+   Bus 1:  i2c@400a
+   Bus 2:  i2c@400a8000
+
+set i2c1 as the current bus:
+   EA-LPC3250v2=> i2c dev 1
+   Setting bus to 1
+
+see what potential devices are found with rudimentary probing on i2c1:
+   EA-LPC3250v2=> i2c probe
+   Valid chip addresses: 1A 1D 48 50 57 60 66 6E
+
+According to the schematics the i2c slave address of the PCA9532 is 0x60.
+
+dump all of the 10 registers from the I/O Expander; NOTE that the 0x10 in the
+command specifies the self-incrementing mode of the PCA9532; also NOTE that
+the values repeat themseves to fill out a full 16 bytes:
+   EA-LPC3250v2=> i2c md 0x60 0x10 10
+   0010: 00 ff 00 80 00 80 00 00 00 00 4f ff 00 80 00 80
..O.
+
+turn on LEDs 23, 25, 27, and 29 (green):
+   EA-LPC3250v2=> i2c mw 0x60 9 0x55
+
+turn on LEDs 22, 24, 26, and 28 (red):
+   EA-LPC3250v2=> i2c mw 0x60 8 0x55
+
+dim the green LEDs (23, 25, 27, 29):
+   EA-LPC3250v2=> i2c mw 0x60 3 0x20
+   EA-LPC3250v2=> i2c mw 0x60 9 0xaa
+
+turn off all LEDs (23-29):
+   EA-LPC3250v2=> i2c mw 0x60 8 0
+   EA-LPC3250v2=> i2c mw 0x60 9 0
+
+read value of switches (input):
+   EA-LPC3250v2=> i2c md 0x60 0 1
+   : 4fO
+[none are pressed]
+
+press and hold SW2 while running the following:
+   EA-LPC3250v2=> i2c md 0x60 0 1
+   : 4eN
+[SW2 is pressed]
diff --git a/board/ea/ea-lpc3250devkitv2/ea-lpc3250devkitv2.c 
b/board/ea/ea-lpc3250devkitv2/ea-lpc3250devkitv2.c
index 7a19400041..72cf46c749 100644
--- a/board/ea/ea-lpc3250devkitv2/ea-lpc3250devkitv2.c
+++ b/board/ea/ea-lpc3250devkitv2/ea-lpc3250devkitv2.c
@@ -19,6 +19,10 @@ int
 board_early_init_f(void)
 {
lpc32xx_uart_init(CONFIG_CONS_INDEX);
+   if (IS_ENABLED(CONFIG_SYS_I2C_LPC32XX)) {
+   lpc32xx_i2c_init(1);
+   lpc32xx_i2c_init(2);
+   }
return 0;
 }
 
diff --git a/configs/ea-lpc3250devkitv2_defconfig 
b/configs/ea-lpc3250devkitv2_defconfig
index dc90e16475..e8d60b573e 100644
--- a/configs/ea-lpc3250devkitv2_defconfig
+++ b/configs/ea-lpc3250devkitv2_defconfig
@@ -14,9 +14,12 @@ CONFIG_DISTRO_DEFAULTS=y
 CONFIG_BOARD_EARLY_INIT_F=y
 CONFIG_SYS_PROMPT="EA-LPC3250v2=> "
 CONFIG_CMD_GPIO=y
+CONFIG_CMD_I2C=y
 CONFIG_OF_CONTROL=y
 # CONFIG_NET is not set
 CONFIG_LPC32XX_GPIO=y
+CONFIG_DM_I2C=y
+CONFIG_SYS_I2C_LPC32XX=y
 CONFIG_SPECIFY_CONSOLE_INDEX=y
 CONFIG_CONS_INDEX=5
 CONFIG_SYS_NS16550=y
-- 
2.30.0.rc0



[PATCH v2 6/8] lpc32xx: i2c: finish DM/OF code

2021-06-10 Thread Trevor Woerner
Add the of_match/compatible string to the lpc32xx i2c driver so it works
correctly with device-tree.

Signed-off-by: Trevor Woerner 

---

Changes in v2:
- added

 drivers/i2c/lpc32xx_i2c.c | 8 +++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/drivers/i2c/lpc32xx_i2c.c b/drivers/i2c/lpc32xx_i2c.c
index 6abff263bd..774129ad8e 100644
--- a/drivers/i2c/lpc32xx_i2c.c
+++ b/drivers/i2c/lpc32xx_i2c.c
@@ -348,9 +348,15 @@ static const struct dm_i2c_ops lpc32xx_i2c_ops = {
.set_bus_speed = lpc32xx_i2c_set_bus_speed,
 };
 
+static const struct udevice_id lpc32xx_i2c_ids[] = {
+   { .compatible = "nxp,pnx-i2c" },
+   { }
+};
+
 U_BOOT_DRIVER(i2c_lpc32xx) = {
-   .id   = UCLASS_I2C,
.name = "i2c_lpc32xx",
+   .id   = UCLASS_I2C,
+   .of_match = lpc32xx_i2c_ids,
.probe= lpc32xx_i2c_probe,
.ops  = &lpc32xx_i2c_ops,
 };
-- 
2.30.0.rc0



[PATCH v2 5/8] lpc32xx: i2c: fix base address

2021-06-10 Thread Trevor Woerner
The lpc32xx driver was not obtaining the per-device base address correctly
from the device tree. Fix the FIXME in order to get the correct base address.

Signed-off-by: Trevor Woerner 

---

Changes in v2:
- added

 drivers/i2c/lpc32xx_i2c.c | 6 +-
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/drivers/i2c/lpc32xx_i2c.c b/drivers/i2c/lpc32xx_i2c.c
index 0ae116617c..6abff263bd 100644
--- a/drivers/i2c/lpc32xx_i2c.c
+++ b/drivers/i2c/lpc32xx_i2c.c
@@ -282,11 +282,7 @@ static int lpc32xx_i2c_probe(struct udevice *bus)
 {
struct lpc32xx_i2c_dev *dev = dev_get_plat(bus);
 
-   /*
-* FIXME: This is not permitted
-*  dev_seq(bus) = dev->index;
-*/
-
+   dev->base = dev_read_addr_ptr(bus);
__i2c_init(dev->base, dev->speed, 0, dev->index);
return 0;
 }
-- 
2.30.0.rc0



[PATCH v2 4/8] lpc32xx: i2c: remove unused define

2021-06-10 Thread Trevor Woerner
The LPC32XX_I2C_STAT_DRMI is not used anywhere so remove it.

Signed-off-by: Trevor Woerner 

---

Changes in v2:
- added

 drivers/i2c/lpc32xx_i2c.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/i2c/lpc32xx_i2c.c b/drivers/i2c/lpc32xx_i2c.c
index f89f7955e4..0ae116617c 100644
--- a/drivers/i2c/lpc32xx_i2c.c
+++ b/drivers/i2c/lpc32xx_i2c.c
@@ -38,7 +38,6 @@
 /* Status register values */
 #define LPC32XX_I2C_STAT_TFF   0x0400
 #define LPC32XX_I2C_STAT_RFE   0x0200
-#define LPC32XX_I2C_STAT_DRMI  0x0008
 #define LPC32XX_I2C_STAT_NAI   0x0004
 #define LPC32XX_I2C_STAT_TDI   0x0001
 
-- 
2.30.0.rc0



[PATCH v2 3/8] arm: lpc32xx: add EA LPC3250 DevKitv2 board support

2021-06-10 Thread Trevor Woerner
Add basic support for running U-Boot on the Embedded Artists LPC3250
Developer's Kit v2 board by launching U-Boot from the board's s1l loader
(which comes pre-installed on the board).

Signed-off-by: Trevor Woerner 
---

(no changes since v1)

 arch/arm/dts/Makefile |   2 +
 arch/arm/dts/lpc3250-ea3250-u-boot.dtsi   |  15 ++
 arch/arm/mach-lpc32xx/Kconfig |   4 +
 board/ea/ea-lpc3250devkitv2/Kconfig   |  15 ++
 board/ea/ea-lpc3250devkitv2/MAINTAINERS   |   9 ++
 board/ea/ea-lpc3250devkitv2/Makefile  |   4 +
 board/ea/ea-lpc3250devkitv2/README.rst| 132 ++
 .../ea-lpc3250devkitv2/ea-lpc3250devkitv2.c   |  37 +
 configs/ea-lpc3250devkitv2_defconfig  |  23 +++
 include/configs/ea-lpc3250devkitv2.h  |  37 +
 10 files changed, 278 insertions(+)
 create mode 100644 arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
 create mode 100644 board/ea/ea-lpc3250devkitv2/Kconfig
 create mode 100644 board/ea/ea-lpc3250devkitv2/MAINTAINERS
 create mode 100644 board/ea/ea-lpc3250devkitv2/Makefile
 create mode 100644 board/ea/ea-lpc3250devkitv2/README.rst
 create mode 100644 board/ea/ea-lpc3250devkitv2/ea-lpc3250devkitv2.c
 create mode 100644 configs/ea-lpc3250devkitv2_defconfig
 create mode 100644 include/configs/ea-lpc3250devkitv2.h

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 096068261d..134108f14e 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -1103,6 +1103,8 @@ dtb-$(CONFIG_TARGET_PRESIDIO_ASIC) += 
ca-presidio-engboard.dtb
 
 dtb-$(CONFIG_TARGET_IMX8MM_CL_IOT_GATE) += imx8mm-cl-iot-gate.dtb
 
+dtb-$(CONFIG_TARGET_EA_LPC3250DEVKITV2) += lpc3250-ea3250.dtb
+
 targets += $(dtb-y)
 
 # Add any required device tree compiler flags here
diff --git a/arch/arm/dts/lpc3250-ea3250-u-boot.dtsi 
b/arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
new file mode 100644
index 00..0c82e512c6
--- /dev/null
+++ b/arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
@@ -0,0 +1,15 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2021 Trevor Woerner 
+ */
+
+/{
+   model = "Embedded Artists LPC3250 DevKit v2 board based on the NXP 
LPC3250 SoC";
+   chosen {
+   stdout-path = &uart5;
+   };
+};
+
+&uart5 {
+   compatible = "nxp,lpc3220-uart", "ns16550a";
+};
diff --git a/arch/arm/mach-lpc32xx/Kconfig b/arch/arm/mach-lpc32xx/Kconfig
index 986ad738ac..185bda41c2 100644
--- a/arch/arm/mach-lpc32xx/Kconfig
+++ b/arch/arm/mach-lpc32xx/Kconfig
@@ -12,9 +12,13 @@ config TARGET_DEVKIT3250
 config TARGET_WORK_92105
bool "Work Microwave Work_92105"
 
+config TARGET_EA_LPC3250DEVKITV2
+   bool "Embedded Artists LPC3250 Developer's Kit v2"
+
 endchoice
 
 source "board/timll/devkit3250/Kconfig"
 source "board/work-microwave/work_92105/Kconfig"
+source "board/ea/ea-lpc3250devkitv2/Kconfig"
 
 endif
diff --git a/board/ea/ea-lpc3250devkitv2/Kconfig 
b/board/ea/ea-lpc3250devkitv2/Kconfig
new file mode 100644
index 00..368ce027e6
--- /dev/null
+++ b/board/ea/ea-lpc3250devkitv2/Kconfig
@@ -0,0 +1,15 @@
+if TARGET_EA_LPC3250DEVKITV2
+
+config SYS_BOARD
+   default "ea-lpc3250devkitv2"
+
+config SYS_VENDOR
+   default "ea"
+
+config SYS_SOC
+   default "lpc32xx"
+
+config SYS_CONFIG_NAME
+   default "ea-lpc3250devkitv2"
+
+endif
diff --git a/board/ea/ea-lpc3250devkitv2/MAINTAINERS 
b/board/ea/ea-lpc3250devkitv2/MAINTAINERS
new file mode 100644
index 000000..b4b9362f5b
--- /dev/null
+++ b/board/ea/ea-lpc3250devkitv2/MAINTAINERS
@@ -0,0 +1,9 @@
+EMBEDDED ARTISTS LPC3250 DEVKIT v2
+M: Trevor Woerner 
+S: Maintained
+F: board/ea/ea-lpc3250devkitv2
+F: include/configs/ea-lpc3250devkitv2.h
+F: configs/ea-lpc3250devkitv2_defconfig
+F: arch/arm/dts/lpc32xx.dtsi
+F: arch/arm/dts/lpc3250-ea3250.dts
+F: arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
diff --git a/board/ea/ea-lpc3250devkitv2/Makefile 
b/board/ea/ea-lpc3250devkitv2/Makefile
new file mode 100644
index 00..a4a40b6d4f
--- /dev/null
+++ b/board/ea/ea-lpc3250devkitv2/Makefile
@@ -0,0 +1,4 @@
+# SPDX-License-Identifier: GPL-2.0+
+# Copyright (C) 2021  Trevor Woerner 
+
+obj-y += ea-lpc3250devkitv2.o
diff --git a/board/ea/ea-lpc3250devkitv2/README.rst 
b/board/ea/ea-lpc3250devkitv2/README.rst
new file mode 100644
index 00..56b5d0dbb1
--- /dev/null
+++ b/board/ea/ea-lpc3250devkitv2/README.rst
@@ -0,0 +1,132 @@
+.. SPDX-License-Identifier: GPL-2.0+
+
+ToC:
+- Introduction
+- Booting
+- Debugging
+
+
+Introduction
+
+The Embedded Artists LPC3250 Developer's Kit v2 features the LPC3250 SoC
+which is based on the ARM926EJ-S CPU. The kit features a base board and
+a removable OEM board which features the SoC. Details, schematics, and
+documentation are available from the Embedded Artists product website:
+
+   htt

[PATCH v2 2/8] lpc32xx: import device tree from Linux

2021-06-10 Thread Trevor Woerner
Import the dtsi, dts, and clock binding files for the lpc32xx ea3250 board
directly and unmodified from the latest Linux kernel.

Signed-off-by: Trevor Woerner 
---

(no changes since v1)

 arch/arm/dts/lpc3250-ea3250.dts   | 273 
 arch/arm/dts/lpc32xx.dtsi | 508 ++
 include/dt-bindings/clock/lpc32xx-clock.h |  58 +++
 3 files changed, 839 insertions(+)
 create mode 100644 arch/arm/dts/lpc3250-ea3250.dts
 create mode 100644 arch/arm/dts/lpc32xx.dtsi
 create mode 100644 include/dt-bindings/clock/lpc32xx-clock.h

diff --git a/arch/arm/dts/lpc3250-ea3250.dts b/arch/arm/dts/lpc3250-ea3250.dts
new file mode 100644
index 00..63c6f17bb7
--- /dev/null
+++ b/arch/arm/dts/lpc3250-ea3250.dts
@@ -0,0 +1,273 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * Embedded Artists LPC3250 board
+ *
+ * Copyright 2012 Roland Stigge 
+ */
+
+/dts-v1/;
+#include "lpc32xx.dtsi"
+
+/ {
+   model = "Embedded Artists LPC3250 board based on NXP LPC3250";
+   compatible = "ea,ea3250", "nxp,lpc3250";
+
+   memory@8000 {
+   device_type = "memory";
+   reg = <0x8000 0x400>;
+   };
+
+   gpio-keys {
+   compatible = "gpio-keys";
+   autorepeat;
+
+   button {
+   label = "Interrupt Key";
+   linux,code = <103>;
+   gpios = <&gpio 4 1 0>; /* GPI_P3 1 */
+   };
+
+   key1 {
+   label = "KEY1";
+   linux,code = <1>;
+   gpios = <&pca9532 0 0>;
+   };
+
+   key2 {
+   label = "KEY2";
+   linux,code = <2>;
+   gpios = <&pca9532 1 0>;
+   };
+
+   key3 {
+   label = "KEY3";
+   linux,code = <3>;
+   gpios = <&pca9532 2 0>;
+   };
+
+   key4 {
+   label = "KEY4";
+   linux,code = <4>;
+   gpios = <&pca9532 3 0>;
+   };
+
+   joy0 {
+   label = "Joystick Key 0";
+   linux,code = <10>;
+   gpios = <&gpio 2 0 0>; /* P2.0 */
+   };
+
+   joy1 {
+   label = "Joystick Key 1";
+   linux,code = <11>;
+   gpios = <&gpio 2 1 0>; /* P2.1 */
+   };
+
+   joy2 {
+   label = "Joystick Key 2";
+   linux,code = <12>;
+   gpios = <&gpio 2 2 0>; /* P2.2 */
+   };
+
+   joy3 {
+   label = "Joystick Key 3";
+   linux,code = <13>;
+   gpios = <&gpio 2 3 0>; /* P2.3 */
+   };
+
+   joy4 {
+   label = "Joystick Key 4";
+   linux,code = <14>;
+   gpios = <&gpio 2 4 0>; /* P2.4 */
+   };
+   };
+
+   leds {
+   compatible = "gpio-leds";
+
+   /* LEDs on OEM Board */
+
+   led1 {
+   gpios = <&gpio 5 14 1>; /* GPO_P3 14, GPIO 93, active 
low */
+   linux,default-trigger = "timer";
+   default-state = "off";
+   };
+
+   led2 {
+   gpios = <&gpio 2 10 1>; /* P2.10, active low */
+   default-state = "off";
+   };
+
+   led3 {
+   gpios = <&gpio 2 11 1>; /* P2.11, active low */
+   default-state = "off";
+   };
+
+   led4 {
+   gpios = <&gpio 2 12 1>; /* P2.12, active low */
+   default-state = "off";
+   };
+
+   /* LEDs on Base Board */
+
+   lede1 {
+   gpios = <&pca9532 8 0>;
+   default-state = "off";
+   };
+   lede2 {
+   gpios = <&pca9532 9 0>;
+   default-state = "off";
+   };
+   lede3 {
+   gpios = <&pca9532 10 0>;
+   default-state = "off";
+   };
+   lede4 {
+   

[PATCH v2 1/8] lpc32xx: Kconfig: switch to CONFIG_CONS_INDEX

2021-06-10 Thread Trevor Woerner
There's nothing special or unique to the lpc32xx that requires its own config
parameter for specifying the console uart index. Therefore instead of using
the lpc32xx-specific CONFIG_SYS_LPC32XX_UART include parameter, use the
already-available CONFIG_CONS_INDEX from Kconfig.

Signed-off-by: Trevor Woerner 
---

(no changes since v1)

 arch/arm/include/asm/arch-lpc32xx/config.h   | 4 ++--
 arch/arm/mach-lpc32xx/devices.c  | 3 +--
 board/timll/devkit3250/devkit3250.c  | 2 +-
 board/timll/devkit3250/devkit3250_spl.c  | 2 +-
 board/work-microwave/work_92105/work_92105.c | 2 +-
 board/work-microwave/work_92105/work_92105_spl.c | 2 +-
 configs/devkit3250_defconfig | 2 ++
 configs/work_92105_defconfig | 2 ++
 include/configs/devkit3250.h | 5 -
 include/configs/work_92105.h | 5 -
 scripts/config_whitelist.txt | 1 -
 11 files changed, 11 insertions(+), 19 deletions(-)

diff --git a/arch/arm/include/asm/arch-lpc32xx/config.h 
b/arch/arm/include/asm/arch-lpc32xx/config.h
index 0836091af2..45e46f9946 100644
--- a/arch/arm/include/asm/arch-lpc32xx/config.h
+++ b/arch/arm/include/asm/arch-lpc32xx/config.h
@@ -12,8 +12,8 @@
 /* Basic CPU architecture */
 
 /* UART configuration */
-#if(CONFIG_SYS_LPC32XX_UART == 1) || (CONFIG_SYS_LPC32XX_UART == 2) || \
-   (CONFIG_SYS_LPC32XX_UART == 7)
+#if(CONFIG_CONS_INDEX == 1) || (CONFIG_CONS_INDEX == 2) || \
+   (CONFIG_CONS_INDEX == 7)
 #if !defined(CONFIG_LPC32XX_HSUART)
 #define CONFIG_LPC32XX_HSUART
 #endif
diff --git a/arch/arm/mach-lpc32xx/devices.c b/arch/arm/mach-lpc32xx/devices.c
index e1e2e0d094..0a4fef295a 100644
--- a/arch/arm/mach-lpc32xx/devices.c
+++ b/arch/arm/mach-lpc32xx/devices.c
@@ -23,8 +23,7 @@ void lpc32xx_uart_init(unsigned int uart_id)
return;
 
/* Disable loopback mode, if it is set by S1L bootloader */
-   clrbits_le32(&ctrl->loop,
-UART_LOOPBACK(CONFIG_SYS_LPC32XX_UART));
+   clrbits_le32(&ctrl->loop, UART_LOOPBACK(uart_id));
 
if (uart_id < 3 || uart_id > 6)
return;
diff --git a/board/timll/devkit3250/devkit3250.c 
b/board/timll/devkit3250/devkit3250.c
index 3c744b943f..9d4ffb0f97 100644
--- a/board/timll/devkit3250/devkit3250.c
+++ b/board/timll/devkit3250/devkit3250.c
@@ -38,7 +38,7 @@ void reset_periph(void)
 
 int board_early_init_f(void)
 {
-   lpc32xx_uart_init(CONFIG_SYS_LPC32XX_UART);
+   lpc32xx_uart_init(CONFIG_CONS_INDEX);
lpc32xx_i2c_init(1);
lpc32xx_i2c_init(2);
lpc32xx_ssp_init();
diff --git a/board/timll/devkit3250/devkit3250_spl.c 
b/board/timll/devkit3250/devkit3250_spl.c
index 47af78ae0b..12e8ae9c39 100644
--- a/board/timll/devkit3250/devkit3250_spl.c
+++ b/board/timll/devkit3250/devkit3250_spl.c
@@ -49,7 +49,7 @@ void spl_board_init(void)
/* First of all silence buzzer controlled by GPO_20 */
writel((1 << 20), &gpio->p3_outp_clr);
 
-   lpc32xx_uart_init(CONFIG_SYS_LPC32XX_UART);
+   lpc32xx_uart_init(CONFIG_CONS_INDEX);
preloader_console_init();
 
ddr_init(&dram_64mb);
diff --git a/board/work-microwave/work_92105/work_92105.c 
b/board/work-microwave/work_92105/work_92105.c
index bdcecff730..5d12f84cfe 100644
--- a/board/work-microwave/work_92105/work_92105.c
+++ b/board/work-microwave/work_92105/work_92105.c
@@ -37,7 +37,7 @@ void reset_periph(void)
 int board_early_init_f(void)
 {
/* initialize serial port for console */
-   lpc32xx_uart_init(CONFIG_SYS_LPC32XX_UART);
+   lpc32xx_uart_init(CONFIG_CONS_INDEX);
/* enable I2C, SSP, MAC, NAND */
lpc32xx_i2c_init(1); /* only I2C1 has devices, I2C2 has none */
lpc32xx_ssp_init();
diff --git a/board/work-microwave/work_92105/work_92105_spl.c 
b/board/work-microwave/work_92105/work_92105_spl.c
index a31553a2d2..d9401145f2 100644
--- a/board/work-microwave/work_92105/work_92105_spl.c
+++ b/board/work-microwave/work_92105/work_92105_spl.c
@@ -58,7 +58,7 @@ const struct emc_dram_settings dram_128mb = {
 void spl_board_init(void)
 {
/* initialize serial port for console */
-   lpc32xx_uart_init(CONFIG_SYS_LPC32XX_UART);
+   lpc32xx_uart_init(CONFIG_CONS_INDEX);
/* initialize console */
preloader_console_init();
/* init DDR and NAND to chainload U-Boot */
diff --git a/configs/devkit3250_defconfig b/configs/devkit3250_defconfig
index 93c048cee8..9ae70f7d46 100644
--- a/configs/devkit3250_defconfig
+++ b/configs/devkit3250_defconfig
@@ -51,6 +51,8 @@ CONFIG_PHYLIB=y
 CONFIG_PHY_ADDR_ENABLE=y
 CONFIG_PHY_ADDR=31
 CONFIG_PHY_SMSC=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_CONS_INDEX=5
 CONFIG_SYS_NS16550=y
 CONFIG_SPI=y
 CONFIG_USB=y
diff --git a/configs/work_92105_defconfig b/configs/work_92105_defconfig
index c3f666dcfe..e9605adedd 100644
--- a/configs/work_92105_de

[PATCH v2 0/8] lpc32xx updates

2021-06-10 Thread Trevor Woerner
This patch series starts with some lpc32xx-related cleanups, then adds
support for a new LPC32XX board: the Embedded Artists LPC3250 DevKit v2.

The series then goes on to look at the lpc32xx i2c driver. It starts off by
perfomring some cleanups, adds some fixes so that it fully works in DM/OF
mode, does a Kconfig conversion, then adds i2c to the ea-lpc3250devkitv2
configuration (with examples).

Trevor Woerner (8):
  lpc32xx: Kconfig: switch to CONFIG_CONS_INDEX
  lpc32xx: import device tree from Linux
  arm: lpc32xx: add EA LPC3250 DevKitv2 board support
  lpc32xx: i2c: remove unused define
  lpc32xx: i2c: fix base address
  lpc32xx: i2c: finish DM/OF code
  Kconfig: convert CONFIG_SYS_I2C_LPC32XX
  lpc32xx: ea-lpc3250devkitv2: enable i2c (DM)

 arch/arm/dts/Makefile |   2 +
 arch/arm/dts/lpc3250-ea3250-u-boot.dtsi   |  15 +
 arch/arm/dts/lpc3250-ea3250.dts   | 273 ++
 arch/arm/dts/lpc32xx.dtsi | 508 ++
 arch/arm/include/asm/arch-lpc32xx/config.h|   4 +-
 arch/arm/mach-lpc32xx/Kconfig |   4 +
 arch/arm/mach-lpc32xx/devices.c   |   3 +-
 board/ea/ea-lpc3250devkitv2/Kconfig   |  15 +
 board/ea/ea-lpc3250devkitv2/MAINTAINERS   |   9 +
 board/ea/ea-lpc3250devkitv2/Makefile  |   4 +
 board/ea/ea-lpc3250devkitv2/README.rst| 186 +++
 .../ea-lpc3250devkitv2/ea-lpc3250devkitv2.c   |  41 ++
 board/timll/devkit3250/devkit3250.c   |   2 +-
 board/timll/devkit3250/devkit3250_spl.c   |   2 +-
 board/work-microwave/work_92105/work_92105.c  |   2 +-
 .../work_92105/work_92105_spl.c   |   2 +-
 configs/devkit3250_defconfig  |   3 +
 configs/ea-lpc3250devkitv2_defconfig  |  26 +
 configs/work_92105_defconfig  |   3 +
 drivers/i2c/Kconfig   |   6 +
 drivers/i2c/lpc32xx_i2c.c |  15 +-
 include/configs/devkit3250.h  |   6 -
 include/configs/ea-lpc3250devkitv2.h  |  37 ++
 include/configs/work_92105.h  |   6 -
 include/dt-bindings/clock/lpc32xx-clock.h |  58 ++
 scripts/config_whitelist.txt  |   2 -
 26 files changed, 1205 insertions(+), 29 deletions(-)
 create mode 100644 arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
 create mode 100644 arch/arm/dts/lpc3250-ea3250.dts
 create mode 100644 arch/arm/dts/lpc32xx.dtsi
 create mode 100644 board/ea/ea-lpc3250devkitv2/Kconfig
 create mode 100644 board/ea/ea-lpc3250devkitv2/MAINTAINERS
 create mode 100644 board/ea/ea-lpc3250devkitv2/Makefile
 create mode 100644 board/ea/ea-lpc3250devkitv2/README.rst
 create mode 100644 board/ea/ea-lpc3250devkitv2/ea-lpc3250devkitv2.c
 create mode 100644 configs/ea-lpc3250devkitv2_defconfig
 create mode 100644 include/configs/ea-lpc3250devkitv2.h
 create mode 100644 include/dt-bindings/clock/lpc32xx-clock.h

-- 
2.30.0.rc0



[PATCH v1 3/3] arm: lpc32xx: add EA LPC3250 DevKitv2 board support

2021-06-06 Thread Trevor Woerner
Add basic support for running U-Boot on the Embedded Artists LPC3250
Developer's Kit v2 board by launching U-Boot from the board's s1l loader
(which comes pre-installed on the board).

Signed-off-by: Trevor Woerner 
---

 arch/arm/dts/Makefile |   2 +
 arch/arm/dts/lpc3250-ea3250-u-boot.dtsi   |  15 ++
 arch/arm/mach-lpc32xx/Kconfig |   4 +
 board/ea/ea-lpc3250devkitv2/Kconfig   |  15 ++
 board/ea/ea-lpc3250devkitv2/MAINTAINERS   |   9 ++
 board/ea/ea-lpc3250devkitv2/Makefile  |   4 +
 board/ea/ea-lpc3250devkitv2/README.rst| 132 ++
 .../ea-lpc3250devkitv2/ea-lpc3250devkitv2.c   |  37 +
 configs/ea-lpc3250devkitv2_defconfig  |  23 +++
 include/configs/ea-lpc3250devkitv2.h  |  37 +
 10 files changed, 278 insertions(+)
 create mode 100644 arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
 create mode 100644 board/ea/ea-lpc3250devkitv2/Kconfig
 create mode 100644 board/ea/ea-lpc3250devkitv2/MAINTAINERS
 create mode 100644 board/ea/ea-lpc3250devkitv2/Makefile
 create mode 100644 board/ea/ea-lpc3250devkitv2/README.rst
 create mode 100644 board/ea/ea-lpc3250devkitv2/ea-lpc3250devkitv2.c
 create mode 100644 configs/ea-lpc3250devkitv2_defconfig
 create mode 100644 include/configs/ea-lpc3250devkitv2.h

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 096068261d..134108f14e 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -1103,6 +1103,8 @@ dtb-$(CONFIG_TARGET_PRESIDIO_ASIC) += 
ca-presidio-engboard.dtb
 
 dtb-$(CONFIG_TARGET_IMX8MM_CL_IOT_GATE) += imx8mm-cl-iot-gate.dtb
 
+dtb-$(CONFIG_TARGET_EA_LPC3250DEVKITV2) += lpc3250-ea3250.dtb
+
 targets += $(dtb-y)
 
 # Add any required device tree compiler flags here
diff --git a/arch/arm/dts/lpc3250-ea3250-u-boot.dtsi 
b/arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
new file mode 100644
index 00..0c82e512c6
--- /dev/null
+++ b/arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
@@ -0,0 +1,15 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2021 Trevor Woerner 
+ */
+
+/{
+   model = "Embedded Artists LPC3250 DevKit v2 board based on the NXP 
LPC3250 SoC";
+   chosen {
+   stdout-path = &uart5;
+   };
+};
+
+&uart5 {
+   compatible = "nxp,lpc3220-uart", "ns16550a";
+};
diff --git a/arch/arm/mach-lpc32xx/Kconfig b/arch/arm/mach-lpc32xx/Kconfig
index 986ad738ac..185bda41c2 100644
--- a/arch/arm/mach-lpc32xx/Kconfig
+++ b/arch/arm/mach-lpc32xx/Kconfig
@@ -12,9 +12,13 @@ config TARGET_DEVKIT3250
 config TARGET_WORK_92105
bool "Work Microwave Work_92105"
 
+config TARGET_EA_LPC3250DEVKITV2
+   bool "Embedded Artists LPC3250 Developer's Kit v2"
+
 endchoice
 
 source "board/timll/devkit3250/Kconfig"
 source "board/work-microwave/work_92105/Kconfig"
+source "board/ea/ea-lpc3250devkitv2/Kconfig"
 
 endif
diff --git a/board/ea/ea-lpc3250devkitv2/Kconfig 
b/board/ea/ea-lpc3250devkitv2/Kconfig
new file mode 100644
index 00..368ce027e6
--- /dev/null
+++ b/board/ea/ea-lpc3250devkitv2/Kconfig
@@ -0,0 +1,15 @@
+if TARGET_EA_LPC3250DEVKITV2
+
+config SYS_BOARD
+   default "ea-lpc3250devkitv2"
+
+config SYS_VENDOR
+   default "ea"
+
+config SYS_SOC
+   default "lpc32xx"
+
+config SYS_CONFIG_NAME
+   default "ea-lpc3250devkitv2"
+
+endif
diff --git a/board/ea/ea-lpc3250devkitv2/MAINTAINERS 
b/board/ea/ea-lpc3250devkitv2/MAINTAINERS
new file mode 100644
index 000000..b4b9362f5b
--- /dev/null
+++ b/board/ea/ea-lpc3250devkitv2/MAINTAINERS
@@ -0,0 +1,9 @@
+EMBEDDED ARTISTS LPC3250 DEVKIT v2
+M: Trevor Woerner 
+S: Maintained
+F: board/ea/ea-lpc3250devkitv2
+F: include/configs/ea-lpc3250devkitv2.h
+F: configs/ea-lpc3250devkitv2_defconfig
+F: arch/arm/dts/lpc32xx.dtsi
+F: arch/arm/dts/lpc3250-ea3250.dts
+F: arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
diff --git a/board/ea/ea-lpc3250devkitv2/Makefile 
b/board/ea/ea-lpc3250devkitv2/Makefile
new file mode 100644
index 00..a4a40b6d4f
--- /dev/null
+++ b/board/ea/ea-lpc3250devkitv2/Makefile
@@ -0,0 +1,4 @@
+# SPDX-License-Identifier: GPL-2.0+
+# Copyright (C) 2021  Trevor Woerner 
+
+obj-y += ea-lpc3250devkitv2.o
diff --git a/board/ea/ea-lpc3250devkitv2/README.rst 
b/board/ea/ea-lpc3250devkitv2/README.rst
new file mode 100644
index 00..56b5d0dbb1
--- /dev/null
+++ b/board/ea/ea-lpc3250devkitv2/README.rst
@@ -0,0 +1,132 @@
+.. SPDX-License-Identifier: GPL-2.0+
+
+ToC:
+- Introduction
+- Booting
+- Debugging
+
+
+Introduction
+
+The Embedded Artists LPC3250 Developer's Kit v2 features the LPC3250 SoC
+which is based on the ARM926EJ-S CPU. The kit features a base board and
+a removable OEM board which features the SoC. Details, schematics, and
+documentation are available from the Embedded Artists product website:
+
+   https://www.embedded

[PATCH v1 2/3] lpc32xx: import device tree from Linux

2021-06-06 Thread Trevor Woerner
Import the dtsi, dts, and clock binding files for the lpc32xx ea3250 board
directly and unmodified from the latest Linux kernel.

Signed-off-by: Trevor Woerner 
---

 arch/arm/dts/lpc3250-ea3250.dts   | 273 
 arch/arm/dts/lpc32xx.dtsi | 508 ++
 include/dt-bindings/clock/lpc32xx-clock.h |  58 +++
 3 files changed, 839 insertions(+)
 create mode 100644 arch/arm/dts/lpc3250-ea3250.dts
 create mode 100644 arch/arm/dts/lpc32xx.dtsi
 create mode 100644 include/dt-bindings/clock/lpc32xx-clock.h

diff --git a/arch/arm/dts/lpc3250-ea3250.dts b/arch/arm/dts/lpc3250-ea3250.dts
new file mode 100644
index 00..63c6f17bb7
--- /dev/null
+++ b/arch/arm/dts/lpc3250-ea3250.dts
@@ -0,0 +1,273 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * Embedded Artists LPC3250 board
+ *
+ * Copyright 2012 Roland Stigge 
+ */
+
+/dts-v1/;
+#include "lpc32xx.dtsi"
+
+/ {
+   model = "Embedded Artists LPC3250 board based on NXP LPC3250";
+   compatible = "ea,ea3250", "nxp,lpc3250";
+
+   memory@8000 {
+   device_type = "memory";
+   reg = <0x8000 0x400>;
+   };
+
+   gpio-keys {
+   compatible = "gpio-keys";
+   autorepeat;
+
+   button {
+   label = "Interrupt Key";
+   linux,code = <103>;
+   gpios = <&gpio 4 1 0>; /* GPI_P3 1 */
+   };
+
+   key1 {
+   label = "KEY1";
+   linux,code = <1>;
+   gpios = <&pca9532 0 0>;
+   };
+
+   key2 {
+   label = "KEY2";
+   linux,code = <2>;
+   gpios = <&pca9532 1 0>;
+   };
+
+   key3 {
+   label = "KEY3";
+   linux,code = <3>;
+   gpios = <&pca9532 2 0>;
+   };
+
+   key4 {
+   label = "KEY4";
+   linux,code = <4>;
+   gpios = <&pca9532 3 0>;
+   };
+
+   joy0 {
+   label = "Joystick Key 0";
+   linux,code = <10>;
+   gpios = <&gpio 2 0 0>; /* P2.0 */
+   };
+
+   joy1 {
+   label = "Joystick Key 1";
+   linux,code = <11>;
+   gpios = <&gpio 2 1 0>; /* P2.1 */
+   };
+
+   joy2 {
+   label = "Joystick Key 2";
+   linux,code = <12>;
+   gpios = <&gpio 2 2 0>; /* P2.2 */
+   };
+
+   joy3 {
+   label = "Joystick Key 3";
+   linux,code = <13>;
+   gpios = <&gpio 2 3 0>; /* P2.3 */
+   };
+
+   joy4 {
+   label = "Joystick Key 4";
+   linux,code = <14>;
+   gpios = <&gpio 2 4 0>; /* P2.4 */
+   };
+   };
+
+   leds {
+   compatible = "gpio-leds";
+
+   /* LEDs on OEM Board */
+
+   led1 {
+   gpios = <&gpio 5 14 1>; /* GPO_P3 14, GPIO 93, active 
low */
+   linux,default-trigger = "timer";
+   default-state = "off";
+   };
+
+   led2 {
+   gpios = <&gpio 2 10 1>; /* P2.10, active low */
+   default-state = "off";
+   };
+
+   led3 {
+   gpios = <&gpio 2 11 1>; /* P2.11, active low */
+   default-state = "off";
+   };
+
+   led4 {
+   gpios = <&gpio 2 12 1>; /* P2.12, active low */
+   default-state = "off";
+   };
+
+   /* LEDs on Base Board */
+
+   lede1 {
+   gpios = <&pca9532 8 0>;
+   default-state = "off";
+   };
+   lede2 {
+   gpios = <&pca9532 9 0>;
+   default-state = "off";
+   };
+   lede3 {
+   gpios = <&pca9532 10 0>;
+   default-state = "off";
+   };
+   lede4 {
+   

[PATCH v1 1/3] lpc32xx: Kconfig: switch to CONFIG_CONS_INDEX

2021-06-06 Thread Trevor Woerner
There's nothing special or unique to the lpc32xx that requires its own config
parameter for specifying the console uart index. Therefore instead of using
the lpc32xx-specific CONFIG_SYS_LPC32XX_UART include parameter, use the
already-available CONFIG_CONS_INDEX from Kconfig.

Signed-off-by: Trevor Woerner 
---

 arch/arm/include/asm/arch-lpc32xx/config.h   | 4 ++--
 arch/arm/mach-lpc32xx/devices.c  | 3 +--
 board/timll/devkit3250/devkit3250.c  | 2 +-
 board/timll/devkit3250/devkit3250_spl.c  | 2 +-
 board/work-microwave/work_92105/work_92105.c | 2 +-
 board/work-microwave/work_92105/work_92105_spl.c | 2 +-
 configs/devkit3250_defconfig | 2 ++
 configs/work_92105_defconfig | 2 ++
 include/configs/devkit3250.h | 5 -
 include/configs/work_92105.h | 5 -
 scripts/config_whitelist.txt | 1 -
 11 files changed, 11 insertions(+), 19 deletions(-)

diff --git a/arch/arm/include/asm/arch-lpc32xx/config.h 
b/arch/arm/include/asm/arch-lpc32xx/config.h
index 0836091af2..45e46f9946 100644
--- a/arch/arm/include/asm/arch-lpc32xx/config.h
+++ b/arch/arm/include/asm/arch-lpc32xx/config.h
@@ -12,8 +12,8 @@
 /* Basic CPU architecture */
 
 /* UART configuration */
-#if(CONFIG_SYS_LPC32XX_UART == 1) || (CONFIG_SYS_LPC32XX_UART == 2) || \
-   (CONFIG_SYS_LPC32XX_UART == 7)
+#if(CONFIG_CONS_INDEX == 1) || (CONFIG_CONS_INDEX == 2) || \
+   (CONFIG_CONS_INDEX == 7)
 #if !defined(CONFIG_LPC32XX_HSUART)
 #define CONFIG_LPC32XX_HSUART
 #endif
diff --git a/arch/arm/mach-lpc32xx/devices.c b/arch/arm/mach-lpc32xx/devices.c
index e1e2e0d094..0a4fef295a 100644
--- a/arch/arm/mach-lpc32xx/devices.c
+++ b/arch/arm/mach-lpc32xx/devices.c
@@ -23,8 +23,7 @@ void lpc32xx_uart_init(unsigned int uart_id)
return;
 
/* Disable loopback mode, if it is set by S1L bootloader */
-   clrbits_le32(&ctrl->loop,
-UART_LOOPBACK(CONFIG_SYS_LPC32XX_UART));
+   clrbits_le32(&ctrl->loop, UART_LOOPBACK(uart_id));
 
if (uart_id < 3 || uart_id > 6)
return;
diff --git a/board/timll/devkit3250/devkit3250.c 
b/board/timll/devkit3250/devkit3250.c
index 3c744b943f..9d4ffb0f97 100644
--- a/board/timll/devkit3250/devkit3250.c
+++ b/board/timll/devkit3250/devkit3250.c
@@ -38,7 +38,7 @@ void reset_periph(void)
 
 int board_early_init_f(void)
 {
-   lpc32xx_uart_init(CONFIG_SYS_LPC32XX_UART);
+   lpc32xx_uart_init(CONFIG_CONS_INDEX);
lpc32xx_i2c_init(1);
lpc32xx_i2c_init(2);
lpc32xx_ssp_init();
diff --git a/board/timll/devkit3250/devkit3250_spl.c 
b/board/timll/devkit3250/devkit3250_spl.c
index 47af78ae0b..12e8ae9c39 100644
--- a/board/timll/devkit3250/devkit3250_spl.c
+++ b/board/timll/devkit3250/devkit3250_spl.c
@@ -49,7 +49,7 @@ void spl_board_init(void)
/* First of all silence buzzer controlled by GPO_20 */
writel((1 << 20), &gpio->p3_outp_clr);
 
-   lpc32xx_uart_init(CONFIG_SYS_LPC32XX_UART);
+   lpc32xx_uart_init(CONFIG_CONS_INDEX);
preloader_console_init();
 
ddr_init(&dram_64mb);
diff --git a/board/work-microwave/work_92105/work_92105.c 
b/board/work-microwave/work_92105/work_92105.c
index bdcecff730..5d12f84cfe 100644
--- a/board/work-microwave/work_92105/work_92105.c
+++ b/board/work-microwave/work_92105/work_92105.c
@@ -37,7 +37,7 @@ void reset_periph(void)
 int board_early_init_f(void)
 {
/* initialize serial port for console */
-   lpc32xx_uart_init(CONFIG_SYS_LPC32XX_UART);
+   lpc32xx_uart_init(CONFIG_CONS_INDEX);
/* enable I2C, SSP, MAC, NAND */
lpc32xx_i2c_init(1); /* only I2C1 has devices, I2C2 has none */
lpc32xx_ssp_init();
diff --git a/board/work-microwave/work_92105/work_92105_spl.c 
b/board/work-microwave/work_92105/work_92105_spl.c
index a31553a2d2..d9401145f2 100644
--- a/board/work-microwave/work_92105/work_92105_spl.c
+++ b/board/work-microwave/work_92105/work_92105_spl.c
@@ -58,7 +58,7 @@ const struct emc_dram_settings dram_128mb = {
 void spl_board_init(void)
 {
/* initialize serial port for console */
-   lpc32xx_uart_init(CONFIG_SYS_LPC32XX_UART);
+   lpc32xx_uart_init(CONFIG_CONS_INDEX);
/* initialize console */
preloader_console_init();
/* init DDR and NAND to chainload U-Boot */
diff --git a/configs/devkit3250_defconfig b/configs/devkit3250_defconfig
index 93c048cee8..9ae70f7d46 100644
--- a/configs/devkit3250_defconfig
+++ b/configs/devkit3250_defconfig
@@ -51,6 +51,8 @@ CONFIG_PHYLIB=y
 CONFIG_PHY_ADDR_ENABLE=y
 CONFIG_PHY_ADDR=31
 CONFIG_PHY_SMSC=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_CONS_INDEX=5
 CONFIG_SYS_NS16550=y
 CONFIG_SPI=y
 CONFIG_USB=y
diff --git a/configs/work_92105_defconfig b/configs/work_92105_defconfig
index c3f666dcfe..e9605adedd 100644
--- a/configs/work_92105_defconfig
+++ b/c

[PATCH v1 0/3] lpc32xx updates

2021-06-06 Thread Trevor Woerner
This patch series starts with some lpc32xx-related cleanups, then adds
support for a new LPC32XX board: the Embedded Artists LPC3250 DevKit v2


Trevor Woerner (3):
  lpc32xx: Kconfig: switch to CONFIG_CONS_INDEX
  lpc32xx: import device tree from Linux
  arm: lpc32xx: add EA LPC3250 DevKitv2 board support

 arch/arm/dts/Makefile |   2 +
 arch/arm/dts/lpc3250-ea3250-u-boot.dtsi   |  15 +
 arch/arm/dts/lpc3250-ea3250.dts   | 273 ++
 arch/arm/dts/lpc32xx.dtsi | 508 ++
 arch/arm/include/asm/arch-lpc32xx/config.h|   4 +-
 arch/arm/mach-lpc32xx/Kconfig |   4 +
 arch/arm/mach-lpc32xx/devices.c   |   3 +-
 board/ea/ea-lpc3250devkitv2/Kconfig   |  15 +
 board/ea/ea-lpc3250devkitv2/MAINTAINERS   |   9 +
 board/ea/ea-lpc3250devkitv2/Makefile  |   4 +
 board/ea/ea-lpc3250devkitv2/README.rst| 132 +
 .../ea-lpc3250devkitv2/ea-lpc3250devkitv2.c   |  37 ++
 board/timll/devkit3250/devkit3250.c   |   2 +-
 board/timll/devkit3250/devkit3250_spl.c   |   2 +-
 board/work-microwave/work_92105/work_92105.c  |   2 +-
 .../work_92105/work_92105_spl.c   |   2 +-
 configs/devkit3250_defconfig  |   2 +
 configs/ea-lpc3250devkitv2_defconfig  |  23 +
 configs/work_92105_defconfig  |   2 +
 include/configs/devkit3250.h  |   5 -
 include/configs/ea-lpc3250devkitv2.h  |  37 ++
 include/configs/work_92105.h  |   5 -
 include/dt-bindings/clock/lpc32xx-clock.h |  58 ++
 scripts/config_whitelist.txt  |   1 -
 24 files changed, 1128 insertions(+), 19 deletions(-)
 create mode 100644 arch/arm/dts/lpc3250-ea3250-u-boot.dtsi
 create mode 100644 arch/arm/dts/lpc3250-ea3250.dts
 create mode 100644 arch/arm/dts/lpc32xx.dtsi
 create mode 100644 board/ea/ea-lpc3250devkitv2/Kconfig
 create mode 100644 board/ea/ea-lpc3250devkitv2/MAINTAINERS
 create mode 100644 board/ea/ea-lpc3250devkitv2/Makefile
 create mode 100644 board/ea/ea-lpc3250devkitv2/README.rst
 create mode 100644 board/ea/ea-lpc3250devkitv2/ea-lpc3250devkitv2.c
 create mode 100644 configs/ea-lpc3250devkitv2_defconfig
 create mode 100644 include/configs/ea-lpc3250devkitv2.h
 create mode 100644 include/dt-bindings/clock/lpc32xx-clock.h

-- 
2.30.0.rc0



Re: [ANN] U-Boot v2021.07-rc2 released

2021-05-11 Thread Trevor Woerner
On Mon, May 10, 2021 at 5:06 PM Tom Rini  wrote:

> and shortly after this I will pull in the patches
> needed to enforce the DM migrations that are now 2 years past their
> warning dates.
>

Could you please be more specific with respect to which DM subsystem(s)
migrations are targeted next?


Re: [PATCH 1/2] moveconfig.py: add try…except

2021-04-07 Thread Trevor Woerner
It looks like Simon beat me to this one with 
7570d9bb47be24d9d73518742703f32126af8113
but I'm hoping 2/2 can still make it in.

On Mon 2021-03-15 @ 12:01:32 PM, Trevor Woerner wrote:
> I keep getting a UnicodeDecodeError from one of the header files while
> modifying the headers:
> 
>Traceback (most recent call last):
> File "tools/moveconfig.py", line 1953, in 
>   main()
> File "tools/moveconfig.py", line 1927, in main
>   cleanup_headers(configs, options)
> File "tools/moveconfig.py", line 675, in cleanup_headers
>   cleanup_one_header(header_path, patterns, options)
> File "tools/moveconfig.py", line 599, in cleanup_one_header
>   lines = f.readlines()
> File "/usr/lib64/python3.6/codecs.py", line 321, in decode
>   (result, consumed) = self._buffer_decode(data, self.errors, final)
>   UnicodeDecodeError: 'utf-8' codec can't decode byte 0x83 in position 9: 
> invalid start byte
> 
> I'm curious to know which header file is causing the problem.
> 
> Signed-off-by: Trevor Woerner 
> ---
>  tools/moveconfig.py | 7 ++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/tools/moveconfig.py b/tools/moveconfig.py
> index 9514d9a00c..dd92c00bb7 100755
> --- a/tools/moveconfig.py
> +++ b/tools/moveconfig.py
> @@ -596,7 +596,12 @@ def cleanup_one_header(header_path, patterns, options):
>options: option flags.
>  """
>  with open(header_path) as f:
> -lines = f.readlines()
> +try:
> +lines = f.readlines()
> +except:
> +print("caught exception: ", sys.exc_info()[0])
> +print("header_path: ", header_path)
> +lines = ""
>  
>  matched = []
>  for i, line in enumerate(lines):
> -- 
> 2.30.0.rc0
> 


Re: [ANN] U-Boot v2021.04 released

2021-04-05 Thread Trevor Woerner
On Mon, Apr 5, 2021 at 12:37 PM Tom Rini  wrote:
> On Mon, Apr 05, 2021 at 12:34:42PM -0400, Trevor Woerner wrote:
> > On Mon 2021-04-05 @ 11:03:58 AM, Tom Rini wrote:
> > > It is release day and here is the v2021.04 release.  With this release
> > > we are now at the first of our 2 years past a DM migration deadline.
> > > This will be the last release for a number of boards that will be
> > > removed shortly, so that we can be done with the migration and perform
> > > some cleanups, etc, around that area of code.  There are more migration
> > > deadlines for v2021.07.
> >
> > The patches I sent to save the imx233 olimex devices from being scrapped
> > aren't in master. Is this expected?
> >
> > https://patchwork.ozlabs.org/project/uboot/patch/20210322153129.23026-1-twoer...@gmail.com/
> > https://patchwork.ozlabs.org/project/uboot/patch/20210322153129.23026-2-twoer...@gmail.com/
>
> Yes.  One of my first steps for the next release is going to be to grab
> a bunch of migration patches, and then drop platforms.

Excellent, thank you.


Re: [ANN] U-Boot v2021.04 released

2021-04-05 Thread Trevor Woerner
On Mon 2021-04-05 @ 11:03:58 AM, Tom Rini wrote:
> It is release day and here is the v2021.04 release.  With this release
> we are now at the first of our 2 years past a DM migration deadline.
> This will be the last release for a number of boards that will be
> removed shortly, so that we can be done with the migration and perform
> some cleanups, etc, around that area of code.  There are more migration
> deadlines for v2021.07.

The patches I sent to save the imx233 olimex devices from being scrapped
aren't in master. Is this expected?

https://patchwork.ozlabs.org/project/uboot/patch/20210322153129.23026-1-twoer...@gmail.com/
https://patchwork.ozlabs.org/project/uboot/patch/20210322153129.23026-2-twoer...@gmail.com/


[PATCH v2 1/2] mx23_olinuxino: enable device tree

2021-03-22 Thread Trevor Woerner
Add the dts file for the Olimex Olinuxino from the linux kernel, and enable
its use in this machine's defconfig.

Signed-off-by: Trevor Woerner 
---

Changes in v2:
- none
---
 arch/arm/dts/Makefile|   3 +
 arch/arm/dts/imx23-olinuxino.dts | 131 +++
 configs/mx23_olinuxino_defconfig |   3 +-
 3 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/dts/imx23-olinuxino.dts

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index c6710826a0..d5cffc90d4 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -651,6 +651,9 @@ dtb-$(CONFIG_VF610) += vf500-colibri.dtb \
 dtb-$(CONFIG_MX23) += \
imx23-evk.dtb
 
+dtb-$(CONFIG_TARGET_MX23_OLINUXINO) += \
+   imx23-olinuxino.dtb
+
 dtb-$(CONFIG_MX28) += \
imx28-xea.dtb
 
diff --git a/arch/arm/dts/imx23-olinuxino.dts b/arch/arm/dts/imx23-olinuxino.dts
new file mode 100644
index 00..0729e72f22
--- /dev/null
+++ b/arch/arm/dts/imx23-olinuxino.dts
@@ -0,0 +1,131 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * Copyright 2012 Freescale Semiconductor, Inc.
+ *
+ * Author: Fabio Estevam 
+ */
+
+/dts-v1/;
+#include 
+#include "imx23.dtsi"
+
+/ {
+   model = "i.MX23 Olinuxino Low Cost Board";
+   compatible = "olimex,imx23-olinuxino", "fsl,imx23";
+
+   memory@4000 {
+   device_type = "memory";
+   reg = <0x4000 0x0400>;
+   };
+
+   apb@8000 {
+   apbh@8000 {
+   ssp0: spi@8001 {
+   compatible = "fsl,imx23-mmc";
+   pinctrl-names = "default";
+   pinctrl-0 = <&mmc0_4bit_pins_a &mmc0_sck_cfg>;
+   bus-width = <4>;
+   broken-cd;
+   status = "okay";
+   };
+
+   pinctrl@80018000 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&hog_pins_a>;
+
+   hog_pins_a: hog@0 {
+   reg = <0>;
+   fsl,pinmux-ids = <
+   MX23_PAD_GPMI_ALE__GPIO_0_17
+   >;
+   fsl,drive-strength = ;
+   fsl,voltage = ;
+   fsl,pull-up = ;
+   };
+
+   led_pin_gpio2_1: led_gpio2_1@0 {
+   reg = <0>;
+   fsl,pinmux-ids = <
+   MX23_PAD_SSP1_DETECT__GPIO_2_1
+   >;
+   fsl,drive-strength = ;
+   fsl,voltage = ;
+   fsl,pull-up = ;
+   };
+   };
+
+   ssp1: spi@80034000 {
+   #address-cells = <1>;
+   #size-cells = <0>;
+   compatible = "fsl,imx23-spi";
+   pinctrl-names = "default";
+   pinctrl-0 = <&spi2_pins_a>;
+   status = "okay";
+   };
+   };
+
+   apbx@8004 {
+   lradc@8005 {
+   status = "okay";
+   };
+
+   i2c: i2c@80058000 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&i2c_pins_b>;
+   status = "okay";
+   };
+
+   duart: serial@8007 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&duart_pins_a>;
+   status = "okay";
+   };
+
+   auart0: serial@8006c000 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&auart0_2pins_a>;
+   status = "okay";
+   };
+
+   usbphy0: usbphy@8007c000 {
+   status = "okay";
+   };
+   };
+   };
+
+   ahb@8008 {
+   usb0: usb@8008 {
+   dr_mod

[PATCH v2 2/2] mx23_olinuxino: convert MMC to driver model

2021-03-22 Thread Trevor Woerner
Convert the Olimex Olinuxino board's support for MMC to driver model following
Fabio Estevam's excellent example from:

commit: 23013aa9619881290dbeb6217f1fab863869050e:
mx23evk: Convert to driver model

Signed-off-by: Trevor Woerner 
---

Changes in v2:
- Create an imx23-olinuxino-u-boot.dtsi with the u-boot-specific changes
  instead of modifying the imx23-olinuxino.dts file (which comes directly from
  the Linux kernel). This helps preserve the ability to directly import the
  Linux kernel device tree files into U-Boot without modification.
---
 arch/arm/dts/imx23-olinuxino-u-boot.dtsi |  5 +
 board/olimex/mx23_olinuxino/mx23_olinuxino.c | 12 
 configs/mx23_olinuxino_defconfig |  4 +++-
 3 files changed, 8 insertions(+), 13 deletions(-)
 create mode 100644 arch/arm/dts/imx23-olinuxino-u-boot.dtsi

diff --git a/arch/arm/dts/imx23-olinuxino-u-boot.dtsi 
b/arch/arm/dts/imx23-olinuxino-u-boot.dtsi
new file mode 100644
index 00..dee8433696
--- /dev/null
+++ b/arch/arm/dts/imx23-olinuxino-u-boot.dtsi
@@ -0,0 +1,5 @@
+// SPDX-License-Identifier: GPL-2.0+
+
+&ssp0 {
+   non-removable;
+};
diff --git a/board/olimex/mx23_olinuxino/mx23_olinuxino.c 
b/board/olimex/mx23_olinuxino/mx23_olinuxino.c
index d1e189cbb6..bdd5fcd76a 100644
--- a/board/olimex/mx23_olinuxino/mx23_olinuxino.c
+++ b/board/olimex/mx23_olinuxino/mx23_olinuxino.c
@@ -57,18 +57,6 @@ int dram_init(void)
return mxs_dram_init();
 }
 
-#ifdef CONFIG_CMD_MMC
-static int mx23_olx_mmc_cd(int id)
-{
-   return 1;   /* Card always present */
-}
-
-int board_mmc_init(struct bd_info *bis)
-{
-   return mxsmmc_initialize(bis, 0, NULL, mx23_olx_mmc_cd);
-}
-#endif
-
 int board_init(void)
 {
/* Adress of boot parameters */
diff --git a/configs/mx23_olinuxino_defconfig b/configs/mx23_olinuxino_defconfig
index 2bf6818ee3..680611cd01 100644
--- a/configs/mx23_olinuxino_defconfig
+++ b/configs/mx23_olinuxino_defconfig
@@ -12,6 +12,7 @@ CONFIG_TARGET_MX23_OLINUXINO=y
 CONFIG_SPL_SERIAL_SUPPORT=y
 CONFIG_SPL=y
 CONFIG_DEFAULT_DEVICE_TREE="imx23-olinuxino"
+# CONFIG_SYS_MALLOC_F is not set
 CONFIG_BOOTDELAY=3
 # CONFIG_DISPLAY_BOARDINFO is not set
 CONFIG_ARCH_MISC_INIT=y
@@ -30,6 +31,7 @@ CONFIG_ENV_OVERWRITE=y
 CONFIG_ENV_IS_IN_MMC=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
 CONFIG_VERSION_VARIABLE=y
+CONFIG_DM=y
 CONFIG_MXS_GPIO=y
 CONFIG_LED_STATUS=y
 CONFIG_LED_STATUS_GPIO=y
@@ -39,10 +41,10 @@ CONFIG_LED_STATUS_STATE=2
 CONFIG_LED_STATUS_BOOT_ENABLE=y
 CONFIG_LED_STATUS_BOOT=0
 CONFIG_LED_STATUS_CMD=y
+CONFIG_DM_MMC=y
 CONFIG_MMC_MXS=y
 CONFIG_CONS_INDEX=0
 CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
-CONFIG_USB_STORAGE=y
 CONFIG_USB_HOST_ETHER=y
 CONFIG_USB_ETHER_SMSC95XX=y
-- 
2.30.0.rc0



Re: [ANN] U-Boot v2021.04-rc4 released

2021-03-21 Thread Trevor Woerner
On Sun 2021-03-21 @ 09:28:21 PM, Tom Rini wrote:
> On Sun, Mar 21, 2021 at 09:09:46PM -0400, Trevor Woerner wrote:
> > On Wed 2021-03-17 @ 10:37:18 AM, Fabio Estevam wrote:
> > > On Wed, Mar 17, 2021 at 10:22 AM Trevor Woerner  
> > > wrote:
> > > > However, I am interested in preserving the olimex board (i.e.
> > > > configs/mx23_olinuxino_defconfig). So I could take a look at that one 
> > > > first
> > > > unless, Marek, you would like to take a look?
> > > 
> > > I have recently converted imx23-evk to DM, so hopefully, the imx23
> > > olinuxino transition will be smooth too:
> > > https://source.denx.de/u-boot/u-boot/-/commit/23013aa9619881290dbeb6217f1fab863869050e
> > > 
> > > I don't have the imx23 olinuxino board handy, but let us know if you
> > > face any issues in the DM conversion.
> > 
> > Fabio: your imx23-evk patch provided an excellent example for me to follow, 
> > thanks!
> > 
> > Tom: I have the MMC conversion to DM completed and tested for the Olimex
> > Olinuxino board. But this board is still missing DM conversions for USB and
> > ETH. Should I go ahead and send in just the MMC conversion to save it from 
> > the
> > immediate chopping block, or would you rather wait until I've at least had a
> > chance to look at the USB and ETH conversions in order to send all of them
> > together in one patch set?
> 
> Immediate needs please, thanks.  Due note that USB will have it back on
> the chopping block quickly, so to speak :)

Okay, sent:

https://patchwork.ozlabs.org/project/uboot/patch/20210322013454.13782-1-twoer...@gmail.com/
https://patchwork.ozlabs.org/project/uboot/patch/20210322013454.13782-2-twoer...@gmail.com/


[PATCH 2/2] mx23_olinuxino: convert MMC to driver model

2021-03-21 Thread Trevor Woerner
Convert the Olimex Olinuxino board's support for MMC to driver model
following Fabio Estevam's excellent example from:

commit: 23013aa9619881290dbeb6217f1fab863869050e:
mx23evk: Convert to driver model

Signed-off-by: Trevor Woerner 
---
 arch/arm/dts/imx23-olinuxino.dts |  1 +
 board/olimex/mx23_olinuxino/mx23_olinuxino.c | 12 
 configs/mx23_olinuxino_defconfig |  4 +++-
 3 files changed, 4 insertions(+), 13 deletions(-)

diff --git a/arch/arm/dts/imx23-olinuxino.dts b/arch/arm/dts/imx23-olinuxino.dts
index 0729e72f22..ce368d44a0 100644
--- a/arch/arm/dts/imx23-olinuxino.dts
+++ b/arch/arm/dts/imx23-olinuxino.dts
@@ -26,6 +26,7 @@
pinctrl-0 = <&mmc0_4bit_pins_a &mmc0_sck_cfg>;
bus-width = <4>;
broken-cd;
+   non-removable;
status = "okay";
};
 
diff --git a/board/olimex/mx23_olinuxino/mx23_olinuxino.c 
b/board/olimex/mx23_olinuxino/mx23_olinuxino.c
index d1e189cbb6..bdd5fcd76a 100644
--- a/board/olimex/mx23_olinuxino/mx23_olinuxino.c
+++ b/board/olimex/mx23_olinuxino/mx23_olinuxino.c
@@ -57,18 +57,6 @@ int dram_init(void)
return mxs_dram_init();
 }
 
-#ifdef CONFIG_CMD_MMC
-static int mx23_olx_mmc_cd(int id)
-{
-   return 1;   /* Card always present */
-}
-
-int board_mmc_init(struct bd_info *bis)
-{
-   return mxsmmc_initialize(bis, 0, NULL, mx23_olx_mmc_cd);
-}
-#endif
-
 int board_init(void)
 {
/* Adress of boot parameters */
diff --git a/configs/mx23_olinuxino_defconfig b/configs/mx23_olinuxino_defconfig
index 2bf6818ee3..680611cd01 100644
--- a/configs/mx23_olinuxino_defconfig
+++ b/configs/mx23_olinuxino_defconfig
@@ -12,6 +12,7 @@ CONFIG_TARGET_MX23_OLINUXINO=y
 CONFIG_SPL_SERIAL_SUPPORT=y
 CONFIG_SPL=y
 CONFIG_DEFAULT_DEVICE_TREE="imx23-olinuxino"
+# CONFIG_SYS_MALLOC_F is not set
 CONFIG_BOOTDELAY=3
 # CONFIG_DISPLAY_BOARDINFO is not set
 CONFIG_ARCH_MISC_INIT=y
@@ -30,6 +31,7 @@ CONFIG_ENV_OVERWRITE=y
 CONFIG_ENV_IS_IN_MMC=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
 CONFIG_VERSION_VARIABLE=y
+CONFIG_DM=y
 CONFIG_MXS_GPIO=y
 CONFIG_LED_STATUS=y
 CONFIG_LED_STATUS_GPIO=y
@@ -39,10 +41,10 @@ CONFIG_LED_STATUS_STATE=2
 CONFIG_LED_STATUS_BOOT_ENABLE=y
 CONFIG_LED_STATUS_BOOT=0
 CONFIG_LED_STATUS_CMD=y
+CONFIG_DM_MMC=y
 CONFIG_MMC_MXS=y
 CONFIG_CONS_INDEX=0
 CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
-CONFIG_USB_STORAGE=y
 CONFIG_USB_HOST_ETHER=y
 CONFIG_USB_ETHER_SMSC95XX=y
-- 
2.30.0.rc0



[PATCH 1/2] mx23_olinuxino: enable device tree

2021-03-21 Thread Trevor Woerner
Add the dts file for the Olimex Olinuxino from the linux kernel, and enable
its use in this machine's defconfig.

Signed-off-by: Trevor Woerner 
---
 arch/arm/dts/Makefile|   3 +
 arch/arm/dts/imx23-olinuxino.dts | 131 +++
 configs/mx23_olinuxino_defconfig |   3 +-
 3 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/dts/imx23-olinuxino.dts

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index c6710826a0..d5cffc90d4 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -651,6 +651,9 @@ dtb-$(CONFIG_VF610) += vf500-colibri.dtb \
 dtb-$(CONFIG_MX23) += \
imx23-evk.dtb
 
+dtb-$(CONFIG_TARGET_MX23_OLINUXINO) += \
+   imx23-olinuxino.dtb
+
 dtb-$(CONFIG_MX28) += \
imx28-xea.dtb
 
diff --git a/arch/arm/dts/imx23-olinuxino.dts b/arch/arm/dts/imx23-olinuxino.dts
new file mode 100644
index 00..0729e72f22
--- /dev/null
+++ b/arch/arm/dts/imx23-olinuxino.dts
@@ -0,0 +1,131 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * Copyright 2012 Freescale Semiconductor, Inc.
+ *
+ * Author: Fabio Estevam 
+ */
+
+/dts-v1/;
+#include 
+#include "imx23.dtsi"
+
+/ {
+   model = "i.MX23 Olinuxino Low Cost Board";
+   compatible = "olimex,imx23-olinuxino", "fsl,imx23";
+
+   memory@4000 {
+   device_type = "memory";
+   reg = <0x4000 0x0400>;
+   };
+
+   apb@8000 {
+   apbh@8000 {
+   ssp0: spi@8001 {
+   compatible = "fsl,imx23-mmc";
+   pinctrl-names = "default";
+   pinctrl-0 = <&mmc0_4bit_pins_a &mmc0_sck_cfg>;
+   bus-width = <4>;
+   broken-cd;
+   status = "okay";
+   };
+
+   pinctrl@80018000 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&hog_pins_a>;
+
+   hog_pins_a: hog@0 {
+   reg = <0>;
+   fsl,pinmux-ids = <
+   MX23_PAD_GPMI_ALE__GPIO_0_17
+   >;
+   fsl,drive-strength = ;
+   fsl,voltage = ;
+   fsl,pull-up = ;
+   };
+
+   led_pin_gpio2_1: led_gpio2_1@0 {
+   reg = <0>;
+   fsl,pinmux-ids = <
+   MX23_PAD_SSP1_DETECT__GPIO_2_1
+   >;
+   fsl,drive-strength = ;
+   fsl,voltage = ;
+   fsl,pull-up = ;
+   };
+   };
+
+   ssp1: spi@80034000 {
+   #address-cells = <1>;
+   #size-cells = <0>;
+   compatible = "fsl,imx23-spi";
+   pinctrl-names = "default";
+   pinctrl-0 = <&spi2_pins_a>;
+   status = "okay";
+   };
+   };
+
+   apbx@8004 {
+   lradc@8005 {
+   status = "okay";
+   };
+
+   i2c: i2c@80058000 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&i2c_pins_b>;
+   status = "okay";
+   };
+
+   duart: serial@8007 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&duart_pins_a>;
+   status = "okay";
+   };
+
+   auart0: serial@8006c000 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&auart0_2pins_a>;
+   status = "okay";
+   };
+
+   usbphy0: usbphy@8007c000 {
+   status = "okay";
+   };
+   };
+   };
+
+   ahb@8008 {
+   usb0: usb@8008 {
+   dr_mode 

Re: [ANN] U-Boot v2021.04-rc4 released

2021-03-21 Thread Trevor Woerner
On Wed 2021-03-17 @ 10:37:18 AM, Fabio Estevam wrote:
> On Wed, Mar 17, 2021 at 10:22 AM Trevor Woerner  wrote:
> > However, I am interested in preserving the olimex board (i.e.
> > configs/mx23_olinuxino_defconfig). So I could take a look at that one first
> > unless, Marek, you would like to take a look?
> 
> I have recently converted imx23-evk to DM, so hopefully, the imx23
> olinuxino transition will be smooth too:
> https://source.denx.de/u-boot/u-boot/-/commit/23013aa9619881290dbeb6217f1fab863869050e
> 
> I don't have the imx23 olinuxino board handy, but let us know if you
> face any issues in the DM conversion.

Fabio: your imx23-evk patch provided an excellent example for me to follow, 
thanks!

Tom: I have the MMC conversion to DM completed and tested for the Olimex
Olinuxino board. But this board is still missing DM conversions for USB and
ETH. Should I go ahead and send in just the MMC conversion to save it from the
immediate chopping block, or would you rather wait until I've at least had a
chance to look at the USB and ETH conversions in order to send all of them
together in one patch set?

Best regards,
Trevor


Re: [ANN] U-Boot v2021.04-rc4 released

2021-03-17 Thread Trevor Woerner
On Wed, Mar 17, 2021 at 9:37 AM Fabio Estevam  wrote:
>
> Hi Trevor,
>
> On Wed, Mar 17, 2021 at 10:22 AM Trevor Woerner  wrote:
>
> > However, I am interested in preserving the olimex board (i.e.
> > configs/mx23_olinuxino_defconfig). So I could take a look at that one first
> > unless, Marek, you would like to take a look?
>
> I have recently converted imx23-evk to DM, so hopefully, the imx23
> olinuxino transition will be smooth too:
> https://source.denx.de/u-boot/u-boot/-/commit/23013aa9619881290dbeb6217f1fab863869050e
>
> I don't have the imx23 olinuxino board handy, but let us know if you
> face any issues in the DM conversion.

Okay, I have the -maxi so I'll get on that conversion.

Thanks!


Re: [ANN] U-Boot v2021.04-rc4 released

2021-03-17 Thread Trevor Woerner
On Wed 2021-03-17 @ 08:55:59 AM, Tom Rini wrote:
> On Wed, Mar 17, 2021 at 01:13:57PM +0100, Marek Vasut wrote:
> > On 3/15/21 5:07 PM, Tom Rini wrote:
> > > Hey all,
> > > 
> > > It's release day, and here's v2021.04-rc4.  Not a whole lot of change
> > > since last time in master, and -next has been and is still open.  I just
> > > want to repeat a few things from -rc3:
> > > 
> > > - We've moved from "gitlab.denx.de" (and also "git.denx.de") to
> > >"source.denx.de", please make sure to update your scripts and tools
> > >and so forth.  If you send me pull requests, now is a good time to
> > >switch to url/pushurl if you haven't already.
> > > - Once v2021.04 is released I will be pushing a large number of board
> > >removals for things that will be then 2 years past their "migrate this
> > >by ... or it might be removed" date which is also around 3 years total
> > >of notice.
> > 
> > Which ones ?
> 
> All of the ones I've sent out removal patches for over the last month,
> CC'ing the maintainers.  That's basically:
> https://patchwork.ozlabs.org/project/uboot/list/?series=228850
> https://patchwork.ozlabs.org/project/uboot/list/?series=230325
> along with I believe I need to v2 dropping some defconfigs for I believe
> mx28evk once Stefano picks up Fabio's patch to update and maintain the
> main defconfig (he already ack'd such a removal).

Ah okay, just DM_MMC for now, so the lpc32xx boards aren't on the block… yet.

However, I am interested in preserving the olimex board (i.e.
configs/mx23_olinuxino_defconfig). So I could take a look at that one first
unless, Marek, you would like to take a look?


Re: [ANN] U-Boot v2021.04-rc4 released

2021-03-17 Thread Trevor Woerner
On Mon 2021-03-15 @ 12:07:44 PM, Tom Rini wrote:
> - Once v2021.04 is released I will be pushing a large number of board
>   removals for things that will be then 2 years past their "migrate this
>   by ... or it might be removed" date which is also around 3 years total
>   of notice.

FWIW I'm working on updating the lpc32xx platforms (devkit3250 and work_92105)
to DM. Hopefully I'll get that in sooner rather than later :-)


[PATCH] finish removing mb862xx video driver

2021-03-15 Thread Trevor Woerner
drivers/video/mb862xx.c was removed in commit
9c1e098fb92de38f0017585658dd50c3009c84ab from December 2020, however, this
last little remnant in drivers/video/cfb_console.c remained.

Signed-off-by: Trevor Woerner 
---
 drivers/video/cfb_console.c  | 14 --
 scripts/config_whitelist.txt |  1 -
 2 files changed, 15 deletions(-)

diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c
index 27ff7163f3..1f491a48d6 100644
--- a/drivers/video/cfb_console.c
+++ b/drivers/video/cfb_console.c
@@ -81,20 +81,6 @@
 #define VIDEO_FB_16BPP_WORD_SWAP
 #endif
 
-/*
- * Defines for the MB862xx driver
- */
-#ifdef CONFIG_VIDEO_MB862xx
-
-#ifdef CONFIG_VIDEO_CORALP
-#define VIDEO_FB_LITTLE_ENDIAN
-#endif
-#ifdef CONFIG_VIDEO_MB862xx_ACCEL
-#define VIDEO_HW_RECTFILL
-#define VIDEO_HW_BITBLT
-#endif
-#endif
-
 /*
  * Defines for the i.MX31 driver (mx3fb.c)
  */
diff --git a/scripts/config_whitelist.txt b/scripts/config_whitelist.txt
index 43295eec7d..be47961c31 100644
--- a/scripts/config_whitelist.txt
+++ b/scripts/config_whitelist.txt
@@ -3943,7 +3943,6 @@ CONFIG_VEXPRESS_EXTENDED_MEMORY_MAP
 CONFIG_VEXPRESS_ORIGINAL_MEMORY_MAP
 CONFIG_VIDEO_BCM2835
 CONFIG_VIDEO_BMP_LOGO
-CONFIG_VIDEO_CORALP
 CONFIG_VIDEO_DA8XX
 CONFIG_VIDEO_FONT_4X6
 CONFIG_VIDEO_LCD_I2C_BUS
-- 
2.30.0.rc0



[PATCH 2/2] moveconfig.py: add to the "do not process" list

2021-03-15 Thread Trevor Woerner
Skip the processing of *.aml and *.dat files while iterating through the
source in order to process header files.

Signed-off-by: Trevor Woerner 
---
 tools/moveconfig.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/moveconfig.py b/tools/moveconfig.py
index dd92c00bb7..1e08b3cada 100755
--- a/tools/moveconfig.py
+++ b/tools/moveconfig.py
@@ -672,7 +672,7 @@ def cleanup_headers(configs, options):
 continue
 for filename in filenames:
 if not filename.endswith(('~', '.dts', '.dtsi', '.bin',
-  '.elf')):
+  '.elf','.aml','.dat')):
 header_path = os.path.join(dirpath, filename)
 # This file contains UTF-16 data and no CONFIG symbols
 if header_path == 'include/video_font_data.h':
-- 
2.30.0.rc0



[PATCH 1/2] moveconfig.py: add try…except

2021-03-15 Thread Trevor Woerner
I keep getting a UnicodeDecodeError from one of the header files while
modifying the headers:

 Traceback (most recent call last):
  File "tools/moveconfig.py", line 1953, in 
main()
  File "tools/moveconfig.py", line 1927, in main
cleanup_headers(configs, options)
  File "tools/moveconfig.py", line 675, in cleanup_headers
cleanup_one_header(header_path, patterns, options)
  File "tools/moveconfig.py", line 599, in cleanup_one_header
lines = f.readlines()
  File "/usr/lib64/python3.6/codecs.py", line 321, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x83 in position 9: 
invalid start byte

I'm curious to know which header file is causing the problem.

Signed-off-by: Trevor Woerner 
---
 tools/moveconfig.py | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/tools/moveconfig.py b/tools/moveconfig.py
index 9514d9a00c..dd92c00bb7 100755
--- a/tools/moveconfig.py
+++ b/tools/moveconfig.py
@@ -596,7 +596,12 @@ def cleanup_one_header(header_path, patterns, options):
   options: option flags.
 """
 with open(header_path) as f:
-lines = f.readlines()
+try:
+lines = f.readlines()
+except:
+print("caught exception: ", sys.exc_info()[0])
+print("header_path: ", header_path)
+lines = ""
 
 matched = []
 for i, line in enumerate(lines):
-- 
2.30.0.rc0



[PATCH v4 3/8] rename symbol: CONFIG_ORION5X -> CONFIG_ARCH_ORION5X

2020-05-06 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.
This patch removes a TODO from the code.

Signed-off-by: Trevor Woerner 

---

Changes in v4: None
Changes in v3: None
Changes in v2:
- Update patch to work on latest master; the location where the SPL linker
  script is specified has changed.

 arch/arm/Kconfig| 2 +-
 arch/arm/Makefile   | 3 +--
 arch/arm/mach-orion5x/Kconfig   | 2 +-
 configs/edminiv2_defconfig  | 2 +-
 drivers/ata/mvsata_ide.c| 2 +-
 drivers/i2c/mvtwsi.c| 2 +-
 drivers/net/Kconfig | 2 +-
 drivers/net/mvgbe.c | 2 +-
 drivers/usb/host/Kconfig| 2 +-
 drivers/usb/host/ehci-marvell.c | 2 +-
 10 files changed, 10 insertions(+), 11 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 70b7b89b47..5546329a47 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -576,7 +576,7 @@ config TARGET_APF27
select CPU_ARM926EJS
select SUPPORT_SPL
 
-config ORION5X
+config ARCH_ORION5X
bool "Marvell Orion"
select CPU_ARM926EJS
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 5d32dec29c..2b44ffb493 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -67,8 +67,7 @@ machine-$(CONFIG_ARCH_MEDIATEK)   += mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
 machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
-# TODO: rename CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
-machine-$(CONFIG_ORION5X)  += orion5x
+machine-$(CONFIG_ARCH_ORION5X) += orion5x
 machine-$(CONFIG_ARCH_OWL) += owl
 machine-$(CONFIG_ARCH_RMOBILE) += rmobile
 machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
diff --git a/arch/arm/mach-orion5x/Kconfig b/arch/arm/mach-orion5x/Kconfig
index 7644b8dc85..5baa6fb935 100644
--- a/arch/arm/mach-orion5x/Kconfig
+++ b/arch/arm/mach-orion5x/Kconfig
@@ -1,4 +1,4 @@
-if ORION5X
+if ARCH_ORION5X
 
 choice
prompt "Marvell Orion board select"
diff --git a/configs/edminiv2_defconfig b/configs/edminiv2_defconfig
index b9a68a9263..d06f83db04 100644
--- a/configs/edminiv2_defconfig
+++ b/configs/edminiv2_defconfig
@@ -1,6 +1,6 @@
 CONFIG_ARM=y
 CONFIG_ARCH_CPU_INIT=y
-CONFIG_ORION5X=y
+CONFIG_ARCH_ORION5X=y
 CONFIG_SPL_LDSCRIPT="arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds"
 CONFIG_SYS_TEXT_BASE=0x0080
 CONFIG_SPL_LIBCOMMON_SUPPORT=y
diff --git a/drivers/ata/mvsata_ide.c b/drivers/ata/mvsata_ide.c
index 38181235af..9ac16555d6 100644
--- a/drivers/ata/mvsata_ide.c
+++ b/drivers/ata/mvsata_ide.c
@@ -8,7 +8,7 @@
 #include 
 #include 
 
-#if defined(CONFIG_ORION5X)
+#if defined(CONFIG_ARCH_ORION5X)
 #include 
 #elif defined(CONFIG_KIRKWOOD)
 #include 
diff --git a/drivers/i2c/mvtwsi.c b/drivers/i2c/mvtwsi.c
index 382cf4b304..77fe35a42b 100644
--- a/drivers/i2c/mvtwsi.c
+++ b/drivers/i2c/mvtwsi.c
@@ -25,7 +25,7 @@ DECLARE_GLOBAL_DATA_PTR;
  */
 
 #ifndef CONFIG_DM_I2C
-#if defined(CONFIG_ORION5X)
+#if defined(CONFIG_ARCH_ORION5X)
 #include 
 #elif (defined(CONFIG_KIRKWOOD) || defined(CONFIG_ARCH_MVEBU))
 #include 
diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig
index a2587a29e1..8afaa7c06a 100644
--- a/drivers/net/Kconfig
+++ b/drivers/net/Kconfig
@@ -303,7 +303,7 @@ config FSLDMAFEC
 
 config MVGBE
bool "Marvell Orion5x/Kirkwood network interface support"
-   depends on KIRKWOOD || ORION5X
+   depends on KIRKWOOD || ARCH_ORION5X
select PHYLIB if DM_ETH
help
  This driver supports the network interface units in the
diff --git a/drivers/net/mvgbe.c b/drivers/net/mvgbe.c
index 037e59ec6e..b0b8d349a8 100644
--- a/drivers/net/mvgbe.c
+++ b/drivers/net/mvgbe.c
@@ -26,7 +26,7 @@
 
 #if defined(CONFIG_KIRKWOOD)
 #include 
-#elif defined(CONFIG_ORION5X)
+#elif defined(CONFIG_ARCH_ORION5X)
 #include 
 #endif
 
diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
index 2f381dc958..cc9646d40a 100644
--- a/drivers/usb/host/Kconfig
+++ b/drivers/usb/host/Kconfig
@@ -135,7 +135,7 @@ config USB_EHCI_ATMEL
 
 config USB_EHCI_MARVELL
bool "Support for Marvell on-chip EHCI USB controller"
-   depends on ARCH_MVEBU || KIRKWOOD || ORION5X
+   depends on ARCH_MVEBU || KIRKWOOD || ARCH_ORION5X
default y
---help---
  Enables support for the on-chip EHCI controller on MVEBU SoCs.
diff --git a/drivers/usb/host/ehci-marvell.c b/drivers/usb/host/ehci-marvell.c
index 8efe6b63b9..3b10cdfc58 100644
--- a/drivers/usb/host/ehci-marvell.c
+++ b/drivers/usb/host/ehci-marvell.c
@@ -15,7 +15,7 @@
 
 #if defined(CONFIG_KIRKWOOD)
 #include 
-#elif defined(CONFIG_ORION5X)
+#elif defined(CONFIG_ARCH_ORION5X)
 #include 
 #endif
 
-- 
2.26.0.106.g9fadedd637



[PATCH v4 5/8] rename symbol: CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD

2020-05-06 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.
This patch also removes a TODO from the code.

Reviewed-by: Chris Packham 
Signed-off-by: Trevor Woerner 

---

Changes in v4: None
Changes in v3: None
Changes in v2:
- Add Chris Packham's r-b

 Kconfig  |  2 +-
 arch/arm/Kconfig |  2 +-
 arch/arm/Makefile|  3 +--
 arch/arm/dts/Makefile|  2 +-
 arch/arm/mach-kirkwood/Kconfig   |  2 +-
 arch/arm/mach-mvebu/Makefile |  6 +++---
 arch/arm/mach-mvebu/mbus.c   |  6 +++---
 board/keymile/Kconfig| 12 ++--
 configs/SBx81LIFKW_defconfig |  2 +-
 configs/SBx81LIFXCAT_defconfig   |  2 +-
 configs/d2net_v2_defconfig   |  2 +-
 configs/db-88f6281-bp-nand_defconfig |  2 +-
 configs/db-88f6281-bp-spi_defconfig  |  2 +-
 configs/dns325_defconfig |  2 +-
 configs/dockstar_defconfig   |  2 +-
 configs/dreamplug_defconfig  |  2 +-
 configs/ds109_defconfig  |  2 +-
 configs/goflexhome_defconfig |  2 +-
 configs/guruplug_defconfig   |  2 +-
 configs/ib62x0_defconfig |  2 +-
 configs/iconnect_defconfig   |  2 +-
 configs/inetspace_v2_defconfig   |  2 +-
 configs/km_kirkwood_128m16_defconfig |  2 +-
 configs/km_kirkwood_defconfig|  2 +-
 configs/km_kirkwood_pci_defconfig|  2 +-
 configs/kmcoge5un_defconfig  |  2 +-
 configs/kmnusa_defconfig |  2 +-
 configs/kmsuse2_defconfig|  2 +-
 configs/lschlv2_defconfig|  2 +-
 configs/lsxhl_defconfig  |  2 +-
 configs/nas220_defconfig |  2 +-
 configs/net2big_v2_defconfig |  2 +-
 configs/netspace_lite_v2_defconfig   |  2 +-
 configs/netspace_max_v2_defconfig|  2 +-
 configs/netspace_mini_v2_defconfig   |  2 +-
 configs/netspace_v2_defconfig|  2 +-
 configs/nsa310s_defconfig|  2 +-
 configs/openrd_base_defconfig|  2 +-
 configs/openrd_client_defconfig  |  2 +-
 configs/openrd_ultimate_defconfig|  2 +-
 configs/pogo_e02_defconfig   |  2 +-
 configs/sheevaplug_defconfig |  2 +-
 drivers/ata/mvsata_ide.c |  2 +-
 drivers/ata/sata_mv.c|  2 +-
 drivers/i2c/mvtwsi.c |  4 ++--
 drivers/net/Kconfig  |  2 +-
 drivers/net/mvgbe.c  |  2 +-
 drivers/spi/kirkwood_spi.c   | 10 +-
 drivers/usb/host/Kconfig |  2 +-
 drivers/usb/host/ehci-marvell.c  |  2 +-
 tools/Makefile   |  4 ++--
 51 files changed, 66 insertions(+), 67 deletions(-)

diff --git a/Kconfig b/Kconfig
index 15f1a75c61..0e7ccc0b07 100644
--- a/Kconfig
+++ b/Kconfig
@@ -268,7 +268,7 @@ config BUILD_TARGET
default "u-boot-elf.srec" if RCAR_GEN3
default "u-boot.itb" if SPL_LOAD_FIT && (ARCH_ROCKCHIP || \
ARCH_SUNXI || RISCV || ARCH_ZYNQMP)
-   default "u-boot.kwb" if KIRKWOOD
+   default "u-boot.kwb" if ARCH_KIRKWOOD
default "u-boot-with-spl.bin" if ARCH_AT91 && SPL_NAND_SUPPORT
default "u-boot-with-spl.imx" if ARCH_MX6 && SPL
help
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 5546329a47..91185b9299 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -553,7 +553,7 @@ config ARCH_DAVINCI
help
  Support for TI's DaVinci platform.
 
-config KIRKWOOD
+config ARCH_KIRKWOOD
bool "Marvell Kirkwood"
select ARCH_MISC_INIT
select BOARD_EARLY_INIT_F
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 2b44ffb493..9b3ca9772c 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -60,8 +60,7 @@ machine-$(CONFIG_ARCH_EXYNOS) += exynos
 machine-$(CONFIG_ARCH_HIGHBANK)+= highbank
 machine-$(CONFIG_ARCH_K3)  += k3
 machine-$(CONFIG_ARCH_KEYSTONE)+= keystone
-# TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
-machine-$(CONFIG_KIRKWOOD) += kirkwood
+machine-$(CONFIG_ARCH_KIRKWOOD)+= kirkwood
 machine-$(CONFIG_ARCH_LPC32XX) += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 559d3ab6a7..9ce634e8b8 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -34,7 +34,7 @@ dtb-$(CONFIG_ARCH_DAVINCI) += \
da850-lcdk.dtb \
da850-lego-ev3.dtb
 
-dtb-$(CONFIG_KIRKWOOD) += \
+dtb-$(CONFIG_ARCH_KIRKWOOD) += \
kirkwood-atl-sbx81lifkw.dtb \
kirkwood-atl-sbx81lifxcat.dtb \
kirkwood-blackarmor-nas220.dtb \
diff --git a/arch/arm/mach-kirkwood/Kconfig b/arch/arm/mach-kirkwood/Kconfig
index 2f68092f82..ae44cb665e 100644
--- a/arch/arm/mach-kirkwood/Kconfig
+

[PATCH v4 8/8] drivers/reset/Kconfig: fix typo

2020-05-06 Thread Trevor Woerner
Signed-off-by: Trevor Woerner 

---

Changes in v4: None
Changes in v3: None
Changes in v2: None

 drivers/reset/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/reset/Kconfig b/drivers/reset/Kconfig
index 65101ab4e8..88d3be1593 100644
--- a/drivers/reset/Kconfig
+++ b/drivers/reset/Kconfig
@@ -33,7 +33,7 @@ config STM32_RESET
depends on ARCH_STM32 || ARCH_STM32MP
help
  Support for reset controllers on STMicroelectronics STM32 family SoCs.
- This resset driver is compatible with STM32 F4/F7 and H7 SoCs.
+ This reset driver is compatible with STM32 F4/F7 and H7 SoCs.
 
 config TEGRA_CAR_RESET
bool "Enable Tegra CAR-based reset driver"
-- 
2.26.0.106.g9fadedd637



[PATCH v4 6/8] rename symbol: CONFIG_TEGRA -> CONFIG_ARCH_TEGRA

2020-05-06 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.

Signed-off-by: Trevor Woerner 

---

Changes in v4:
- Tweaked patch so it applies to master; some of the diff context lines have
  changed.

Changes in v3: None
Changes in v2: None

 Makefile  | 4 ++--
 arch/arm/Kconfig  | 2 +-
 arch/arm/Makefile | 7 +++
 arch/arm/cpu/arm720t/interrupts.c | 2 +-
 arch/arm/cpu/armv7/Kconfig| 2 +-
 arch/arm/dts/Makefile | 2 +-
 arch/arm/mach-tegra/Kconfig   | 2 +-
 common/spl/Kconfig| 4 ++--
 config.mk | 2 +-
 configs/apalis-tk1_defconfig  | 2 +-
 configs/apalis_t30_defconfig  | 2 +-
 configs/beaver_defconfig  | 2 +-
 configs/cardhu_defconfig  | 2 +-
 configs/cei-tk1-som_defconfig | 2 +-
 configs/colibri_t20_defconfig | 2 +-
 configs/colibri_t30_defconfig | 2 +-
 configs/dalmore_defconfig | 2 +-
 configs/e2220-1170_defconfig  | 2 +-
 configs/harmony_defconfig | 2 +-
 configs/jetson-tk1_defconfig  | 2 +-
 configs/medcom-wide_defconfig | 2 +-
 configs/nyan-big_defconfig| 2 +-
 configs/p2371-_defconfig  | 2 +-
 configs/p2371-2180_defconfig  | 2 +-
 configs/p2571_defconfig   | 2 +-
 configs/p2771--000_defconfig  | 2 +-
 configs/p2771--500_defconfig  | 2 +-
 configs/p3450-_defconfig  | 2 +-
 configs/paz00_defconfig   | 2 +-
 configs/plutux_defconfig  | 2 +-
 configs/seaboard_defconfig| 2 +-
 configs/tec-ng_defconfig  | 2 +-
 configs/tec_defconfig | 2 +-
 configs/trimslice_defconfig   | 2 +-
 configs/venice2_defconfig | 2 +-
 configs/ventana_defconfig | 2 +-
 disk/Kconfig  | 4 ++--
 drivers/i2c/Kconfig   | 2 +-
 drivers/mailbox/Kconfig   | 2 +-
 drivers/mmc/Kconfig   | 2 +-
 drivers/pci/Kconfig   | 2 +-
 drivers/usb/host/Kconfig  | 2 +-
 drivers/video/Kconfig | 2 +-
 include/serial.h  | 2 +-
 44 files changed, 49 insertions(+), 50 deletions(-)

diff --git a/Makefile b/Makefile
index cc99873062..a38fb4a5ff 100644
--- a/Makefile
+++ b/Makefile
@@ -936,7 +936,7 @@ ALL-y += u-boot-sunxi-with-spl.bin
 endif
 
 # enable combined SPL/u-boot/dtb rules for tegra
-ifeq ($(CONFIG_TEGRA)$(CONFIG_SPL),yy)
+ifeq ($(CONFIG_ARCH_TEGRA)$(CONFIG_SPL),yy)
 ALL-y += u-boot-tegra.bin u-boot-nodtb-tegra.bin
 ALL-$(CONFIG_OF_SEPARATE) += u-boot-dtb-tegra.bin
 endif
@@ -1632,7 +1632,7 @@ endif
 u-boot-x86-with-spl.bin: spl/u-boot-spl.bin u-boot.bin FORCE
$(call if_changed,binman)
 
-ifneq ($(CONFIG_TEGRA),)
+ifneq ($(CONFIG_ARCH_TEGRA),)
 ifneq ($(CONFIG_BINMAN),)
 # Makes u-boot-dtb-tegra.bin u-boot-tegra.bin u-boot-nodtb-tegra.bin
 %-dtb-tegra.bin %-tegra.bin %-nodtb-tegra.bin: \
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 91185b9299..574d1e246f 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1142,7 +1142,7 @@ config ARCH_ZYNQMP
imply MP
imply DM_USB_GADGET
 
-config TEGRA
+config ARCH_TEGRA
bool "NVIDIA Tegra"
imply DISTRO_DEFAULTS
imply FAT_WRITE
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 9b3ca9772c..e91b37fb34 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -1,6 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0+
 
-ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_TEGRA),yy)
+ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_ARCH_TEGRA),yy)
 CONFIG_CPU_V7A=
 CONFIG_CPU_ARM720T=y
 endif
@@ -22,7 +22,7 @@ arch-$(CONFIG_ARM64)  =-march=armv8-a
 
 # On Tegra systems we must build SPL for the armv4 core on the device
 # but otherwise we can use the value in CONFIG_SYS_ARM_ARCH
-ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_TEGRA),yy)
+ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_ARCH_TEGRA),yy)
 arch-y += -D__LINUX_ARM_ARCH__=4
 else
 arch-y += -D__LINUX_ARM_ARCH__=$(CONFIG_SYS_ARM_ARCH)
@@ -76,8 +76,7 @@ machine-$(CONFIG_ARCH_SOCFPGA)+= socfpga
 machine-$(CONFIG_STM32)+= stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
 machine-$(CONFIG_ARCH_SUNXI)   += sunxi
-# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
-machine-$(CONFIG_TEGRA)+= tegra
+machine-$(CONFIG_ARCH_TEGRA)   += tegra
 machine-$(CONFIG_ARCH_U8500)   += u8500
 machine-$(CONFIG_ARCH_UNIPHIER)+= uniphier
 machine-$(CONFIG_ARCH_VERSAL)  += versal
diff --git a/arch/arm/cpu/arm720t/interrupts.c 
b/arch/arm/cpu/arm720t/interrupts.c
index 8437717a7b..f0fc58dead 100644
--- a/arch/arm/cpu/arm720t/interrupts.c
+++ b/arch/arm/cpu/arm720t/interrupts.c
@@ -11,7 +11,7 @@
 
 #include 
 
-#if defined(CONFIG_TEGRA)
+#if defined(CONFIG_ARCH_TEGRA)
 static ulong timestamp;
 static ulong lastdec;
 
diff --git a/arch/arm/cpu/armv7/Kconfig b/arch/arm/cpu/armv7/Kconfig
index 73d57a2aae..14569e560b 100644
--- a/arch/arm/cpu/armv7/Kconfig
+++ b

[PATCH v4 4/8] arm: orion5x: finish moving SoC to mach-orion5x

2020-05-06 Thread Trevor Woerner
The SPL linker script had been left in arch/$(ARCH)/cpu/$(CPU)/$(SOC);
therefore move it to the already-established arch/$(ARCH)/mach-$(SOC)
location.

Signed-off-by: Trevor Woerner 

---

Changes in v4: None
Changes in v3: None
Changes in v2:
- Update patch to work on latest master; the location where the SPL linker
  script is specified has changed.

 arch/arm/{cpu/arm926ejs/orion5x => mach-orion5x}/u-boot-spl.lds | 0
 configs/edminiv2_defconfig  | 2 +-
 2 files changed, 1 insertion(+), 1 deletion(-)
 rename arch/arm/{cpu/arm926ejs/orion5x => mach-orion5x}/u-boot-spl.lds (100%)

diff --git a/arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds 
b/arch/arm/mach-orion5x/u-boot-spl.lds
similarity index 100%
rename from arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds
rename to arch/arm/mach-orion5x/u-boot-spl.lds
diff --git a/configs/edminiv2_defconfig b/configs/edminiv2_defconfig
index d06f83db04..9a9d9c58d7 100644
--- a/configs/edminiv2_defconfig
+++ b/configs/edminiv2_defconfig
@@ -1,7 +1,7 @@
 CONFIG_ARM=y
 CONFIG_ARCH_CPU_INIT=y
 CONFIG_ARCH_ORION5X=y
-CONFIG_SPL_LDSCRIPT="arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds"
+CONFIG_SPL_LDSCRIPT="arch/arm/mach-orion5x/u-boot-spl.lds"
 CONFIG_SYS_TEXT_BASE=0x0080
 CONFIG_SPL_LIBCOMMON_SUPPORT=y
 CONFIG_SPL_LIBGENERIC_SUPPORT=y
-- 
2.26.0.106.g9fadedd637



[PATCH v4 1/8] arm: lpc32xx: move SoC to mach-lpc32xx

2020-05-06 Thread Trevor Woerner
Following the example of most other SoCs in arch/$(ARCH)/cpu/$(CPU)/$(SOC)
move the lpc32xx code from arch/arm/cpu/arm926ejs/lpc32xx to
arch/arm/mach-lpc32xx.

Following the checklist from
commit 01f14456306c ("ARM: prepare for moving SoC sources into mach-*"):

[1] move files from arch/arm/cpu/arm926ejs/lpc32xx to arch/arm/mach-lpx32xx
[2] add machine entry to arch/arm/Makefile
[3] remove "obj-y += ..." from arch/arm/cpu/arm926ejs/Makefile
[4] fix the Kconfig file path in arch/arm/Kconfig
[5] (no MAINTAINERS update)

Reviewed-by: Simon Glass 
Signed-off-by: Trevor Woerner 

---

Changes in v4: None
Changes in v3:
- Add Simon Glass' r-b

Changes in v2:
- Update the commit message to fix the error identified by checkpatch.pl, namely
  to fix the formatting used to reference a prior commit.

 arch/arm/Kconfig| 2 +-
 arch/arm/Makefile   | 1 +
 arch/arm/cpu/arm926ejs/Makefile | 1 -
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig| 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile   | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c | 0
 .../arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c| 0
 11 files changed, 2 insertions(+), 2 deletions(-)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c (100%)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index b494bcae95..70b7b89b47 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1766,7 +1766,7 @@ source "arch/arm/mach-keystone/Kconfig"
 
 source "arch/arm/mach-kirkwood/Kconfig"
 
-source "arch/arm/cpu/arm926ejs/lpc32xx/Kconfig"
+source "arch/arm/mach-lpc32xx/Kconfig"
 
 source "arch/arm/mach-mvebu/Kconfig"
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index e25bb0e594..33bb8923bf 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -62,6 +62,7 @@ machine-$(CONFIG_ARCH_K3) += k3
 machine-$(CONFIG_ARCH_KEYSTONE)+= keystone
 # TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
 machine-$(CONFIG_KIRKWOOD) += kirkwood
+machine-$(CONFIG_ARCH_LPC32XX) += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
diff --git a/arch/arm/cpu/arm926ejs/Makefile b/arch/arm/cpu/arm926ejs/Makefile
index b051025bb0..af63d5cc5e 100644
--- a/arch/arm/cpu/arm926ejs/Makefile
+++ b/arch/arm/cpu/arm926ejs/Makefile
@@ -13,7 +13,6 @@ endif
 endif
 
 obj-$(CONFIG_ARMADA100) += armada100/
-obj-$(if $(filter lpc32xx,$(SOC)),y) += lpc32xx/
 obj-$(CONFIG_MX25) += mx25/
 obj-$(CONFIG_MX27) += mx27/
 obj-$(if $(filter mxs,$(SOC)),y) += mxs/
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Kconfig 
b/arch/arm/mach-lpc32xx/Kconfig
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Kconfig
rename to arch/arm/mach-lpc32xx/Kconfig
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Makefile 
b/arch/arm/mach-lpc32xx/Makefile
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Makefile
rename to arch/arm/mach-lpc32xx/Makefile
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/clk.c b/arch/arm/mach-lpc32xx/clk.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/clk.c
rename to arch/arm/mach-lpc32xx/clk.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/cpu.c b/arch/arm/mach-lpc32xx/cpu.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/cpu.c
rename to arch/arm/mach-lpc32xx/cpu.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/devices.c 
b/arch/arm/mach-lpc32xx/devices.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/devices.c
rename to arch/arm/mach-lpc32xx/devices.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/dram.c 
b/arch/arm/mach-lpc32xx/dram.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/dram.c
rename to arch/arm/mach-lpc32xx/dram.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/lowlevel_init.S 
b/arch/arm/mach-lpc32xx/lowlevel_init.S
similarity inde

[PATCH v4 7/8] rename symbol: CONFIG_STM32 -> CONFIG_ARCH_STM32

2020-05-06 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.

Signed-off-by: Trevor Woerner 
---

Changes in v4: None
Changes in v3: None
Changes in v2: None

 arch/arm/Kconfig   | 2 +-
 arch/arm/Makefile  | 2 +-
 arch/arm/mach-stm32/Kconfig| 2 +-
 configs/stm32f429-discovery_defconfig  | 2 +-
 configs/stm32f429-evaluation_defconfig | 2 +-
 configs/stm32f469-discovery_defconfig  | 2 +-
 configs/stm32f746-disco_defconfig  | 2 +-
 configs/stm32f769-disco_defconfig  | 2 +-
 configs/stm32h743-disco_defconfig  | 2 +-
 configs/stm32h743-eval_defconfig   | 2 +-
 drivers/gpio/Kconfig   | 2 +-
 drivers/misc/Kconfig   | 2 +-
 drivers/reset/Kconfig  | 2 +-
 13 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 574d1e246f..56972234b8 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1596,7 +1596,7 @@ config ARCH_UNIPHIER
  Support for UniPhier SoC family developed by Socionext Inc.
  (formerly, System LSI Business Division of Panasonic Corporation)
 
-config STM32
+config ARCH_STM32
bool "Support STMicroelectronics STM32 MCU with cortex M"
select CPU_V7M
select DM
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index e91b37fb34..94eb50bf72 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -73,7 +73,7 @@ machine-$(CONFIG_ARCH_ROCKCHIP)   += rockchip
 machine-$(CONFIG_ARCH_S5PC1XX) += s5pc1xx
 machine-$(CONFIG_ARCH_SNAPDRAGON)  += snapdragon
 machine-$(CONFIG_ARCH_SOCFPGA) += socfpga
-machine-$(CONFIG_STM32)+= stm32
+machine-$(CONFIG_ARCH_STM32)   += stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
 machine-$(CONFIG_ARCH_SUNXI)   += sunxi
 machine-$(CONFIG_ARCH_TEGRA)   += tegra
diff --git a/arch/arm/mach-stm32/Kconfig b/arch/arm/mach-stm32/Kconfig
index cea5ee2ce5..b42b05669a 100644
--- a/arch/arm/mach-stm32/Kconfig
+++ b/arch/arm/mach-stm32/Kconfig
@@ -1,4 +1,4 @@
-if STM32
+if ARCH_STM32
 
 config STM32F4
bool "stm32f4 family"
diff --git a/configs/stm32f429-discovery_defconfig 
b/configs/stm32f429-discovery_defconfig
index 52a577f97b..da43317ae5 100644
--- a/configs/stm32f429-discovery_defconfig
+++ b/configs/stm32f429-discovery_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f429-evaluation_defconfig 
b/configs/stm32f429-evaluation_defconfig
index 24f79b51bf..f67ce3e407 100644
--- a/configs/stm32f429-evaluation_defconfig
+++ b/configs/stm32f429-evaluation_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f469-discovery_defconfig 
b/configs/stm32f469-discovery_defconfig
index 0ab00514d5..082fb0cc19 100644
--- a/configs/stm32f469-discovery_defconfig
+++ b/configs/stm32f469-discovery_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f746-disco_defconfig 
b/configs/stm32f746-disco_defconfig
index cdfa8bbbc4..be030bfb37 100644
--- a/configs/stm32f746-disco_defconfig
+++ b/configs/stm32f746-disco_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x08008000
 CONFIG_SYS_MALLOC_F_LEN=0xE00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f769-disco_defconfig 
b/configs/stm32f769-disco_defconfig
index c40730e14a..09fbcc968f 100644
--- a/configs/stm32f769-disco_defconfig
+++ b/configs/stm32f769-disco_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x08008000
 CONFIG_SYS_MALLOC_F_LEN=0xE00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32h743-disco_defconfig 
b/configs/stm32h743-disco_defconfig
index 6b7a1d6d68..21ea90a2c1 100644
--- a/configs/stm32h743-disco_defconfig
+++ b/configs/stm32h743-disco_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32h743-eval_defconfig b/configs/stm32h743-eval_defconfig
index 7564d97707..432fce0181 100644
--- a/configs/stm32h743-eval_defconfig
+++ b/configs/stm32h743-eval_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index 2081520f42..d87f6cc105 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -318,7 +318,7 @@ config PIC32_GPIO
 
 config STM32_GPIO
bool "ST STM32 GPIO driver"
- 

[PATCH v4 0/8] A small set of arm cleanups

2020-05-06 Thread Trevor Woerner
This patch series presents a set of cleanups I stumbled across while looking
at some arm-related code.

A long time ago there was an effort to follow the Linux kernel's convention of
putting SoC-specific code in arch/$(ARCH)/mach-$(SOC) instead of the previous
location of arch/$(ARCH)/cpu/$(CPU)/$(SOC). For some reason this didn't occur
with code for NXP's LPC32xx SoC. Therefore the first patch performs this move.

While moving the code, I noticed that years of editing had caused a list in
arch/arm/Makefile to not be sorted alphanumerically anymore, despite the
comment's request to do so. Therefore the second patch re-orders the list to
put it back in alphanumerical order.

While sorting the above-mentioned list, I noticed that there were 4
symbol names that were not following the convention of other symbols:
CONFIG_KIRKWOOD, CONFIG_ORION5X, CONFIG_TEGRA, and CONFIG_STM32. These
symbols should have the pattern: CONFIG_ARCH_. Therefore more
patches were created to fix these symbol names.

While renaming the CONFIG_ARCH_ORION5X symbol I noticed that this SoC had
code both in arch/$(ARCH)/cpu/$(CPU)/$(SOC) and arch/$(ARCH)/mach-$(SOC),
so there's a patch to complete this move.

In the original series I only renamed 2 of the 4 symbols that were missing
the "ARCH_" string (CONFIG_ORION5X and CONFIG_KIRKWOOD), since those were
the only 2 with TODOs attached to them. As part of v2 I also converted
CONFIG_TEGRA and CONFIG_STM32

Also, I found a typo, so another patch, and I added a cover letter.


Changes in v4:
- Tweaked patch so it applies to master; some of the diff context lines have
  changed.

Changes in v3:
- Add Simon Glass' r-b

Changes in v2:
- Update the commit message to fix the error identified by checkpatch.pl, namely
  to fix the formatting used to reference a prior commit.
- Improve the wording of the commit message, mostly to specify that the sorting
  was done assuming all symbols had "ARCH_" in the middle.
- Update patch to work on latest master; the location where the SPL linker
  script is specified has changed.
- Update patch to work on latest master; the location where the SPL linker
  script is specified has changed.
- Add Chris Packham's r-b

Trevor Woerner (8):
  arm: lpc32xx: move SoC to mach-lpc32xx
  arch/arm/Makefile: sort machine names
  rename symbol: CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
  arm: orion5x: finish moving SoC to mach-orion5x
  rename symbol: CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
  rename symbol: CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
  rename symbol: CONFIG_STM32 -> CONFIG_ARCH_STM32
  drivers/reset/Kconfig: fix typo

 Kconfig   |  2 +-
 Makefile  |  4 ++--
 arch/arm/Kconfig  | 10 
 arch/arm/Makefile | 24 +--
 arch/arm/cpu/arm720t/interrupts.c |  2 +-
 arch/arm/cpu/arm926ejs/Makefile   |  1 -
 arch/arm/cpu/armv7/Kconfig|  2 +-
 arch/arm/dts/Makefile |  4 ++--
 arch/arm/mach-kirkwood/Kconfig|  2 +-
 .../lpc32xx => mach-lpc32xx}/Kconfig  |  0
 .../lpc32xx => mach-lpc32xx}/Makefile |  0
 .../arm926ejs/lpc32xx => mach-lpc32xx}/clk.c  |  0
 .../arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c  |  0
 .../lpc32xx => mach-lpc32xx}/devices.c|  0
 .../arm926ejs/lpc32xx => mach-lpc32xx}/dram.c |  0
 .../lpc32xx => mach-lpc32xx}/lowlevel_init.S  |  0
 .../lpc32xx => mach-lpc32xx}/timer.c  |  0
 arch/arm/mach-mvebu/Makefile  |  6 ++---
 arch/arm/mach-mvebu/mbus.c|  6 ++---
 arch/arm/mach-orion5x/Kconfig |  2 +-
 .../orion5x => mach-orion5x}/u-boot-spl.lds   |  0
 arch/arm/mach-stm32/Kconfig   |  2 +-
 arch/arm/mach-tegra/Kconfig   |  2 +-
 board/keymile/Kconfig | 12 +-
 common/spl/Kconfig|  4 ++--
 config.mk |  2 +-
 configs/SBx81LIFKW_defconfig  |  2 +-
 configs/SBx81LIFXCAT_defconfig|  2 +-
 configs/apalis-tk1_defconfig  |  2 +-
 configs/apalis_t30_defconfig  |  2 +-
 configs/beaver_defconfig  |  2 +-
 configs/cardhu_defconfig  |  2 +-
 configs/cei-tk1-som_defconfig |  2 +-
 configs/colibri_t20_defconfig |  2 +-
 configs/colibri_t30_defconfig |  2 +-
 configs/d2net_v2_defconfig|  2 +-
 configs/dalmore_defconfig |  2 +-
 configs/db-88f6281-bp-nand_defconfig  |  2 +-
 configs/db-88f6281-bp-spi_defconfig   |  2 +-
 configs/dns325_defconfig  |  2 +-
 configs/dockstar_defconfig|  2 +-
 configs/dreamplug_defconfig  

[PATCH v4 2/8] arch/arm/Makefile: sort machine names

2020-05-06 Thread Trevor Woerner
The comment immediately above the block of machine directory names implored
users to keep the macro names sorted, but, alas, this is no longer the case.

Put the list of machine directory names back in alphanumerical order by
CONFIG_* macro name, as the comment asks. Sort all the symbols as though they
all followed the convention of having the string "ARCH_" in the middle of
their definitions.

Signed-off-by: Trevor Woerner 

---

Changes in v4: None
Changes in v3: None
Changes in v2:
- Improve the wording of the commit message, mostly to specify that the sorting
  was done assuming all symbols had "ARCH_" in the middle.

 arch/arm/Makefile | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 33bb8923bf..5d32dec29c 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -66,25 +66,25 @@ machine-$(CONFIG_ARCH_LPC32XX)  += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
-# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
+machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
 # TODO: rename CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
 machine-$(CONFIG_ORION5X)  += orion5x
-machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
 machine-$(CONFIG_ARCH_OWL) += owl
+machine-$(CONFIG_ARCH_RMOBILE) += rmobile
+machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
 machine-$(CONFIG_ARCH_S5PC1XX) += s5pc1xx
-machine-$(CONFIG_ARCH_SUNXI)   += sunxi
 machine-$(CONFIG_ARCH_SNAPDRAGON)  += snapdragon
 machine-$(CONFIG_ARCH_SOCFPGA) += socfpga
-machine-$(CONFIG_ARCH_RMOBILE) += rmobile
-machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
 machine-$(CONFIG_STM32)+= stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
+machine-$(CONFIG_ARCH_SUNXI)   += sunxi
+# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
 machine-$(CONFIG_TEGRA)+= tegra
 machine-$(CONFIG_ARCH_U8500)   += u8500
 machine-$(CONFIG_ARCH_UNIPHIER)+= uniphier
+machine-$(CONFIG_ARCH_VERSAL)  += versal
 machine-$(CONFIG_ARCH_ZYNQ)+= zynq
 machine-$(CONFIG_ARCH_ZYNQMP)  += zynqmp
-machine-$(CONFIG_ARCH_VERSAL)  += versal
 machine-$(CONFIG_ARCH_ZYNQMP_R5)   += zynqmp-r5
 
 machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y))
-- 
2.26.0.106.g9fadedd637



[PATCH v3 8/8] drivers/reset/Kconfig: fix typo

2020-05-02 Thread Trevor Woerner
Signed-off-by: Trevor Woerner 

---

Changes in v3: None
Changes in v2: None

 drivers/reset/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/reset/Kconfig b/drivers/reset/Kconfig
index 65101ab4e8..88d3be1593 100644
--- a/drivers/reset/Kconfig
+++ b/drivers/reset/Kconfig
@@ -33,7 +33,7 @@ config STM32_RESET
depends on ARCH_STM32 || ARCH_STM32MP
help
  Support for reset controllers on STMicroelectronics STM32 family SoCs.
- This resset driver is compatible with STM32 F4/F7 and H7 SoCs.
+ This reset driver is compatible with STM32 F4/F7 and H7 SoCs.
 
 config TEGRA_CAR_RESET
bool "Enable Tegra CAR-based reset driver"
-- 
2.26.0.106.g9fadedd637



[PATCH v3 7/8] rename symbol: CONFIG_STM32 -> CONFIG_ARCH_STM32

2020-05-02 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.

Signed-off-by: Trevor Woerner 
---

Changes in v3: None
Changes in v2: None

 arch/arm/Kconfig   | 2 +-
 arch/arm/Makefile  | 2 +-
 arch/arm/mach-stm32/Kconfig| 2 +-
 configs/stm32f429-discovery_defconfig  | 2 +-
 configs/stm32f429-evaluation_defconfig | 2 +-
 configs/stm32f469-discovery_defconfig  | 2 +-
 configs/stm32f746-disco_defconfig  | 2 +-
 configs/stm32f769-disco_defconfig  | 2 +-
 configs/stm32h743-disco_defconfig  | 2 +-
 configs/stm32h743-eval_defconfig   | 2 +-
 drivers/gpio/Kconfig   | 2 +-
 drivers/misc/Kconfig   | 2 +-
 drivers/reset/Kconfig  | 2 +-
 13 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 574d1e246f..56972234b8 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1596,7 +1596,7 @@ config ARCH_UNIPHIER
  Support for UniPhier SoC family developed by Socionext Inc.
  (formerly, System LSI Business Division of Panasonic Corporation)
 
-config STM32
+config ARCH_STM32
bool "Support STMicroelectronics STM32 MCU with cortex M"
select CPU_V7M
select DM
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index e91b37fb34..94eb50bf72 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -73,7 +73,7 @@ machine-$(CONFIG_ARCH_ROCKCHIP)   += rockchip
 machine-$(CONFIG_ARCH_S5PC1XX) += s5pc1xx
 machine-$(CONFIG_ARCH_SNAPDRAGON)  += snapdragon
 machine-$(CONFIG_ARCH_SOCFPGA) += socfpga
-machine-$(CONFIG_STM32)+= stm32
+machine-$(CONFIG_ARCH_STM32)   += stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
 machine-$(CONFIG_ARCH_SUNXI)   += sunxi
 machine-$(CONFIG_ARCH_TEGRA)   += tegra
diff --git a/arch/arm/mach-stm32/Kconfig b/arch/arm/mach-stm32/Kconfig
index cea5ee2ce5..b42b05669a 100644
--- a/arch/arm/mach-stm32/Kconfig
+++ b/arch/arm/mach-stm32/Kconfig
@@ -1,4 +1,4 @@
-if STM32
+if ARCH_STM32
 
 config STM32F4
bool "stm32f4 family"
diff --git a/configs/stm32f429-discovery_defconfig 
b/configs/stm32f429-discovery_defconfig
index 52a577f97b..da43317ae5 100644
--- a/configs/stm32f429-discovery_defconfig
+++ b/configs/stm32f429-discovery_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f429-evaluation_defconfig 
b/configs/stm32f429-evaluation_defconfig
index 24f79b51bf..f67ce3e407 100644
--- a/configs/stm32f429-evaluation_defconfig
+++ b/configs/stm32f429-evaluation_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f469-discovery_defconfig 
b/configs/stm32f469-discovery_defconfig
index 0ab00514d5..082fb0cc19 100644
--- a/configs/stm32f469-discovery_defconfig
+++ b/configs/stm32f469-discovery_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f746-disco_defconfig 
b/configs/stm32f746-disco_defconfig
index cdfa8bbbc4..be030bfb37 100644
--- a/configs/stm32f746-disco_defconfig
+++ b/configs/stm32f746-disco_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x08008000
 CONFIG_SYS_MALLOC_F_LEN=0xE00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f769-disco_defconfig 
b/configs/stm32f769-disco_defconfig
index c40730e14a..09fbcc968f 100644
--- a/configs/stm32f769-disco_defconfig
+++ b/configs/stm32f769-disco_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x08008000
 CONFIG_SYS_MALLOC_F_LEN=0xE00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32h743-disco_defconfig 
b/configs/stm32h743-disco_defconfig
index 6b7a1d6d68..21ea90a2c1 100644
--- a/configs/stm32h743-disco_defconfig
+++ b/configs/stm32h743-disco_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32h743-eval_defconfig b/configs/stm32h743-eval_defconfig
index 7564d97707..432fce0181 100644
--- a/configs/stm32h743-eval_defconfig
+++ b/configs/stm32h743-eval_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index 2081520f42..d87f6cc105 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -318,7 +318,7 @@ config PIC32_GPIO
 
 config STM32_GPIO
bool "ST STM32 GPIO driver"
-   depends on DM_GPIO && (

[PATCH v3 6/8] rename symbol: CONFIG_TEGRA -> CONFIG_ARCH_TEGRA

2020-05-02 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.

Signed-off-by: Trevor Woerner 
---

Changes in v3: None
Changes in v2: None

 Makefile  | 4 ++--
 arch/arm/Kconfig  | 2 +-
 arch/arm/Makefile | 7 +++
 arch/arm/cpu/arm720t/interrupts.c | 2 +-
 arch/arm/cpu/armv7/Kconfig| 2 +-
 arch/arm/dts/Makefile | 2 +-
 arch/arm/mach-tegra/Kconfig   | 2 +-
 common/spl/Kconfig| 4 ++--
 config.mk | 2 +-
 configs/apalis-tk1_defconfig  | 2 +-
 configs/apalis_t30_defconfig  | 2 +-
 configs/beaver_defconfig  | 2 +-
 configs/cardhu_defconfig  | 2 +-
 configs/cei-tk1-som_defconfig | 2 +-
 configs/colibri_t20_defconfig | 2 +-
 configs/colibri_t30_defconfig | 2 +-
 configs/dalmore_defconfig | 2 +-
 configs/e2220-1170_defconfig  | 2 +-
 configs/harmony_defconfig | 2 +-
 configs/jetson-tk1_defconfig  | 2 +-
 configs/medcom-wide_defconfig | 2 +-
 configs/nyan-big_defconfig| 2 +-
 configs/p2371-_defconfig  | 2 +-
 configs/p2371-2180_defconfig  | 2 +-
 configs/p2571_defconfig   | 2 +-
 configs/p2771--000_defconfig  | 2 +-
 configs/p2771--500_defconfig  | 2 +-
 configs/p3450-_defconfig  | 2 +-
 configs/paz00_defconfig   | 2 +-
 configs/plutux_defconfig  | 2 +-
 configs/seaboard_defconfig| 2 +-
 configs/tec-ng_defconfig  | 2 +-
 configs/tec_defconfig | 2 +-
 configs/trimslice_defconfig   | 2 +-
 configs/venice2_defconfig | 2 +-
 configs/ventana_defconfig | 2 +-
 disk/Kconfig  | 4 ++--
 drivers/i2c/Kconfig   | 2 +-
 drivers/mailbox/Kconfig   | 2 +-
 drivers/mmc/Kconfig   | 2 +-
 drivers/pci/Kconfig   | 2 +-
 drivers/usb/host/Kconfig  | 2 +-
 drivers/video/Kconfig | 2 +-
 include/serial.h  | 2 +-
 44 files changed, 49 insertions(+), 50 deletions(-)

diff --git a/Makefile b/Makefile
index 6bb9cf55f2..e9264ca1e5 100644
--- a/Makefile
+++ b/Makefile
@@ -933,7 +933,7 @@ ALL-y += u-boot-sunxi-with-spl.bin
 endif
 
 # enable combined SPL/u-boot/dtb rules for tegra
-ifeq ($(CONFIG_TEGRA)$(CONFIG_SPL),yy)
+ifeq ($(CONFIG_ARCH_TEGRA)$(CONFIG_SPL),yy)
 ALL-y += u-boot-tegra.bin u-boot-nodtb-tegra.bin
 ALL-$(CONFIG_OF_SEPARATE) += u-boot-dtb-tegra.bin
 endif
@@ -1626,7 +1626,7 @@ u-boot-sunxi-with-spl.bin: spl/sunxi-spl.bin u-boot.itb 
FORCE
 endif
 endif
 
-ifneq ($(CONFIG_TEGRA),)
+ifneq ($(CONFIG_ARCH_TEGRA),)
 ifneq ($(CONFIG_BINMAN),)
 # Makes u-boot-dtb-tegra.bin u-boot-tegra.bin u-boot-nodtb-tegra.bin
 %-dtb-tegra.bin %-tegra.bin %-nodtb-tegra.bin: \
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 91185b9299..574d1e246f 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1142,7 +1142,7 @@ config ARCH_ZYNQMP
imply MP
imply DM_USB_GADGET
 
-config TEGRA
+config ARCH_TEGRA
bool "NVIDIA Tegra"
imply DISTRO_DEFAULTS
imply FAT_WRITE
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 9b3ca9772c..e91b37fb34 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -1,6 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0+
 
-ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_TEGRA),yy)
+ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_ARCH_TEGRA),yy)
 CONFIG_CPU_V7A=
 CONFIG_CPU_ARM720T=y
 endif
@@ -22,7 +22,7 @@ arch-$(CONFIG_ARM64)  =-march=armv8-a
 
 # On Tegra systems we must build SPL for the armv4 core on the device
 # but otherwise we can use the value in CONFIG_SYS_ARM_ARCH
-ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_TEGRA),yy)
+ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_ARCH_TEGRA),yy)
 arch-y += -D__LINUX_ARM_ARCH__=4
 else
 arch-y += -D__LINUX_ARM_ARCH__=$(CONFIG_SYS_ARM_ARCH)
@@ -76,8 +76,7 @@ machine-$(CONFIG_ARCH_SOCFPGA)+= socfpga
 machine-$(CONFIG_STM32)+= stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
 machine-$(CONFIG_ARCH_SUNXI)   += sunxi
-# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
-machine-$(CONFIG_TEGRA)+= tegra
+machine-$(CONFIG_ARCH_TEGRA)   += tegra
 machine-$(CONFIG_ARCH_U8500)   += u8500
 machine-$(CONFIG_ARCH_UNIPHIER)+= uniphier
 machine-$(CONFIG_ARCH_VERSAL)  += versal
diff --git a/arch/arm/cpu/arm720t/interrupts.c 
b/arch/arm/cpu/arm720t/interrupts.c
index 8437717a7b..f0fc58dead 100644
--- a/arch/arm/cpu/arm720t/interrupts.c
+++ b/arch/arm/cpu/arm720t/interrupts.c
@@ -11,7 +11,7 @@
 
 #include 
 
-#if defined(CONFIG_TEGRA)
+#if defined(CONFIG_ARCH_TEGRA)
 static ulong timestamp;
 static ulong lastdec;
 
diff --git a/arch/arm/cpu/armv7/Kconfig b/arch/arm/cpu/armv7/Kconfig
index 73d57a2aae..14569e560b 100644
--- a/arch/arm/cpu/armv7/Kconfig
+++ b/arch/arm/cpu/armv7/Kconfig
@@ -19,7 +19,7 @@ config ARMV7_NONSEC
 config ARMV7_BOOT_SEC_DEFAULT
bool "Boot in secu

[PATCH v3 3/8] rename symbol: CONFIG_ORION5X -> CONFIG_ARCH_ORION5X

2020-05-02 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.
This patch removes a TODO from the code.

Signed-off-by: Trevor Woerner 

---

Changes in v3: None
Changes in v2:
Update patch to work on latest master; the location where the SPL linker
script is specified has changed.

 arch/arm/Kconfig| 2 +-
 arch/arm/Makefile   | 3 +--
 arch/arm/mach-orion5x/Kconfig   | 2 +-
 configs/edminiv2_defconfig  | 2 +-
 drivers/ata/mvsata_ide.c| 2 +-
 drivers/i2c/mvtwsi.c| 2 +-
 drivers/net/Kconfig | 2 +-
 drivers/net/mvgbe.c | 2 +-
 drivers/usb/host/Kconfig| 2 +-
 drivers/usb/host/ehci-marvell.c | 2 +-
 10 files changed, 10 insertions(+), 11 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 70b7b89b47..5546329a47 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -576,7 +576,7 @@ config TARGET_APF27
select CPU_ARM926EJS
select SUPPORT_SPL
 
-config ORION5X
+config ARCH_ORION5X
bool "Marvell Orion"
select CPU_ARM926EJS
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 5d32dec29c..2b44ffb493 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -67,8 +67,7 @@ machine-$(CONFIG_ARCH_MEDIATEK)   += mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
 machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
-# TODO: rename CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
-machine-$(CONFIG_ORION5X)  += orion5x
+machine-$(CONFIG_ARCH_ORION5X) += orion5x
 machine-$(CONFIG_ARCH_OWL) += owl
 machine-$(CONFIG_ARCH_RMOBILE) += rmobile
 machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
diff --git a/arch/arm/mach-orion5x/Kconfig b/arch/arm/mach-orion5x/Kconfig
index 7644b8dc85..5baa6fb935 100644
--- a/arch/arm/mach-orion5x/Kconfig
+++ b/arch/arm/mach-orion5x/Kconfig
@@ -1,4 +1,4 @@
-if ORION5X
+if ARCH_ORION5X
 
 choice
prompt "Marvell Orion board select"
diff --git a/configs/edminiv2_defconfig b/configs/edminiv2_defconfig
index b9a68a9263..d06f83db04 100644
--- a/configs/edminiv2_defconfig
+++ b/configs/edminiv2_defconfig
@@ -1,6 +1,6 @@
 CONFIG_ARM=y
 CONFIG_ARCH_CPU_INIT=y
-CONFIG_ORION5X=y
+CONFIG_ARCH_ORION5X=y
 CONFIG_SPL_LDSCRIPT="arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds"
 CONFIG_SYS_TEXT_BASE=0x0080
 CONFIG_SPL_LIBCOMMON_SUPPORT=y
diff --git a/drivers/ata/mvsata_ide.c b/drivers/ata/mvsata_ide.c
index 38181235af..9ac16555d6 100644
--- a/drivers/ata/mvsata_ide.c
+++ b/drivers/ata/mvsata_ide.c
@@ -8,7 +8,7 @@
 #include 
 #include 
 
-#if defined(CONFIG_ORION5X)
+#if defined(CONFIG_ARCH_ORION5X)
 #include 
 #elif defined(CONFIG_KIRKWOOD)
 #include 
diff --git a/drivers/i2c/mvtwsi.c b/drivers/i2c/mvtwsi.c
index 382cf4b304..77fe35a42b 100644
--- a/drivers/i2c/mvtwsi.c
+++ b/drivers/i2c/mvtwsi.c
@@ -25,7 +25,7 @@ DECLARE_GLOBAL_DATA_PTR;
  */
 
 #ifndef CONFIG_DM_I2C
-#if defined(CONFIG_ORION5X)
+#if defined(CONFIG_ARCH_ORION5X)
 #include 
 #elif (defined(CONFIG_KIRKWOOD) || defined(CONFIG_ARCH_MVEBU))
 #include 
diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig
index bc518f218d..77ad823486 100644
--- a/drivers/net/Kconfig
+++ b/drivers/net/Kconfig
@@ -303,7 +303,7 @@ config FSLDMAFEC
 
 config MVGBE
bool "Marvell Orion5x/Kirkwood network interface support"
-   depends on KIRKWOOD || ORION5X
+   depends on KIRKWOOD || ARCH_ORION5X
select PHYLIB if DM_ETH
help
  This driver supports the network interface units in the
diff --git a/drivers/net/mvgbe.c b/drivers/net/mvgbe.c
index 037e59ec6e..b0b8d349a8 100644
--- a/drivers/net/mvgbe.c
+++ b/drivers/net/mvgbe.c
@@ -26,7 +26,7 @@
 
 #if defined(CONFIG_KIRKWOOD)
 #include 
-#elif defined(CONFIG_ORION5X)
+#elif defined(CONFIG_ARCH_ORION5X)
 #include 
 #endif
 
diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
index 94ac969058..ee9d6f2a1b 100644
--- a/drivers/usb/host/Kconfig
+++ b/drivers/usb/host/Kconfig
@@ -129,7 +129,7 @@ config USB_EHCI_ATMEL
 
 config USB_EHCI_MARVELL
bool "Support for Marvell on-chip EHCI USB controller"
-   depends on ARCH_MVEBU || KIRKWOOD || ORION5X
+   depends on ARCH_MVEBU || KIRKWOOD || ARCH_ORION5X
default y
---help---
  Enables support for the on-chip EHCI controller on MVEBU SoCs.
diff --git a/drivers/usb/host/ehci-marvell.c b/drivers/usb/host/ehci-marvell.c
index 8efe6b63b9..3b10cdfc58 100644
--- a/drivers/usb/host/ehci-marvell.c
+++ b/drivers/usb/host/ehci-marvell.c
@@ -15,7 +15,7 @@
 
 #if defined(CONFIG_KIRKWOOD)
 #include 
-#elif defined(CONFIG_ORION5X)
+#elif defined(CONFIG_ARCH_ORION5X)
 #include 
 #endif
 
-- 
2.26.0.106.g9fadedd637



[PATCH v3 4/8] arm: orion5x: finish moving SoC to mach-orion5x

2020-05-02 Thread Trevor Woerner
The SPL linker script had been left in arch/$(ARCH)/cpu/$(CPU)/$(SOC);
therefore move it to the already-established arch/$(ARCH)/mach-$(SOC)
location.

Signed-off-by: Trevor Woerner 

---

Changes in v3: None
Changes in v2:
Update patch to work on latest master; the location where the SPL linker
script is specified has changed.

 arch/arm/{cpu/arm926ejs/orion5x => mach-orion5x}/u-boot-spl.lds | 0
 configs/edminiv2_defconfig  | 2 +-
 2 files changed, 1 insertion(+), 1 deletion(-)
 rename arch/arm/{cpu/arm926ejs/orion5x => mach-orion5x}/u-boot-spl.lds (100%)

diff --git a/arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds 
b/arch/arm/mach-orion5x/u-boot-spl.lds
similarity index 100%
rename from arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds
rename to arch/arm/mach-orion5x/u-boot-spl.lds
diff --git a/configs/edminiv2_defconfig b/configs/edminiv2_defconfig
index d06f83db04..9a9d9c58d7 100644
--- a/configs/edminiv2_defconfig
+++ b/configs/edminiv2_defconfig
@@ -1,7 +1,7 @@
 CONFIG_ARM=y
 CONFIG_ARCH_CPU_INIT=y
 CONFIG_ARCH_ORION5X=y
-CONFIG_SPL_LDSCRIPT="arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds"
+CONFIG_SPL_LDSCRIPT="arch/arm/mach-orion5x/u-boot-spl.lds"
 CONFIG_SYS_TEXT_BASE=0x0080
 CONFIG_SPL_LIBCOMMON_SUPPORT=y
 CONFIG_SPL_LIBGENERIC_SUPPORT=y
-- 
2.26.0.106.g9fadedd637



[PATCH v3 1/8] arm: lpc32xx: move SoC to mach-lpc32xx

2020-05-02 Thread Trevor Woerner
Following the example of most other SoCs in arch/$(ARCH)/cpu/$(CPU)/$(SOC)
move the lpc32xx code from arch/arm/cpu/arm926ejs/lpc32xx to
arch/arm/mach-lpc32xx.

Following the checklist from
commit 01f14456306c ("ARM: prepare for moving SoC sources into mach-*"):

[1] move files from arch/arm/cpu/arm926ejs/lpc32xx to arch/arm/mach-lpx32xx
[2] add machine entry to arch/arm/Makefile
[3] remove "obj-y += ..." from arch/arm/cpu/arm926ejs/Makefile
[4] fix the Kconfig file path in arch/arm/Kconfig
[5] (no MAINTAINERS update)

Reviewed-by: Simon Glass 
Signed-off-by: Trevor Woerner 

---

Changes in v3:
Add Simon Glass' r-b

Changes in v2:
Update the commit message to fix the error identified by checkpatch.pl, namely
to fix the formatting used to reference a prior commit.

 arch/arm/Kconfig| 2 +-
 arch/arm/Makefile   | 1 +
 arch/arm/cpu/arm926ejs/Makefile | 1 -
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig| 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile   | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c | 0
 .../arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c| 0
 11 files changed, 2 insertions(+), 2 deletions(-)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c (100%)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index b494bcae95..70b7b89b47 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1766,7 +1766,7 @@ source "arch/arm/mach-keystone/Kconfig"
 
 source "arch/arm/mach-kirkwood/Kconfig"
 
-source "arch/arm/cpu/arm926ejs/lpc32xx/Kconfig"
+source "arch/arm/mach-lpc32xx/Kconfig"
 
 source "arch/arm/mach-mvebu/Kconfig"
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index e25bb0e594..33bb8923bf 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -62,6 +62,7 @@ machine-$(CONFIG_ARCH_K3) += k3
 machine-$(CONFIG_ARCH_KEYSTONE)+= keystone
 # TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
 machine-$(CONFIG_KIRKWOOD) += kirkwood
+machine-$(CONFIG_ARCH_LPC32XX) += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
diff --git a/arch/arm/cpu/arm926ejs/Makefile b/arch/arm/cpu/arm926ejs/Makefile
index b051025bb0..af63d5cc5e 100644
--- a/arch/arm/cpu/arm926ejs/Makefile
+++ b/arch/arm/cpu/arm926ejs/Makefile
@@ -13,7 +13,6 @@ endif
 endif
 
 obj-$(CONFIG_ARMADA100) += armada100/
-obj-$(if $(filter lpc32xx,$(SOC)),y) += lpc32xx/
 obj-$(CONFIG_MX25) += mx25/
 obj-$(CONFIG_MX27) += mx27/
 obj-$(if $(filter mxs,$(SOC)),y) += mxs/
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Kconfig 
b/arch/arm/mach-lpc32xx/Kconfig
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Kconfig
rename to arch/arm/mach-lpc32xx/Kconfig
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Makefile 
b/arch/arm/mach-lpc32xx/Makefile
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Makefile
rename to arch/arm/mach-lpc32xx/Makefile
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/clk.c b/arch/arm/mach-lpc32xx/clk.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/clk.c
rename to arch/arm/mach-lpc32xx/clk.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/cpu.c b/arch/arm/mach-lpc32xx/cpu.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/cpu.c
rename to arch/arm/mach-lpc32xx/cpu.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/devices.c 
b/arch/arm/mach-lpc32xx/devices.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/devices.c
rename to arch/arm/mach-lpc32xx/devices.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/dram.c 
b/arch/arm/mach-lpc32xx/dram.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/dram.c
rename to arch/arm/mach-lpc32xx/dram.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/lowlevel_init.S 
b/arch/arm/mach-lpc32xx/lowlevel_init.S
similarity index 100%
rename from arch

[PATCH v3 2/8] arch/arm/Makefile: sort machine names

2020-05-02 Thread Trevor Woerner
The comment immediately above the block of machine directory names implored
users to keep the macro names sorted, but, alas, this is no longer the case.

Put the list of machine directory names back in alphanumerical order by
CONFIG_* macro name, as the comment asks. Sort all the symbols as though they
all followed the convention of having the string "ARCH_" in the middle of
their definitions.

Signed-off-by: Trevor Woerner 

---

Changes in v3: None
Changes in v2:
Improve the wording of the commit message, mostly to specify that the sorting
was done assuming all symbols had "ARCH_" in the middle.

 arch/arm/Makefile | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 33bb8923bf..5d32dec29c 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -66,25 +66,25 @@ machine-$(CONFIG_ARCH_LPC32XX)  += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
-# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
+machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
 # TODO: rename CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
 machine-$(CONFIG_ORION5X)  += orion5x
-machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
 machine-$(CONFIG_ARCH_OWL) += owl
+machine-$(CONFIG_ARCH_RMOBILE) += rmobile
+machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
 machine-$(CONFIG_ARCH_S5PC1XX) += s5pc1xx
-machine-$(CONFIG_ARCH_SUNXI)   += sunxi
 machine-$(CONFIG_ARCH_SNAPDRAGON)  += snapdragon
 machine-$(CONFIG_ARCH_SOCFPGA) += socfpga
-machine-$(CONFIG_ARCH_RMOBILE) += rmobile
-machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
 machine-$(CONFIG_STM32)+= stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
+machine-$(CONFIG_ARCH_SUNXI)   += sunxi
+# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
 machine-$(CONFIG_TEGRA)+= tegra
 machine-$(CONFIG_ARCH_U8500)   += u8500
 machine-$(CONFIG_ARCH_UNIPHIER)+= uniphier
+machine-$(CONFIG_ARCH_VERSAL)  += versal
 machine-$(CONFIG_ARCH_ZYNQ)+= zynq
 machine-$(CONFIG_ARCH_ZYNQMP)  += zynqmp
-machine-$(CONFIG_ARCH_VERSAL)  += versal
 machine-$(CONFIG_ARCH_ZYNQMP_R5)   += zynqmp-r5
 
 machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y))
-- 
2.26.0.106.g9fadedd637



[PATCH v3 5/8] rename symbol: CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD

2020-05-02 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.
This patch also removes a TODO from the code.

Reviewed-by: Chris Packham 
Signed-off-by: Trevor Woerner 

---

Changes in v3: None
Changes in v2:
Add Chris Packham's r-b

 Kconfig  |  2 +-
 arch/arm/Kconfig |  2 +-
 arch/arm/Makefile|  3 +--
 arch/arm/dts/Makefile|  2 +-
 arch/arm/mach-kirkwood/Kconfig   |  2 +-
 arch/arm/mach-mvebu/Makefile |  6 +++---
 arch/arm/mach-mvebu/mbus.c   |  6 +++---
 board/keymile/Kconfig| 12 ++--
 configs/SBx81LIFKW_defconfig |  2 +-
 configs/SBx81LIFXCAT_defconfig   |  2 +-
 configs/d2net_v2_defconfig   |  2 +-
 configs/db-88f6281-bp-nand_defconfig |  2 +-
 configs/db-88f6281-bp-spi_defconfig  |  2 +-
 configs/dns325_defconfig |  2 +-
 configs/dockstar_defconfig   |  2 +-
 configs/dreamplug_defconfig  |  2 +-
 configs/ds109_defconfig  |  2 +-
 configs/goflexhome_defconfig |  2 +-
 configs/guruplug_defconfig   |  2 +-
 configs/ib62x0_defconfig |  2 +-
 configs/iconnect_defconfig   |  2 +-
 configs/inetspace_v2_defconfig   |  2 +-
 configs/km_kirkwood_128m16_defconfig |  2 +-
 configs/km_kirkwood_defconfig|  2 +-
 configs/km_kirkwood_pci_defconfig|  2 +-
 configs/kmcoge5un_defconfig  |  2 +-
 configs/kmnusa_defconfig |  2 +-
 configs/kmsuse2_defconfig|  2 +-
 configs/lschlv2_defconfig|  2 +-
 configs/lsxhl_defconfig  |  2 +-
 configs/nas220_defconfig |  2 +-
 configs/net2big_v2_defconfig |  2 +-
 configs/netspace_lite_v2_defconfig   |  2 +-
 configs/netspace_max_v2_defconfig|  2 +-
 configs/netspace_mini_v2_defconfig   |  2 +-
 configs/netspace_v2_defconfig|  2 +-
 configs/nsa310s_defconfig|  2 +-
 configs/openrd_base_defconfig|  2 +-
 configs/openrd_client_defconfig  |  2 +-
 configs/openrd_ultimate_defconfig|  2 +-
 configs/pogo_e02_defconfig   |  2 +-
 configs/sheevaplug_defconfig |  2 +-
 drivers/ata/mvsata_ide.c |  2 +-
 drivers/ata/sata_mv.c|  2 +-
 drivers/i2c/mvtwsi.c |  4 ++--
 drivers/net/Kconfig  |  2 +-
 drivers/net/mvgbe.c  |  2 +-
 drivers/spi/kirkwood_spi.c   | 10 +-
 drivers/usb/host/Kconfig |  2 +-
 drivers/usb/host/ehci-marvell.c  |  2 +-
 tools/Makefile   |  4 ++--
 51 files changed, 66 insertions(+), 67 deletions(-)

diff --git a/Kconfig b/Kconfig
index 15f1a75c61..0e7ccc0b07 100644
--- a/Kconfig
+++ b/Kconfig
@@ -268,7 +268,7 @@ config BUILD_TARGET
default "u-boot-elf.srec" if RCAR_GEN3
default "u-boot.itb" if SPL_LOAD_FIT && (ARCH_ROCKCHIP || \
ARCH_SUNXI || RISCV || ARCH_ZYNQMP)
-   default "u-boot.kwb" if KIRKWOOD
+   default "u-boot.kwb" if ARCH_KIRKWOOD
default "u-boot-with-spl.bin" if ARCH_AT91 && SPL_NAND_SUPPORT
default "u-boot-with-spl.imx" if ARCH_MX6 && SPL
help
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 5546329a47..91185b9299 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -553,7 +553,7 @@ config ARCH_DAVINCI
help
  Support for TI's DaVinci platform.
 
-config KIRKWOOD
+config ARCH_KIRKWOOD
bool "Marvell Kirkwood"
select ARCH_MISC_INIT
select BOARD_EARLY_INIT_F
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 2b44ffb493..9b3ca9772c 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -60,8 +60,7 @@ machine-$(CONFIG_ARCH_EXYNOS) += exynos
 machine-$(CONFIG_ARCH_HIGHBANK)+= highbank
 machine-$(CONFIG_ARCH_K3)  += k3
 machine-$(CONFIG_ARCH_KEYSTONE)+= keystone
-# TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
-machine-$(CONFIG_KIRKWOOD) += kirkwood
+machine-$(CONFIG_ARCH_KIRKWOOD)+= kirkwood
 machine-$(CONFIG_ARCH_LPC32XX) += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 2c123bd6da..49f79f6eb0 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -34,7 +34,7 @@ dtb-$(CONFIG_ARCH_DAVINCI) += \
da850-lcdk.dtb \
da850-lego-ev3.dtb
 
-dtb-$(CONFIG_KIRKWOOD) += \
+dtb-$(CONFIG_ARCH_KIRKWOOD) += \
kirkwood-atl-sbx81lifkw.dtb \
kirkwood-atl-sbx81lifxcat.dtb \
kirkwood-blackarmor-nas220.dtb \
diff --git a/arch/arm/mach-kirkwood/Kconfig b/arch/arm/mach-kirkwood/Kconfig
index 2f68092f82..ae44cb665e 100644
--- a/arch/arm/mach-kirkwood/Kconfig
+++ b/arch/arm/mach-kirkw

[PATCH v3 0/8] A small set of arm cleanups

2020-05-02 Thread Trevor Woerner
This patch series presents a set of cleanups I stumbled across while looking
at some arm-related code.

A long time ago there was an effort to follow the Linux kernel's convention of
putting SoC-specific code in arch/$(ARCH)/mach-$(SOC) instead of the previous
location of arch/$(ARCH)/cpu/$(CPU)/$(SOC). For some reason this didn't occur
with code for NXP's LPC32xx SoC. Therefore the first patch performs this move.

While moving the code, I noticed that years of editing had caused a list in
arch/arm/Makefile to not be sorted alphanumerically anymore, despite the
comment's request to do so. Therefore the second patch re-orders the list to
put it back in alphanumerical order.

While sorting the above-mentioned list, I noticed that there were 4
symbol names that were not following the convention of other symbols:
CONFIG_KIRKWOOD, CONFIG_ORION5X, CONFIG_TEGRA, and CONFIG_STM32. These
symbols should have the pattern: CONFIG_ARCH_. Therefore more
patches were created to fix these symbol names.

While renaming the CONFIG_ARCH_ORION5X symbol I noticed that this SoC had
code both in arch/$(ARCH)/cpu/$(CPU)/$(SOC) and arch/$(ARCH)/mach-$(SOC),
so there's a patch to complete this move.

In the original series I only renamed 2 of the 4 symbols that were missing
the "ARCH_" stinrg (CONFIG_ORION5X and CONFIG_KIRKWOOD), since those were
the only 2 with TODOs attached to them. As part of v2 I also converted
CONFIG_TEGRA and CONFIG_STM32

Also, I found a typo, so another patch, and I added a cover letter.


Changes in v3:
Add Simon Glass' r-b

Changes in v2:
Update the commit message to fix the error identified by checkpatch.pl, namely
to fix the formatting used to reference a prior commit.
Improve the wording of the commit message, mostly to specify that the sorting
was done assuming all symbols had "ARCH_" in the middle.
Update patch to work on latest master; the location where the SPL linker
script is specified has changed.
Update patch to work on latest master; the location where the SPL linker
script is specified has changed.
Add Chris Packham's r-b

Trevor Woerner (8):
  arm: lpc32xx: move SoC to mach-lpc32xx
  arch/arm/Makefile: sort machine names
  rename symbol: CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
  arm: orion5x: finish moving SoC to mach-orion5x
  rename symbol: CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
  rename symbol: CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
  rename symbol: CONFIG_STM32 -> CONFIG_ARCH_STM32
  drivers/reset/Kconfig: fix typo

 Kconfig   |  2 +-
 Makefile  |  4 ++--
 arch/arm/Kconfig  | 10 
 arch/arm/Makefile | 24 +--
 arch/arm/cpu/arm720t/interrupts.c |  2 +-
 arch/arm/cpu/arm926ejs/Makefile   |  1 -
 arch/arm/cpu/armv7/Kconfig|  2 +-
 arch/arm/dts/Makefile |  4 ++--
 arch/arm/mach-kirkwood/Kconfig|  2 +-
 .../lpc32xx => mach-lpc32xx}/Kconfig  |  0
 .../lpc32xx => mach-lpc32xx}/Makefile |  0
 .../arm926ejs/lpc32xx => mach-lpc32xx}/clk.c  |  0
 .../arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c  |  0
 .../lpc32xx => mach-lpc32xx}/devices.c|  0
 .../arm926ejs/lpc32xx => mach-lpc32xx}/dram.c |  0
 .../lpc32xx => mach-lpc32xx}/lowlevel_init.S  |  0
 .../lpc32xx => mach-lpc32xx}/timer.c  |  0
 arch/arm/mach-mvebu/Makefile  |  6 ++---
 arch/arm/mach-mvebu/mbus.c|  6 ++---
 arch/arm/mach-orion5x/Kconfig |  2 +-
 .../orion5x => mach-orion5x}/u-boot-spl.lds   |  0
 arch/arm/mach-stm32/Kconfig   |  2 +-
 arch/arm/mach-tegra/Kconfig   |  2 +-
 board/keymile/Kconfig | 12 +-
 common/spl/Kconfig|  4 ++--
 config.mk |  2 +-
 configs/SBx81LIFKW_defconfig  |  2 +-
 configs/SBx81LIFXCAT_defconfig|  2 +-
 configs/apalis-tk1_defconfig  |  2 +-
 configs/apalis_t30_defconfig  |  2 +-
 configs/beaver_defconfig  |  2 +-
 configs/cardhu_defconfig  |  2 +-
 configs/cei-tk1-som_defconfig |  2 +-
 configs/colibri_t20_defconfig |  2 +-
 configs/colibri_t30_defconfig |  2 +-
 configs/d2net_v2_defconfig|  2 +-
 configs/dalmore_defconfig |  2 +-
 configs/db-88f6281-bp-nand_defconfig  |  2 +-
 configs/db-88f6281-bp-spi_defconfig   |  2 +-
 configs/dns325_defconfig  |  2 +-
 configs/dockstar_defconfig|  2 +-
 configs/dreamplug_defconfig   |  2 +-
 configs/ds109_defconfig   |  2 +-
 configs/e2220-1170_defconfig  

[PATCH v2 8/8] drivers/reset/Kconfig: fix typo

2020-04-17 Thread Trevor Woerner
Signed-off-by: Trevor Woerner 

---

Changes in v2: added

 drivers/reset/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/reset/Kconfig b/drivers/reset/Kconfig
index 65101ab4e8..88d3be1593 100644
--- a/drivers/reset/Kconfig
+++ b/drivers/reset/Kconfig
@@ -33,7 +33,7 @@ config STM32_RESET
depends on ARCH_STM32 || ARCH_STM32MP
help
  Support for reset controllers on STMicroelectronics STM32 family SoCs.
- This resset driver is compatible with STM32 F4/F7 and H7 SoCs.
+ This reset driver is compatible with STM32 F4/F7 and H7 SoCs.
 
 config TEGRA_CAR_RESET
bool "Enable Tegra CAR-based reset driver"
-- 
2.26.0.106.g9fadedd637



[PATCH v2 5/8] rename symbol: CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD

2020-04-17 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.
This patch also removes a TODO from the code.

Reviewed-by: Chris Packham 
Signed-off-by: Trevor Woerner 

---

Changes in v2:
Add Chris Packham's r-b

 Kconfig  |  2 +-
 arch/arm/Kconfig |  2 +-
 arch/arm/Makefile|  3 +--
 arch/arm/dts/Makefile|  2 +-
 arch/arm/mach-kirkwood/Kconfig   |  2 +-
 arch/arm/mach-mvebu/Makefile |  6 +++---
 arch/arm/mach-mvebu/mbus.c   |  6 +++---
 board/keymile/Kconfig| 12 ++--
 configs/SBx81LIFKW_defconfig |  2 +-
 configs/SBx81LIFXCAT_defconfig   |  2 +-
 configs/d2net_v2_defconfig   |  2 +-
 configs/db-88f6281-bp-nand_defconfig |  2 +-
 configs/db-88f6281-bp-spi_defconfig  |  2 +-
 configs/dns325_defconfig |  2 +-
 configs/dockstar_defconfig   |  2 +-
 configs/dreamplug_defconfig  |  2 +-
 configs/ds109_defconfig  |  2 +-
 configs/goflexhome_defconfig |  2 +-
 configs/guruplug_defconfig   |  2 +-
 configs/ib62x0_defconfig |  2 +-
 configs/iconnect_defconfig   |  2 +-
 configs/inetspace_v2_defconfig   |  2 +-
 configs/km_kirkwood_128m16_defconfig |  2 +-
 configs/km_kirkwood_defconfig|  2 +-
 configs/km_kirkwood_pci_defconfig|  2 +-
 configs/kmcoge5un_defconfig  |  2 +-
 configs/kmnusa_defconfig |  2 +-
 configs/kmsuse2_defconfig|  2 +-
 configs/lschlv2_defconfig|  2 +-
 configs/lsxhl_defconfig  |  2 +-
 configs/nas220_defconfig |  2 +-
 configs/net2big_v2_defconfig |  2 +-
 configs/netspace_lite_v2_defconfig   |  2 +-
 configs/netspace_max_v2_defconfig|  2 +-
 configs/netspace_mini_v2_defconfig   |  2 +-
 configs/netspace_v2_defconfig|  2 +-
 configs/nsa310s_defconfig|  2 +-
 configs/openrd_base_defconfig|  2 +-
 configs/openrd_client_defconfig  |  2 +-
 configs/openrd_ultimate_defconfig|  2 +-
 configs/pogo_e02_defconfig   |  2 +-
 configs/sheevaplug_defconfig |  2 +-
 drivers/ata/mvsata_ide.c |  2 +-
 drivers/ata/sata_mv.c|  2 +-
 drivers/i2c/mvtwsi.c |  4 ++--
 drivers/net/Kconfig  |  2 +-
 drivers/net/mvgbe.c  |  2 +-
 drivers/spi/kirkwood_spi.c   | 10 +-
 drivers/usb/host/Kconfig |  2 +-
 drivers/usb/host/ehci-marvell.c  |  2 +-
 tools/Makefile   |  4 ++--
 51 files changed, 66 insertions(+), 67 deletions(-)

diff --git a/Kconfig b/Kconfig
index 1b0b6999d8..ca5ed9431d 100644
--- a/Kconfig
+++ b/Kconfig
@@ -254,7 +254,7 @@ config BUILD_TARGET
default "u-boot-elf.srec" if RCAR_GEN3
default "u-boot.itb" if SPL_LOAD_FIT && (ARCH_ROCKCHIP || \
ARCH_SUNXI || RISCV || ARCH_ZYNQMP)
-   default "u-boot.kwb" if KIRKWOOD
+   default "u-boot.kwb" if ARCH_KIRKWOOD
default "u-boot-with-spl.bin" if ARCH_AT91 && SPL_NAND_SUPPORT
default "u-boot-with-spl.imx" if ARCH_MX6 && SPL
help
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 5b77b0d613..6bc1776cfd 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -524,7 +524,7 @@ config ARCH_DAVINCI
help
  Support for TI's DaVinci platform.
 
-config KIRKWOOD
+config ARCH_KIRKWOOD
bool "Marvell Kirkwood"
select ARCH_MISC_INIT
select BOARD_EARLY_INIT_F
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 2b44ffb493..9b3ca9772c 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -60,8 +60,7 @@ machine-$(CONFIG_ARCH_EXYNOS) += exynos
 machine-$(CONFIG_ARCH_HIGHBANK)+= highbank
 machine-$(CONFIG_ARCH_K3)  += k3
 machine-$(CONFIG_ARCH_KEYSTONE)+= keystone
-# TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
-machine-$(CONFIG_KIRKWOOD) += kirkwood
+machine-$(CONFIG_ARCH_KIRKWOOD)+= kirkwood
 machine-$(CONFIG_ARCH_LPC32XX) += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 6d1e8668e7..20d3adc5d4 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -34,7 +34,7 @@ dtb-$(CONFIG_ARCH_DAVINCI) += \
da850-lcdk.dtb \
da850-lego-ev3.dtb
 
-dtb-$(CONFIG_KIRKWOOD) += \
+dtb-$(CONFIG_ARCH_KIRKWOOD) += \
kirkwood-atl-sbx81lifkw.dtb \
kirkwood-atl-sbx81lifxcat.dtb \
kirkwood-blackarmor-nas220.dtb \
diff --git a/arch/arm/mach-kirkwood/Kconfig b/arch/arm/mach-kirkwood/Kconfig
index 2f68092f82..ae44cb665e 100644
--- a/arch/arm/mach-kirkwood/Kconfig
+++ b/arch/arm/mach-kirkwood/Kconfig
@@ -1,4 +1,4 @

[PATCH v2 6/8] rename symbol: CONFIG_TEGRA -> CONFIG_ARCH_TEGRA

2020-04-17 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.

Signed-off-by: Trevor Woerner 
---

Changes in v2: added

 Makefile  | 4 ++--
 arch/arm/Kconfig  | 2 +-
 arch/arm/Makefile | 7 +++
 arch/arm/cpu/arm720t/interrupts.c | 2 +-
 arch/arm/cpu/armv7/Kconfig| 2 +-
 arch/arm/dts/Makefile | 2 +-
 arch/arm/mach-tegra/Kconfig   | 2 +-
 common/spl/Kconfig| 4 ++--
 config.mk | 2 +-
 configs/apalis-tk1_defconfig  | 2 +-
 configs/apalis_t30_defconfig  | 2 +-
 configs/beaver_defconfig  | 2 +-
 configs/cardhu_defconfig  | 2 +-
 configs/cei-tk1-som_defconfig | 2 +-
 configs/colibri_t20_defconfig | 2 +-
 configs/colibri_t30_defconfig | 2 +-
 configs/dalmore_defconfig | 2 +-
 configs/e2220-1170_defconfig  | 2 +-
 configs/harmony_defconfig | 2 +-
 configs/jetson-tk1_defconfig  | 2 +-
 configs/medcom-wide_defconfig | 2 +-
 configs/nyan-big_defconfig| 2 +-
 configs/p2371-_defconfig  | 2 +-
 configs/p2371-2180_defconfig  | 2 +-
 configs/p2571_defconfig   | 2 +-
 configs/p2771--000_defconfig  | 2 +-
 configs/p2771--500_defconfig  | 2 +-
 configs/p3450-_defconfig  | 2 +-
 configs/paz00_defconfig   | 2 +-
 configs/plutux_defconfig  | 2 +-
 configs/seaboard_defconfig| 2 +-
 configs/tec-ng_defconfig  | 2 +-
 configs/tec_defconfig | 2 +-
 configs/trimslice_defconfig   | 2 +-
 configs/venice2_defconfig | 2 +-
 configs/ventana_defconfig | 2 +-
 disk/Kconfig  | 4 ++--
 drivers/i2c/Kconfig   | 2 +-
 drivers/mailbox/Kconfig   | 2 +-
 drivers/mmc/Kconfig   | 2 +-
 drivers/pci/Kconfig   | 2 +-
 drivers/usb/host/Kconfig  | 2 +-
 drivers/video/Kconfig | 2 +-
 include/serial.h  | 2 +-
 44 files changed, 49 insertions(+), 50 deletions(-)

diff --git a/Makefile b/Makefile
index 26307fd4a6..882fa91295 100644
--- a/Makefile
+++ b/Makefile
@@ -931,7 +931,7 @@ ALL-y += u-boot-sunxi-with-spl.bin
 endif
 
 # enable combined SPL/u-boot/dtb rules for tegra
-ifeq ($(CONFIG_TEGRA)$(CONFIG_SPL),yy)
+ifeq ($(CONFIG_ARCH_TEGRA)$(CONFIG_SPL),yy)
 ALL-y += u-boot-tegra.bin u-boot-nodtb-tegra.bin
 ALL-$(CONFIG_OF_SEPARATE) += u-boot-dtb-tegra.bin
 endif
@@ -1609,7 +1609,7 @@ u-boot-sunxi-with-spl.bin: spl/sunxi-spl.bin u-boot.itb 
FORCE
 endif
 endif
 
-ifneq ($(CONFIG_TEGRA),)
+ifneq ($(CONFIG_ARCH_TEGRA),)
 ifneq ($(CONFIG_BINMAN),)
 # Makes u-boot-dtb-tegra.bin u-boot-tegra.bin u-boot-nodtb-tegra.bin
 %-dtb-tegra.bin %-tegra.bin %-nodtb-tegra.bin: \
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 6bc1776cfd..4b0cab553a 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1109,7 +1109,7 @@ config ARCH_ZYNQMP
imply MP
imply DM_USB_GADGET
 
-config TEGRA
+config ARCH_TEGRA
bool "NVIDIA Tegra"
imply DISTRO_DEFAULTS
imply FAT_WRITE
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 9b3ca9772c..e91b37fb34 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -1,6 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0+
 
-ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_TEGRA),yy)
+ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_ARCH_TEGRA),yy)
 CONFIG_CPU_V7A=
 CONFIG_CPU_ARM720T=y
 endif
@@ -22,7 +22,7 @@ arch-$(CONFIG_ARM64)  =-march=armv8-a
 
 # On Tegra systems we must build SPL for the armv4 core on the device
 # but otherwise we can use the value in CONFIG_SYS_ARM_ARCH
-ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_TEGRA),yy)
+ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_ARCH_TEGRA),yy)
 arch-y += -D__LINUX_ARM_ARCH__=4
 else
 arch-y += -D__LINUX_ARM_ARCH__=$(CONFIG_SYS_ARM_ARCH)
@@ -76,8 +76,7 @@ machine-$(CONFIG_ARCH_SOCFPGA)+= socfpga
 machine-$(CONFIG_STM32)+= stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
 machine-$(CONFIG_ARCH_SUNXI)   += sunxi
-# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
-machine-$(CONFIG_TEGRA)+= tegra
+machine-$(CONFIG_ARCH_TEGRA)   += tegra
 machine-$(CONFIG_ARCH_U8500)   += u8500
 machine-$(CONFIG_ARCH_UNIPHIER)+= uniphier
 machine-$(CONFIG_ARCH_VERSAL)  += versal
diff --git a/arch/arm/cpu/arm720t/interrupts.c 
b/arch/arm/cpu/arm720t/interrupts.c
index 8437717a7b..f0fc58dead 100644
--- a/arch/arm/cpu/arm720t/interrupts.c
+++ b/arch/arm/cpu/arm720t/interrupts.c
@@ -11,7 +11,7 @@
 
 #include 
 
-#if defined(CONFIG_TEGRA)
+#if defined(CONFIG_ARCH_TEGRA)
 static ulong timestamp;
 static ulong lastdec;
 
diff --git a/arch/arm/cpu/armv7/Kconfig b/arch/arm/cpu/armv7/Kconfig
index 73d57a2aae..14569e560b 100644
--- a/arch/arm/cpu/armv7/Kconfig
+++ b/arch/arm/cpu/armv7/Kconfig
@@ -19,7 +19,7 @@ config ARMV7_NONSEC
 config ARMV7_BOOT_SEC_DEFAULT
bool "Boot in secure mode by 

[PATCH v2 3/8] rename symbol: CONFIG_ORION5X -> CONFIG_ARCH_ORION5X

2020-04-17 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.
This patch removes a TODO from the code.

Signed-off-by: Trevor Woerner 

---

Changes in v2:
Update patch to work on latest master; the location where the SPL linker
script is specified has changed.

 arch/arm/Kconfig| 2 +-
 arch/arm/Makefile   | 3 +--
 arch/arm/mach-orion5x/Kconfig   | 2 +-
 configs/edminiv2_defconfig  | 2 +-
 drivers/ata/mvsata_ide.c| 2 +-
 drivers/i2c/mvtwsi.c| 2 +-
 drivers/net/Kconfig | 2 +-
 drivers/net/mvgbe.c | 2 +-
 drivers/usb/host/Kconfig| 2 +-
 drivers/usb/host/ehci-marvell.c | 2 +-
 10 files changed, 10 insertions(+), 11 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 8567c15c26..5b77b0d613 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -547,7 +547,7 @@ config TARGET_APF27
select CPU_ARM926EJS
select SUPPORT_SPL
 
-config ORION5X
+config ARCH_ORION5X
bool "Marvell Orion"
select CPU_ARM926EJS
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 5d32dec29c..2b44ffb493 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -67,8 +67,7 @@ machine-$(CONFIG_ARCH_MEDIATEK)   += mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
 machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
-# TODO: rename CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
-machine-$(CONFIG_ORION5X)  += orion5x
+machine-$(CONFIG_ARCH_ORION5X) += orion5x
 machine-$(CONFIG_ARCH_OWL) += owl
 machine-$(CONFIG_ARCH_RMOBILE) += rmobile
 machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
diff --git a/arch/arm/mach-orion5x/Kconfig b/arch/arm/mach-orion5x/Kconfig
index 7644b8dc85..5baa6fb935 100644
--- a/arch/arm/mach-orion5x/Kconfig
+++ b/arch/arm/mach-orion5x/Kconfig
@@ -1,4 +1,4 @@
-if ORION5X
+if ARCH_ORION5X
 
 choice
prompt "Marvell Orion board select"
diff --git a/configs/edminiv2_defconfig b/configs/edminiv2_defconfig
index b9a68a9263..d06f83db04 100644
--- a/configs/edminiv2_defconfig
+++ b/configs/edminiv2_defconfig
@@ -1,6 +1,6 @@
 CONFIG_ARM=y
 CONFIG_ARCH_CPU_INIT=y
-CONFIG_ORION5X=y
+CONFIG_ARCH_ORION5X=y
 CONFIG_SPL_LDSCRIPT="arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds"
 CONFIG_SYS_TEXT_BASE=0x0080
 CONFIG_SPL_LIBCOMMON_SUPPORT=y
diff --git a/drivers/ata/mvsata_ide.c b/drivers/ata/mvsata_ide.c
index 38181235af..9ac16555d6 100644
--- a/drivers/ata/mvsata_ide.c
+++ b/drivers/ata/mvsata_ide.c
@@ -8,7 +8,7 @@
 #include 
 #include 
 
-#if defined(CONFIG_ORION5X)
+#if defined(CONFIG_ARCH_ORION5X)
 #include 
 #elif defined(CONFIG_KIRKWOOD)
 #include 
diff --git a/drivers/i2c/mvtwsi.c b/drivers/i2c/mvtwsi.c
index 382cf4b304..77fe35a42b 100644
--- a/drivers/i2c/mvtwsi.c
+++ b/drivers/i2c/mvtwsi.c
@@ -25,7 +25,7 @@ DECLARE_GLOBAL_DATA_PTR;
  */
 
 #ifndef CONFIG_DM_I2C
-#if defined(CONFIG_ORION5X)
+#if defined(CONFIG_ARCH_ORION5X)
 #include 
 #elif (defined(CONFIG_KIRKWOOD) || defined(CONFIG_ARCH_MVEBU))
 #include 
diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig
index 4d1013c984..3fd3e72219 100644
--- a/drivers/net/Kconfig
+++ b/drivers/net/Kconfig
@@ -303,7 +303,7 @@ config FSLDMAFEC
 
 config MVGBE
bool "Marvell Orion5x/Kirkwood network interface support"
-   depends on KIRKWOOD || ORION5X
+   depends on KIRKWOOD || ARCH_ORION5X
select PHYLIB if DM_ETH
help
  This driver supports the network interface units in the
diff --git a/drivers/net/mvgbe.c b/drivers/net/mvgbe.c
index 037e59ec6e..b0b8d349a8 100644
--- a/drivers/net/mvgbe.c
+++ b/drivers/net/mvgbe.c
@@ -26,7 +26,7 @@
 
 #if defined(CONFIG_KIRKWOOD)
 #include 
-#elif defined(CONFIG_ORION5X)
+#elif defined(CONFIG_ARCH_ORION5X)
 #include 
 #endif
 
diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
index 94ac969058..ee9d6f2a1b 100644
--- a/drivers/usb/host/Kconfig
+++ b/drivers/usb/host/Kconfig
@@ -129,7 +129,7 @@ config USB_EHCI_ATMEL
 
 config USB_EHCI_MARVELL
bool "Support for Marvell on-chip EHCI USB controller"
-   depends on ARCH_MVEBU || KIRKWOOD || ORION5X
+   depends on ARCH_MVEBU || KIRKWOOD || ARCH_ORION5X
default y
---help---
  Enables support for the on-chip EHCI controller on MVEBU SoCs.
diff --git a/drivers/usb/host/ehci-marvell.c b/drivers/usb/host/ehci-marvell.c
index 8efe6b63b9..3b10cdfc58 100644
--- a/drivers/usb/host/ehci-marvell.c
+++ b/drivers/usb/host/ehci-marvell.c
@@ -15,7 +15,7 @@
 
 #if defined(CONFIG_KIRKWOOD)
 #include 
-#elif defined(CONFIG_ORION5X)
+#elif defined(CONFIG_ARCH_ORION5X)
 #include 
 #endif
 
-- 
2.26.0.106.g9fadedd637



[PATCH v2 2/8] arch/arm/Makefile: sort machine names

2020-04-17 Thread Trevor Woerner
The comment immediately above the block of machine directory names implored
users to keep the macro names sorted, but, alas, this is no longer the case.

Put the list of machine directory names back in alphanumerical order by
CONFIG_* macro name, as the comment asks. Sort all the symbols as though they
all followed the convention of having the string "ARCH_" in the middle of
their definitions.

Signed-off-by: Trevor Woerner 

---

Changes in v2:
Improve the wording of the commit message, mostly to specify that the sorting
was done assuming all symbols had "ARCH_" in the middle.

 arch/arm/Makefile | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 33bb8923bf..5d32dec29c 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -66,25 +66,25 @@ machine-$(CONFIG_ARCH_LPC32XX)  += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
-# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
+machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
 # TODO: rename CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
 machine-$(CONFIG_ORION5X)  += orion5x
-machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
 machine-$(CONFIG_ARCH_OWL) += owl
+machine-$(CONFIG_ARCH_RMOBILE) += rmobile
+machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
 machine-$(CONFIG_ARCH_S5PC1XX) += s5pc1xx
-machine-$(CONFIG_ARCH_SUNXI)   += sunxi
 machine-$(CONFIG_ARCH_SNAPDRAGON)  += snapdragon
 machine-$(CONFIG_ARCH_SOCFPGA) += socfpga
-machine-$(CONFIG_ARCH_RMOBILE) += rmobile
-machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
 machine-$(CONFIG_STM32)+= stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
+machine-$(CONFIG_ARCH_SUNXI)   += sunxi
+# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
 machine-$(CONFIG_TEGRA)+= tegra
 machine-$(CONFIG_ARCH_U8500)   += u8500
 machine-$(CONFIG_ARCH_UNIPHIER)+= uniphier
+machine-$(CONFIG_ARCH_VERSAL)  += versal
 machine-$(CONFIG_ARCH_ZYNQ)+= zynq
 machine-$(CONFIG_ARCH_ZYNQMP)  += zynqmp
-machine-$(CONFIG_ARCH_VERSAL)  += versal
 machine-$(CONFIG_ARCH_ZYNQMP_R5)   += zynqmp-r5
 
 machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y))
-- 
2.26.0.106.g9fadedd637



[PATCH v2 4/8] arm: orion5x: finish moving SoC to mach-orion5x

2020-04-17 Thread Trevor Woerner
The SPL linker script had been left in arch/$(ARCH)/cpu/$(CPU)/$(SOC);
therefore move it to the already-established arch/$(ARCH)/mach-$(SOC)
location.

Signed-off-by: Trevor Woerner 

---

Changes in v2:
Update patch to work on latest master; the location where the SPL linker
script is specified has changed.

 arch/arm/{cpu/arm926ejs/orion5x => mach-orion5x}/u-boot-spl.lds | 0
 configs/edminiv2_defconfig  | 2 +-
 2 files changed, 1 insertion(+), 1 deletion(-)
 rename arch/arm/{cpu/arm926ejs/orion5x => mach-orion5x}/u-boot-spl.lds (100%)

diff --git a/arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds 
b/arch/arm/mach-orion5x/u-boot-spl.lds
similarity index 100%
rename from arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds
rename to arch/arm/mach-orion5x/u-boot-spl.lds
diff --git a/configs/edminiv2_defconfig b/configs/edminiv2_defconfig
index d06f83db04..9a9d9c58d7 100644
--- a/configs/edminiv2_defconfig
+++ b/configs/edminiv2_defconfig
@@ -1,7 +1,7 @@
 CONFIG_ARM=y
 CONFIG_ARCH_CPU_INIT=y
 CONFIG_ARCH_ORION5X=y
-CONFIG_SPL_LDSCRIPT="arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds"
+CONFIG_SPL_LDSCRIPT="arch/arm/mach-orion5x/u-boot-spl.lds"
 CONFIG_SYS_TEXT_BASE=0x0080
 CONFIG_SPL_LIBCOMMON_SUPPORT=y
 CONFIG_SPL_LIBGENERIC_SUPPORT=y
-- 
2.26.0.106.g9fadedd637



[PATCH v2 7/8] rename symbol: CONFIG_STM32 -> CONFIG_ARCH_STM32

2020-04-17 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.

Signed-off-by: Trevor Woerner 
---

Changes in v2: added

 arch/arm/Kconfig   | 2 +-
 arch/arm/Makefile  | 2 +-
 arch/arm/mach-stm32/Kconfig| 2 +-
 configs/stm32f429-discovery_defconfig  | 2 +-
 configs/stm32f429-evaluation_defconfig | 2 +-
 configs/stm32f469-discovery_defconfig  | 2 +-
 configs/stm32f746-disco_defconfig  | 2 +-
 configs/stm32f769-disco_defconfig  | 2 +-
 configs/stm32h743-disco_defconfig  | 2 +-
 configs/stm32h743-eval_defconfig   | 2 +-
 drivers/gpio/Kconfig   | 2 +-
 drivers/misc/Kconfig   | 2 +-
 drivers/reset/Kconfig  | 2 +-
 13 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 4b0cab553a..dee31952ca 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1563,7 +1563,7 @@ config ARCH_UNIPHIER
  Support for UniPhier SoC family developed by Socionext Inc.
  (formerly, System LSI Business Division of Panasonic Corporation)
 
-config STM32
+config ARCH_STM32
bool "Support STMicroelectronics STM32 MCU with cortex M"
select CPU_V7M
select DM
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index e91b37fb34..94eb50bf72 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -73,7 +73,7 @@ machine-$(CONFIG_ARCH_ROCKCHIP)   += rockchip
 machine-$(CONFIG_ARCH_S5PC1XX) += s5pc1xx
 machine-$(CONFIG_ARCH_SNAPDRAGON)  += snapdragon
 machine-$(CONFIG_ARCH_SOCFPGA) += socfpga
-machine-$(CONFIG_STM32)+= stm32
+machine-$(CONFIG_ARCH_STM32)   += stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
 machine-$(CONFIG_ARCH_SUNXI)   += sunxi
 machine-$(CONFIG_ARCH_TEGRA)   += tegra
diff --git a/arch/arm/mach-stm32/Kconfig b/arch/arm/mach-stm32/Kconfig
index cea5ee2ce5..b42b05669a 100644
--- a/arch/arm/mach-stm32/Kconfig
+++ b/arch/arm/mach-stm32/Kconfig
@@ -1,4 +1,4 @@
-if STM32
+if ARCH_STM32
 
 config STM32F4
bool "stm32f4 family"
diff --git a/configs/stm32f429-discovery_defconfig 
b/configs/stm32f429-discovery_defconfig
index 52a577f97b..da43317ae5 100644
--- a/configs/stm32f429-discovery_defconfig
+++ b/configs/stm32f429-discovery_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f429-evaluation_defconfig 
b/configs/stm32f429-evaluation_defconfig
index 24f79b51bf..f67ce3e407 100644
--- a/configs/stm32f429-evaluation_defconfig
+++ b/configs/stm32f429-evaluation_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f469-discovery_defconfig 
b/configs/stm32f469-discovery_defconfig
index 0ab00514d5..082fb0cc19 100644
--- a/configs/stm32f469-discovery_defconfig
+++ b/configs/stm32f469-discovery_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f746-disco_defconfig 
b/configs/stm32f746-disco_defconfig
index c9e22563a3..574bc61db0 100644
--- a/configs/stm32f746-disco_defconfig
+++ b/configs/stm32f746-disco_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x08008000
 CONFIG_SYS_MALLOC_F_LEN=0xE00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32f769-disco_defconfig 
b/configs/stm32f769-disco_defconfig
index 19a7493d00..3f53c11c24 100644
--- a/configs/stm32f769-disco_defconfig
+++ b/configs/stm32f769-disco_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x08008000
 CONFIG_SYS_MALLOC_F_LEN=0xE00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32h743-disco_defconfig 
b/configs/stm32h743-disco_defconfig
index 6b7a1d6d68..21ea90a2c1 100644
--- a/configs/stm32h743-disco_defconfig
+++ b/configs/stm32h743-disco_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/configs/stm32h743-eval_defconfig b/configs/stm32h743-eval_defconfig
index 7564d97707..432fce0181 100644
--- a/configs/stm32h743-eval_defconfig
+++ b/configs/stm32h743-eval_defconfig
@@ -1,5 +1,5 @@
 CONFIG_ARM=y
-CONFIG_STM32=y
+CONFIG_ARCH_STM32=y
 CONFIG_SYS_TEXT_BASE=0x0800
 CONFIG_SYS_MALLOC_F_LEN=0xF00
 CONFIG_ENV_SIZE=0x2000
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index 2081520f42..d87f6cc105 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -318,7 +318,7 @@ config PIC32_GPIO
 
 config STM32_GPIO
bool "ST STM32 GPIO driver"
-   depends on DM_GPIO && (STM32 || AR

[PATCH v2 0/8] A small set of arm cleanups

2020-04-17 Thread Trevor Woerner
This patch series presents a set of cleanups I stumbled across while looking
at some arm-related code.

A long time ago there was an effort to follow the Linux kernel's convention of
putting SoC-specific code in arch/$(ARCH)/mach-$(SOC) instead of the previous
location of arch/$(ARCH)/cpu/$(CPU)/$(SOC). For some reason this didn't occur
with code for NXP's LPC32xx SoC. Therefore the first patch performs this move.

While moving the code, I noticed that years of editing had caused a list in
arch/arm/Makefile to not be sorted alphanumerically anymore, despite the
comment's request to do so. Therefore the second patch re-orders the list to
put it back in alphanumerical order.

While sorting the above-mentioned list, I noticed that there were 4
symbol names that were not following the convention of other symbols:
CONFIG_KIRKWOOD, CONFIG_ORION5X, CONFIG_TEGRA, and CONFIG_STM32. These
symbols should have the pattern: CONFIG_ARCH_. Therefore more
patches were created to fix these symbol names.

While renaming the CONFIG_ARCH_ORION5X symbol I noticed that this SoC had
code both in arch/$(ARCH)/cpu/$(CPU)/$(SOC) and arch/$(ARCH)/mach-$(SOC),
so there's a patch to complete this move.

Also, I found a typo, so another patch.


Changes in v2:
- Update the commit message to fix the error identified by checkpatch.pl, namely
  to fix the formatting used to reference a prior commit.
- Improve the wording of the commit message, mostly to specify that the sorting
  was done assuming all symbols had "ARCH_" in the middle.
- Update patch to work on latest master; the location where the SPL linker
  script is specified has changed.
- Add Chris Packham's r-b
- Added a cover letter.
- In the original series I only renamed 2 of the 4 symbols that were missing
  the "ARCH_" string (CONFIG_ORION5X and CONFIG_KIRKWOOD), since those were
  the only 2 with TODOs attached to them. As part of v2 I also converted
  CONFIG_TEGRA and CONFIG_STM32


Trevor Woerner (8):
  arm: lpc32xx: move SoC to mach-lpc32xx
  arch/arm/Makefile: sort machine names
  rename symbol: CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
  arm: orion5x: finish moving SoC to mach-orion5x
  rename symbol: CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
  rename symbol: CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
  rename symbol: CONFIG_STM32 -> CONFIG_ARCH_STM32
  drivers/reset/Kconfig: fix typo

 Kconfig   |  2 +-
 Makefile  |  4 ++--
 arch/arm/Kconfig  | 10 
 arch/arm/Makefile | 24 +--
 arch/arm/cpu/arm720t/interrupts.c |  2 +-
 arch/arm/cpu/arm926ejs/Makefile   |  1 -
 arch/arm/cpu/armv7/Kconfig|  2 +-
 arch/arm/dts/Makefile |  4 ++--
 arch/arm/mach-kirkwood/Kconfig|  2 +-
 .../lpc32xx => mach-lpc32xx}/Kconfig  |  0
 .../lpc32xx => mach-lpc32xx}/Makefile |  0
 .../arm926ejs/lpc32xx => mach-lpc32xx}/clk.c  |  0
 .../arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c  |  0
 .../lpc32xx => mach-lpc32xx}/devices.c|  0
 .../arm926ejs/lpc32xx => mach-lpc32xx}/dram.c |  0
 .../lpc32xx => mach-lpc32xx}/lowlevel_init.S  |  0
 .../lpc32xx => mach-lpc32xx}/timer.c  |  0
 arch/arm/mach-mvebu/Makefile  |  6 ++---
 arch/arm/mach-mvebu/mbus.c|  6 ++---
 arch/arm/mach-orion5x/Kconfig |  2 +-
 .../orion5x => mach-orion5x}/u-boot-spl.lds   |  0
 arch/arm/mach-stm32/Kconfig   |  2 +-
 arch/arm/mach-tegra/Kconfig   |  2 +-
 board/keymile/Kconfig | 12 +-
 common/spl/Kconfig|  4 ++--
 config.mk |  2 +-
 configs/SBx81LIFKW_defconfig  |  2 +-
 configs/SBx81LIFXCAT_defconfig|  2 +-
 configs/apalis-tk1_defconfig  |  2 +-
 configs/apalis_t30_defconfig  |  2 +-
 configs/beaver_defconfig  |  2 +-
 configs/cardhu_defconfig  |  2 +-
 configs/cei-tk1-som_defconfig |  2 +-
 configs/colibri_t20_defconfig |  2 +-
 configs/colibri_t30_defconfig |  2 +-
 configs/d2net_v2_defconfig|  2 +-
 configs/dalmore_defconfig |  2 +-
 configs/db-88f6281-bp-nand_defconfig  |  2 +-
 configs/db-88f6281-bp-spi_defconfig   |  2 +-
 configs/dns325_defconfig  |  2 +-
 configs/dockstar_defconfig|  2 +-
 configs/dreamplug_defconfig   |  2 +-
 configs/ds109_defconfig   |  2 +-
 configs/e2220-1170_defconfig  |  2 +-
 configs/edminiv2_defconfig|  4 ++--
 configs/goflexhome_defconfig  

[PATCH v2 1/8] arm: lpc32xx: move SoC to mach-lpc32xx

2020-04-17 Thread Trevor Woerner
Following the example of most other SoCs in arch/$(ARCH)/cpu/$(CPU)/$(SOC)
move the lpc32xx code from arch/arm/cpu/arm926ejs/lpc32xx to
arch/arm/mach-lpc32xx.

Following the checklist from
commit 01f14456306c ("ARM: prepare for moving SoC sources into mach-*"):

[1] move files from arch/arm/cpu/arm926ejs/lpc32xx to arch/arm/mach-lpx32xx
[2] add machine entry to arch/arm/Makefile
[3] remove "obj-y += ..." from arch/arm/cpu/arm926ejs/Makefile
[4] fix the Kconfig file path in arch/arm/Kconfig
[5] (no MAINTAINERS update)

Signed-off-by: Trevor Woerner 

---

Changes in v2:
Update the commit message to fix the error identified by checkpatch.pl, namely
to fix the formatting used to reference a prior commit.

 arch/arm/Kconfig| 2 +-
 arch/arm/Makefile   | 1 +
 arch/arm/cpu/arm926ejs/Makefile | 1 -
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig| 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile   | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c | 0
 .../arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c| 0
 11 files changed, 2 insertions(+), 2 deletions(-)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c (100%)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index dd41090fc6..8567c15c26 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1733,7 +1733,7 @@ source "arch/arm/mach-keystone/Kconfig"
 
 source "arch/arm/mach-kirkwood/Kconfig"
 
-source "arch/arm/cpu/arm926ejs/lpc32xx/Kconfig"
+source "arch/arm/mach-lpc32xx/Kconfig"
 
 source "arch/arm/mach-mvebu/Kconfig"
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index e25bb0e594..33bb8923bf 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -62,6 +62,7 @@ machine-$(CONFIG_ARCH_K3) += k3
 machine-$(CONFIG_ARCH_KEYSTONE)+= keystone
 # TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
 machine-$(CONFIG_KIRKWOOD) += kirkwood
+machine-$(CONFIG_ARCH_LPC32XX) += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
diff --git a/arch/arm/cpu/arm926ejs/Makefile b/arch/arm/cpu/arm926ejs/Makefile
index b051025bb0..af63d5cc5e 100644
--- a/arch/arm/cpu/arm926ejs/Makefile
+++ b/arch/arm/cpu/arm926ejs/Makefile
@@ -13,7 +13,6 @@ endif
 endif
 
 obj-$(CONFIG_ARMADA100) += armada100/
-obj-$(if $(filter lpc32xx,$(SOC)),y) += lpc32xx/
 obj-$(CONFIG_MX25) += mx25/
 obj-$(CONFIG_MX27) += mx27/
 obj-$(if $(filter mxs,$(SOC)),y) += mxs/
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Kconfig 
b/arch/arm/mach-lpc32xx/Kconfig
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Kconfig
rename to arch/arm/mach-lpc32xx/Kconfig
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Makefile 
b/arch/arm/mach-lpc32xx/Makefile
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Makefile
rename to arch/arm/mach-lpc32xx/Makefile
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/clk.c b/arch/arm/mach-lpc32xx/clk.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/clk.c
rename to arch/arm/mach-lpc32xx/clk.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/cpu.c b/arch/arm/mach-lpc32xx/cpu.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/cpu.c
rename to arch/arm/mach-lpc32xx/cpu.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/devices.c 
b/arch/arm/mach-lpc32xx/devices.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/devices.c
rename to arch/arm/mach-lpc32xx/devices.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/dram.c 
b/arch/arm/mach-lpc32xx/dram.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/dram.c
rename to arch/arm/mach-lpc32xx/dram.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/lowlevel_init.S 
b/arch/arm/mach-lpc32xx/lowlevel_init.S
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/lowlevel_init.S
rename to arch/arm/mach-lpc3

[PATCH][RESEND] arm: lpc32xx: move SoC to mach-lpc32xx

2020-04-13 Thread Trevor Woerner
Following the example of most other SoCs in arch/$(ARCH)/cpu/$(CPU)/$(SOC)
move the lpc32xx code from arch/arm/cpu/arm926ejs/lpc32xx to
arch/arm/mach-lpc32xx.

Following the checklist from
commit 01f14456306c ("ARM: prepare for moving SoC sources into mach-*"):

[1] move files from arch/arm/cpu/arm926ejs/lpc32xx to arch/arm/mach-lpx32xx
[2] add machine entry to arch/arm/Makefile
[3] remove "obj-y += ..." from arch/arm/cpu/arm926ejs/Makefile
[4] fix the Kconfig file path in arch/arm/Kconfig
[5] (no MAINTAINERS update)

Signed-off-by: Trevor Woerner 
---
 arch/arm/Kconfig| 2 +-
 arch/arm/Makefile   | 1 +
 arch/arm/cpu/arm926ejs/Makefile | 1 -
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig| 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile   | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c | 0
 .../arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c| 0
 11 files changed, 2 insertions(+), 2 deletions(-)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c (100%)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index bbb1e2738b..3096b97c6f 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1732,7 +1732,7 @@ source "arch/arm/mach-keystone/Kconfig"
 
 source "arch/arm/mach-kirkwood/Kconfig"
 
-source "arch/arm/cpu/arm926ejs/lpc32xx/Kconfig"
+source "arch/arm/mach-lpc32xx/Kconfig"
 
 source "arch/arm/mach-mvebu/Kconfig"
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index e25bb0e594..33bb8923bf 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -62,6 +62,7 @@ machine-$(CONFIG_ARCH_K3) += k3
 machine-$(CONFIG_ARCH_KEYSTONE)+= keystone
 # TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
 machine-$(CONFIG_KIRKWOOD) += kirkwood
+machine-$(CONFIG_ARCH_LPC32XX) += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
diff --git a/arch/arm/cpu/arm926ejs/Makefile b/arch/arm/cpu/arm926ejs/Makefile
index b051025bb0..af63d5cc5e 100644
--- a/arch/arm/cpu/arm926ejs/Makefile
+++ b/arch/arm/cpu/arm926ejs/Makefile
@@ -13,7 +13,6 @@ endif
 endif
 
 obj-$(CONFIG_ARMADA100) += armada100/
-obj-$(if $(filter lpc32xx,$(SOC)),y) += lpc32xx/
 obj-$(CONFIG_MX25) += mx25/
 obj-$(CONFIG_MX27) += mx27/
 obj-$(if $(filter mxs,$(SOC)),y) += mxs/
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Kconfig 
b/arch/arm/mach-lpc32xx/Kconfig
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Kconfig
rename to arch/arm/mach-lpc32xx/Kconfig
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Makefile 
b/arch/arm/mach-lpc32xx/Makefile
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Makefile
rename to arch/arm/mach-lpc32xx/Makefile
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/clk.c b/arch/arm/mach-lpc32xx/clk.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/clk.c
rename to arch/arm/mach-lpc32xx/clk.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/cpu.c b/arch/arm/mach-lpc32xx/cpu.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/cpu.c
rename to arch/arm/mach-lpc32xx/cpu.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/devices.c 
b/arch/arm/mach-lpc32xx/devices.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/devices.c
rename to arch/arm/mach-lpc32xx/devices.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/dram.c 
b/arch/arm/mach-lpc32xx/dram.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/dram.c
rename to arch/arm/mach-lpc32xx/dram.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/lowlevel_init.S 
b/arch/arm/mach-lpc32xx/lowlevel_init.S
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/lowlevel_init.S
rename to arch/arm/mach-lpc32xx/lowlevel_init.S
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/timer.c 
b/arch/arm/mach-lpc32xx/timer.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/timer.c
rename to arch/arm/mach-lpc32xx/timer.c
-- 
2.26.0.106.g9fadedd637



Re: [PATCH 5/5] rename symbol: CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD

2020-04-06 Thread Trevor Woerner
Hi Chris,

Thank you for your "reviewed-by" :-)

On Mon 2020-04-06 @ 07:54:53 PM, Chris Packham wrote:
> On Mon, 6 Apr 2020, 6:01 PM Trevor Woerner,  wrote:
> 
> > Have this symbol follow the pattern of all other such symbols.
> > This patch also removes a TODO from the code.
> >
> > Signed-off-by: Trevor Woerner 
> >
> 
> Not sure if there was a cover letter accompanying this series that I missed
> but I can't really speak with any authority on the first two patches anyway.

Sorry, I couldn't decide whether or not to include a cover letter since the
changes included in the set meander around doing various cleanups that are
only loosely related. The strongest thing they have in common is that their
order relies on each other. In the end I didn't include one.

I'll include a cover letter next time; I like reading them on other sets of
patches.

Best regards,
Trevor


[PATCH 5/5] rename symbol: CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD

2020-04-05 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.
This patch also removes a TODO from the code.

Signed-off-by: Trevor Woerner 
---
 Kconfig  |  2 +-
 arch/arm/Kconfig |  2 +-
 arch/arm/Makefile|  3 +--
 arch/arm/dts/Makefile|  2 +-
 arch/arm/mach-kirkwood/Kconfig   |  2 +-
 arch/arm/mach-mvebu/Makefile |  6 +++---
 arch/arm/mach-mvebu/mbus.c   |  6 +++---
 board/keymile/Kconfig| 12 ++--
 configs/SBx81LIFKW_defconfig |  2 +-
 configs/SBx81LIFXCAT_defconfig   |  2 +-
 configs/d2net_v2_defconfig   |  2 +-
 configs/db-88f6281-bp-nand_defconfig |  2 +-
 configs/db-88f6281-bp-spi_defconfig  |  2 +-
 configs/dns325_defconfig |  2 +-
 configs/dockstar_defconfig   |  2 +-
 configs/dreamplug_defconfig  |  2 +-
 configs/ds109_defconfig  |  2 +-
 configs/goflexhome_defconfig |  2 +-
 configs/guruplug_defconfig   |  2 +-
 configs/ib62x0_defconfig |  2 +-
 configs/iconnect_defconfig   |  2 +-
 configs/inetspace_v2_defconfig   |  2 +-
 configs/km_kirkwood_128m16_defconfig |  2 +-
 configs/km_kirkwood_defconfig|  2 +-
 configs/km_kirkwood_pci_defconfig|  2 +-
 configs/kmcoge5un_defconfig  |  2 +-
 configs/kmnusa_defconfig |  2 +-
 configs/kmsuse2_defconfig|  2 +-
 configs/lschlv2_defconfig|  2 +-
 configs/lsxhl_defconfig  |  2 +-
 configs/nas220_defconfig |  2 +-
 configs/net2big_v2_defconfig |  2 +-
 configs/netspace_lite_v2_defconfig   |  2 +-
 configs/netspace_max_v2_defconfig|  2 +-
 configs/netspace_mini_v2_defconfig   |  2 +-
 configs/netspace_v2_defconfig|  2 +-
 configs/nsa310s_defconfig|  2 +-
 configs/openrd_base_defconfig|  2 +-
 configs/openrd_client_defconfig  |  2 +-
 configs/openrd_ultimate_defconfig|  2 +-
 configs/pogo_e02_defconfig   |  2 +-
 configs/sheevaplug_defconfig |  2 +-
 drivers/ata/mvsata_ide.c |  2 +-
 drivers/ata/sata_mv.c|  2 +-
 drivers/i2c/mvtwsi.c |  4 ++--
 drivers/net/Kconfig  |  2 +-
 drivers/net/mvgbe.c  |  2 +-
 drivers/spi/kirkwood_spi.c   | 10 +-
 drivers/usb/host/Kconfig |  2 +-
 drivers/usb/host/ehci-marvell.c  |  2 +-
 tools/Makefile   |  4 ++--
 51 files changed, 66 insertions(+), 67 deletions(-)

diff --git a/Kconfig b/Kconfig
index f698e0a94f..4a61b3d2fe 100644
--- a/Kconfig
+++ b/Kconfig
@@ -258,7 +258,7 @@ config BUILD_TARGET
default "u-boot-elf.srec" if RCAR_GEN3
default "u-boot.itb" if SPL_LOAD_FIT && (ARCH_ROCKCHIP || \
ARCH_SUNXI || RISCV || ARCH_ZYNQMP)
-   default "u-boot.kwb" if KIRKWOOD
+   default "u-boot.kwb" if ARCH_KIRKWOOD
default "u-boot-with-spl.bin" if ARCH_AT91 && SPL_NAND_SUPPORT
default "u-boot-with-spl.imx" if ARCH_MX6 && SPL
help
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index d56f375c8b..c7717c2f12 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -524,7 +524,7 @@ config ARCH_DAVINCI
help
  Support for TI's DaVinci platform.
 
-config KIRKWOOD
+config ARCH_KIRKWOOD
bool "Marvell Kirkwood"
select ARCH_MISC_INIT
select BOARD_EARLY_INIT_F
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 2b44ffb493..9b3ca9772c 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -60,8 +60,7 @@ machine-$(CONFIG_ARCH_EXYNOS) += exynos
 machine-$(CONFIG_ARCH_HIGHBANK)+= highbank
 machine-$(CONFIG_ARCH_K3)  += k3
 machine-$(CONFIG_ARCH_KEYSTONE)+= keystone
-# TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
-machine-$(CONFIG_KIRKWOOD) += kirkwood
+machine-$(CONFIG_ARCH_KIRKWOOD)+= kirkwood
 machine-$(CONFIG_ARCH_LPC32XX) += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 820ee9733a..9376770d09 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -34,7 +34,7 @@ dtb-$(CONFIG_ARCH_DAVINCI) += \
da850-lcdk.dtb \
da850-lego-ev3.dtb
 
-dtb-$(CONFIG_KIRKWOOD) += \
+dtb-$(CONFIG_ARCH_KIRKWOOD) += \
kirkwood-atl-sbx81lifkw.dtb \
kirkwood-atl-sbx81lifxcat.dtb \
kirkwood-blackarmor-nas220.dtb \
diff --git a/arch/arm/mach-kirkwood/Kconfig b/arch/arm/mach-kirkwood/Kconfig
index 2f68092f82..ae44cb665e 100644
--- a/arch/arm/mach-kirkwood/Kconfig
+++ b/arch/arm/mach-kirkwood/Kconfig
@@ -1,4 +1,4 @@
-if KIRKWOOD
+if ARCH_KIRKWOOD
 
 choice
prompt "Ma

[PATCH 4/5] arm: orion5x: finish moving SoC to mach-orion5x

2020-04-05 Thread Trevor Woerner
The SPL linker script had been left in arch/$(ARCH)/cpu/$(CPU)/$(SOC) so move
it to the already-established arch/$(ARCH)/mach-$(SOC) location.

Signed-off-by: Trevor Woerner 
---
 arch/arm/mach-orion5x/Kconfig   | 2 +-
 arch/arm/{cpu/arm926ejs/orion5x => mach-orion5x}/u-boot-spl.lds | 0
 2 files changed, 1 insertion(+), 1 deletion(-)
 rename arch/arm/{cpu/arm926ejs/orion5x => mach-orion5x}/u-boot-spl.lds (100%)

diff --git a/arch/arm/mach-orion5x/Kconfig b/arch/arm/mach-orion5x/Kconfig
index 23c13e22f5..5980e095ce 100644
--- a/arch/arm/mach-orion5x/Kconfig
+++ b/arch/arm/mach-orion5x/Kconfig
@@ -16,6 +16,6 @@ config SYS_SOC
 source "board/LaCie/edminiv2/Kconfig"
 
 config SPL_LDSCRIPT
-   default "$(CPUDIR)/orion5x/u-boot-spl.lds" if ARCH_ORION5X
+   default "arch/arm/mach-orion5x/u-boot-spl.lds"
 
 endif
diff --git a/arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds 
b/arch/arm/mach-orion5x/u-boot-spl.lds
similarity index 100%
rename from arch/arm/cpu/arm926ejs/orion5x/u-boot-spl.lds
rename to arch/arm/mach-orion5x/u-boot-spl.lds
-- 
2.25.0.114.g5b0ca878e0



[PATCH 3/5] rename symbol: CONFIG_ORION5X -> CONFIG_ARCH_ORION5X

2020-04-05 Thread Trevor Woerner
Have this symbol follow the pattern of all other such symbols.
This patch also removes a TODO from the code.

Signed-off-by: Trevor Woerner 
---
 arch/arm/Kconfig| 2 +-
 arch/arm/Makefile   | 3 +--
 arch/arm/mach-orion5x/Kconfig   | 4 ++--
 configs/edminiv2_defconfig  | 2 +-
 drivers/ata/mvsata_ide.c| 2 +-
 drivers/i2c/mvtwsi.c| 2 +-
 drivers/net/Kconfig | 2 +-
 drivers/net/mvgbe.c | 2 +-
 drivers/usb/host/Kconfig| 2 +-
 drivers/usb/host/ehci-marvell.c | 2 +-
 10 files changed, 11 insertions(+), 12 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 3096b97c6f..d56f375c8b 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -547,7 +547,7 @@ config TARGET_APF27
select CPU_ARM926EJS
select SUPPORT_SPL
 
-config ORION5X
+config ARCH_ORION5X
bool "Marvell Orion"
select CPU_ARM926EJS
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 5d32dec29c..2b44ffb493 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -67,8 +67,7 @@ machine-$(CONFIG_ARCH_MEDIATEK)   += mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
 machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
-# TODO: rename CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
-machine-$(CONFIG_ORION5X)  += orion5x
+machine-$(CONFIG_ARCH_ORION5X) += orion5x
 machine-$(CONFIG_ARCH_OWL) += owl
 machine-$(CONFIG_ARCH_RMOBILE) += rmobile
 machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
diff --git a/arch/arm/mach-orion5x/Kconfig b/arch/arm/mach-orion5x/Kconfig
index 2984a3edda..23c13e22f5 100644
--- a/arch/arm/mach-orion5x/Kconfig
+++ b/arch/arm/mach-orion5x/Kconfig
@@ -1,4 +1,4 @@
-if ORION5X
+if ARCH_ORION5X
 
 choice
prompt "Marvell Orion board select"
@@ -16,6 +16,6 @@ config SYS_SOC
 source "board/LaCie/edminiv2/Kconfig"
 
 config SPL_LDSCRIPT
-   default "$(CPUDIR)/orion5x/u-boot-spl.lds" if ORION5X
+   default "$(CPUDIR)/orion5x/u-boot-spl.lds" if ARCH_ORION5X
 
 endif
diff --git a/configs/edminiv2_defconfig b/configs/edminiv2_defconfig
index 2bbd6a783b..552b2d5b44 100644
--- a/configs/edminiv2_defconfig
+++ b/configs/edminiv2_defconfig
@@ -1,6 +1,6 @@
 CONFIG_ARM=y
 CONFIG_ARCH_CPU_INIT=y
-CONFIG_ORION5X=y
+CONFIG_ARCH_ORION5X=y
 CONFIG_SYS_TEXT_BASE=0x0080
 CONFIG_SPL_LIBCOMMON_SUPPORT=y
 CONFIG_SPL_LIBGENERIC_SUPPORT=y
diff --git a/drivers/ata/mvsata_ide.c b/drivers/ata/mvsata_ide.c
index 38181235af..9ac16555d6 100644
--- a/drivers/ata/mvsata_ide.c
+++ b/drivers/ata/mvsata_ide.c
@@ -8,7 +8,7 @@
 #include 
 #include 
 
-#if defined(CONFIG_ORION5X)
+#if defined(CONFIG_ARCH_ORION5X)
 #include 
 #elif defined(CONFIG_KIRKWOOD)
 #include 
diff --git a/drivers/i2c/mvtwsi.c b/drivers/i2c/mvtwsi.c
index 382cf4b304..77fe35a42b 100644
--- a/drivers/i2c/mvtwsi.c
+++ b/drivers/i2c/mvtwsi.c
@@ -25,7 +25,7 @@ DECLARE_GLOBAL_DATA_PTR;
  */
 
 #ifndef CONFIG_DM_I2C
-#if defined(CONFIG_ORION5X)
+#if defined(CONFIG_ARCH_ORION5X)
 #include 
 #elif (defined(CONFIG_KIRKWOOD) || defined(CONFIG_ARCH_MVEBU))
 #include 
diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig
index 4d1013c984..3fd3e72219 100644
--- a/drivers/net/Kconfig
+++ b/drivers/net/Kconfig
@@ -303,7 +303,7 @@ config FSLDMAFEC
 
 config MVGBE
bool "Marvell Orion5x/Kirkwood network interface support"
-   depends on KIRKWOOD || ORION5X
+   depends on KIRKWOOD || ARCH_ORION5X
select PHYLIB if DM_ETH
help
  This driver supports the network interface units in the
diff --git a/drivers/net/mvgbe.c b/drivers/net/mvgbe.c
index 037e59ec6e..b0b8d349a8 100644
--- a/drivers/net/mvgbe.c
+++ b/drivers/net/mvgbe.c
@@ -26,7 +26,7 @@
 
 #if defined(CONFIG_KIRKWOOD)
 #include 
-#elif defined(CONFIG_ORION5X)
+#elif defined(CONFIG_ARCH_ORION5X)
 #include 
 #endif
 
diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
index 0987ff25b1..5574e9f989 100644
--- a/drivers/usb/host/Kconfig
+++ b/drivers/usb/host/Kconfig
@@ -121,7 +121,7 @@ config USB_EHCI_ATMEL
 
 config USB_EHCI_MARVELL
bool "Support for Marvell on-chip EHCI USB controller"
-   depends on ARCH_MVEBU || KIRKWOOD || ORION5X
+   depends on ARCH_MVEBU || KIRKWOOD || ARCH_ORION5X
default y
---help---
  Enables support for the on-chip EHCI controller on MVEBU SoCs.
diff --git a/drivers/usb/host/ehci-marvell.c b/drivers/usb/host/ehci-marvell.c
index 8efe6b63b9..3b10cdfc58 100644
--- a/drivers/usb/host/ehci-marvell.c
+++ b/drivers/usb/host/ehci-marvell.c
@@ -15,7 +15,7 @@
 
 #if defined(CONFIG_KIRKWOOD)
 #include 
-#elif defined(CONFIG_ORION5X)
+#elif defined(CONFIG_ARCH_ORION5X)
 #include 
 #endif
 
-- 
2.25.0.114.g5b0ca878e0



[PATCH 2/5] arch/arm/Makefile: sort machine names

2020-04-05 Thread Trevor Woerner
The comment hoped that people would keep the CONFIG_* macro names sorted, but
this drifted over time. Put the list back in alphanumerical order.

Signed-off-by: Trevor Woerner 
---
 arch/arm/Makefile | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 33bb8923bf..5d32dec29c 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -66,25 +66,25 @@ machine-$(CONFIG_ARCH_LPC32XX)  += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
-# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
+machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
 # TODO: rename CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
 machine-$(CONFIG_ORION5X)  += orion5x
-machine-$(CONFIG_ARCH_OMAP2PLUS)   += omap2
 machine-$(CONFIG_ARCH_OWL) += owl
+machine-$(CONFIG_ARCH_RMOBILE) += rmobile
+machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
 machine-$(CONFIG_ARCH_S5PC1XX) += s5pc1xx
-machine-$(CONFIG_ARCH_SUNXI)   += sunxi
 machine-$(CONFIG_ARCH_SNAPDRAGON)  += snapdragon
 machine-$(CONFIG_ARCH_SOCFPGA) += socfpga
-machine-$(CONFIG_ARCH_RMOBILE) += rmobile
-machine-$(CONFIG_ARCH_ROCKCHIP)+= rockchip
 machine-$(CONFIG_STM32)+= stm32
 machine-$(CONFIG_ARCH_STM32MP) += stm32mp
+machine-$(CONFIG_ARCH_SUNXI)   += sunxi
+# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
 machine-$(CONFIG_TEGRA)+= tegra
 machine-$(CONFIG_ARCH_U8500)   += u8500
 machine-$(CONFIG_ARCH_UNIPHIER)+= uniphier
+machine-$(CONFIG_ARCH_VERSAL)  += versal
 machine-$(CONFIG_ARCH_ZYNQ)+= zynq
 machine-$(CONFIG_ARCH_ZYNQMP)  += zynqmp
-machine-$(CONFIG_ARCH_VERSAL)  += versal
 machine-$(CONFIG_ARCH_ZYNQMP_R5)   += zynqmp-r5
 
 machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y))
-- 
2.25.0.114.g5b0ca878e0



[PATCH 1/5] arm: lpc32xx: move SoC to mach-lpc32xx

2020-04-05 Thread Trevor Woerner
Following the example of most other SoCs in arch/$(ARCH)/cpu/$(CPU)/$(SOC)
move the lpc32xx code from arch/arm/cpu/arm926ejs/lpc32xx to
arch/arm/mach-lpc32xx.

Following the checklist from commit 01f14456306c84f9bcd3945a10c98ae50e30542a:
[1] move files from arch/arm/cpu/arm926ejs/lpc32xx to arch/arm/mach-lpx32xx
[2] add machine entry to arch/arm/Makefile
[3] remove "obj-y += ..." from arch/arm/cpu/arm926ejs/Makefile
[4] fix the Kconfig file path in arch/arm/Kconfig
[5] (no MAINTAINERS update)

Signed-off-by: Trevor Woerner 
---
 arch/arm/Kconfig| 2 +-
 arch/arm/Makefile   | 1 +
 arch/arm/cpu/arm926ejs/Makefile | 1 -
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig| 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile   | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c  | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c | 0
 .../arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S | 0
 arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c| 0
 11 files changed, 2 insertions(+), 2 deletions(-)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Kconfig (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/Makefile (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/clk.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/cpu.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/devices.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/dram.c (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/lowlevel_init.S (100%)
 rename arch/arm/{cpu/arm926ejs/lpc32xx => mach-lpc32xx}/timer.c (100%)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index bbb1e2738b..3096b97c6f 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1732,7 +1732,7 @@ source "arch/arm/mach-keystone/Kconfig"
 
 source "arch/arm/mach-kirkwood/Kconfig"
 
-source "arch/arm/cpu/arm926ejs/lpc32xx/Kconfig"
+source "arch/arm/mach-lpc32xx/Kconfig"
 
 source "arch/arm/mach-mvebu/Kconfig"
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index e25bb0e594..33bb8923bf 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -62,6 +62,7 @@ machine-$(CONFIG_ARCH_K3) += k3
 machine-$(CONFIG_ARCH_KEYSTONE)+= keystone
 # TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
 machine-$(CONFIG_KIRKWOOD) += kirkwood
+machine-$(CONFIG_ARCH_LPC32XX) += lpc32xx
 machine-$(CONFIG_ARCH_MEDIATEK)+= mediatek
 machine-$(CONFIG_ARCH_MESON)   += meson
 machine-$(CONFIG_ARCH_MVEBU)   += mvebu
diff --git a/arch/arm/cpu/arm926ejs/Makefile b/arch/arm/cpu/arm926ejs/Makefile
index b051025bb0..af63d5cc5e 100644
--- a/arch/arm/cpu/arm926ejs/Makefile
+++ b/arch/arm/cpu/arm926ejs/Makefile
@@ -13,7 +13,6 @@ endif
 endif
 
 obj-$(CONFIG_ARMADA100) += armada100/
-obj-$(if $(filter lpc32xx,$(SOC)),y) += lpc32xx/
 obj-$(CONFIG_MX25) += mx25/
 obj-$(CONFIG_MX27) += mx27/
 obj-$(if $(filter mxs,$(SOC)),y) += mxs/
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Kconfig 
b/arch/arm/mach-lpc32xx/Kconfig
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Kconfig
rename to arch/arm/mach-lpc32xx/Kconfig
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/Makefile 
b/arch/arm/mach-lpc32xx/Makefile
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/Makefile
rename to arch/arm/mach-lpc32xx/Makefile
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/clk.c b/arch/arm/mach-lpc32xx/clk.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/clk.c
rename to arch/arm/mach-lpc32xx/clk.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/cpu.c b/arch/arm/mach-lpc32xx/cpu.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/cpu.c
rename to arch/arm/mach-lpc32xx/cpu.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/devices.c 
b/arch/arm/mach-lpc32xx/devices.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/devices.c
rename to arch/arm/mach-lpc32xx/devices.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/dram.c 
b/arch/arm/mach-lpc32xx/dram.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/dram.c
rename to arch/arm/mach-lpc32xx/dram.c
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/lowlevel_init.S 
b/arch/arm/mach-lpc32xx/lowlevel_init.S
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/lowlevel_init.S
rename to arch/arm/mach-lpc32xx/lowlevel_init.S
diff --git a/arch/arm/cpu/arm926ejs/lpc32xx/timer.c 
b/arch/arm/mach-lpc32xx/timer.c
similarity index 100%
rename from arch/arm/cpu/arm926ejs/lpc32xx/timer.c
rename to arch/arm/mach-lpc32xx/timer.c
-- 
2.25.0.114.g5b0ca878e0



buildman summary quesiton

2020-03-31 Thread Trevor Woerner
I start off with the following build:

$ buildman -o  arm926ejs

and it tells me that there are 137 boards to build. At the end I can see:

   23  1140 /137

Now I want a summary:

$ buildman -o  arm926ejs -s

but all it prints out are the 114 boards that had warnings.

Is there not a way to get "buildman -s" to also print the list of the 23
boards that succeeded?


Re: NanoPi-M4 boot issue

2020-02-18 Thread Trevor Woerner
cc'ing some maintainers...

On Sat 2020-02-15 @ 01:16:36 AM, Trevor Woerner wrote:
> Hi,
> 
> I'm trying to build an image for a NanoPi-M4 but it is not able to get out of
> TPL. The U-Boot build seems to be constructing the idbloader.img properly, but
> the board is failing to boot. Note that this is an original NanoPi-M4 (i.e.
> V1) and not the NanoPi-M4V2.
> 
> From the build log:
>   ...
>   cat tpl/u-boot-tpl-nodtb.bin tpl/u-boot-tpl.dtb > tpl/u-boot-tpl-dtb.bin
>   cp tpl/u-boot-tpl-dtb.bin tpl/u-boot-tpl.bin
>   ./tools/mkimage -n "rk3399" -T rksd -d tpl/u-boot-tpl.bin 
> tpl/u-boot-tpl-rockchip.bin
>   ...
>   cat spl/u-boot-spl-nodtb.bin spl/u-boot-spl.dtb > spl/u-boot-spl-dtb.bin
>   cp spl/u-boot-spl-dtb.bin spl/u-boot-spl.bin
>   cat tpl/u-boot-tpl-rockchip.bin spl/u-boot-spl.bin > idbloader.img
> 
> What I get on the console is:
> 
>   U-Boot TPL 2020.04-rc2 (Feb 15 2020 - 05:36:59)
>   sdram_init: LPDDR3 - 933MHz failed!
>   rk3399_dmc_init DRAM init failed -22
>   Missing DTB
> 
> It's strange that it says the DTB is missing clearly shows the DTB versions of
> TPL and SPL being used to create the idbloader.img.
> 
> In any case, is anyone building and booting U-Boot master for NanoPi-M4?
> 
> Best regards,
>   Trevor


NanoPi-M4 boot issue

2020-02-15 Thread Trevor Woerner
Hi,

I'm trying to build an image for a NanoPi-M4 but it is not able to get out of
TPL. The U-Boot build seems to be constructing the idbloader.img properly, but
the board is failing to boot. Note that this is an original NanoPi-M4 (i.e.
V1) and not the NanoPi-M4V2.

>From the build log:
...
cat tpl/u-boot-tpl-nodtb.bin tpl/u-boot-tpl.dtb > tpl/u-boot-tpl-dtb.bin
cp tpl/u-boot-tpl-dtb.bin tpl/u-boot-tpl.bin
./tools/mkimage -n "rk3399" -T rksd -d tpl/u-boot-tpl.bin 
tpl/u-boot-tpl-rockchip.bin
...
cat spl/u-boot-spl-nodtb.bin spl/u-boot-spl.dtb > spl/u-boot-spl-dtb.bin
cp spl/u-boot-spl-dtb.bin spl/u-boot-spl.bin
cat tpl/u-boot-tpl-rockchip.bin spl/u-boot-spl.bin > idbloader.img

What I get on the console is:

U-Boot TPL 2020.04-rc2 (Feb 15 2020 - 05:36:59)
sdram_init: LPDDR3 - 933MHz failed!
rk3399_dmc_init DRAM init failed -22
Missing DTB

It's strange that it says the DTB is missing clearly shows the DTB versions of
TPL and SPL being used to create the idbloader.img.

In any case, is anyone building and booting U-Boot master for NanoPi-M4?

Best regards,
Trevor


[U-Boot] [PATCH v3 2/5] CONFIG_SYS_[DI]CACHE_OFF: remove superfluous "1"

2019-05-03 Thread Trevor Woerner
This config is the only config that uses:
#define CONFIG_SYS_DCACHE_OFF 1
in its #define.

Remove the superfluous "1" so this cache #define is like all the others.

Signed-off-by: Trevor Woerner 
---

Changes in v3: None
Changes in v2: None

 include/configs/origen.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/configs/origen.h b/include/configs/origen.h
index 1075084ba3..1b2ed315a7 100644
--- a/include/configs/origen.h
+++ b/include/configs/origen.h
@@ -14,7 +14,7 @@
 #define CONFIG_EXYNOS4210  1   /* which is a EXYNOS4210 SoC */
 #define CONFIG_ORIGEN  1   /* working with ORIGEN*/
 
-#define CONFIG_SYS_DCACHE_OFF  1
+#define CONFIG_SYS_DCACHE_OFF
 
 /* ORIGEN has 4 bank of DRAM */
 #define CONFIG_SYS_SDRAM_BASE  0x4000
-- 
2.21.0.rc2

___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH v3 4/5] CONFIG_SYS_[DI]CACHE_OFF: convert to Kconfig

2019-05-03 Thread Trevor Woerner
CONFIG_SYS_[DI]CACHE_OFF had been partially converted to Kconfig
parameters; only for the ARC architecture. This patch turns these two
parameters into Kconfig items everywhere else they are found.

All of the include/configs/* and defconfig changes in this patch are
for arm machines only. The Kconfig changes for arc, nds32, riscv,
and xtensa have been included since these symbols are found in code
under arch/{arc,nds32,riscv,xtensa}, however, no currently-defined
include/configs/* or defconfigs for these architectures exist which
include these symbols.

These results have been confirmed with tools/moveconfig.py.

Acked-by: Alexey Brodkin 
Signed-off-by: Trevor Woerner 

---

Changes in v3:
- rebase on top of U-Boot master:
  b4ee6daad7 Merge tag 'u-boot-imx-20190426' of git://git.denx.de/u-boot-imx

Changes in v2:
- rebased on top of U-Boot master:
  3fbd2dce35 Merge branch '2019-04-22-master-imports'
- fixed up configs/xilinx_zynqmp_mini_qspi_defconfig

 README   |  2 --
 arch/arc/Kconfig |  8 ++--
 arch/arm/Kconfig | 12 
 arch/arm/mach-kirkwood/include/mach/config.h |  6 --
 arch/nds32/Kconfig   | 12 
 arch/riscv/Kconfig   | 12 
 arch/xtensa/Kconfig  | 12 
 configs/SBx81LIFKW_defconfig |  1 +
 configs/SBx81LIFXCAT_defconfig   |  1 +
 configs/armadillo-800eva_defconfig   |  1 +
 configs/bcm23550_w1d_defconfig   |  2 ++
 configs/colibri_pxa270_defconfig |  1 +
 configs/d2net_v2_defconfig   |  1 +
 configs/devkit3250_defconfig |  2 ++
 configs/dns325_defconfig |  1 +
 configs/dockstar_defconfig   |  1 +
 configs/dreamplug_defconfig  |  1 +
 configs/ds109_defconfig  |  1 +
 configs/evb-ast2500_defconfig|  1 +
 configs/flea3_defconfig  |  1 +
 configs/goflexhome_defconfig |  1 +
 configs/gplugd_defconfig |  1 +
 configs/guruplug_defconfig   |  1 +
 configs/highbank_defconfig   |  1 +
 configs/ib62x0_defconfig |  1 +
 configs/iconnect_defconfig   |  1 +
 configs/inetspace_v2_defconfig   |  1 +
 configs/k2e_evm_defconfig|  1 +
 configs/k2e_hs_evm_defconfig |  1 +
 configs/k2g_evm_defconfig|  1 +
 configs/k2g_hs_evm_defconfig |  1 +
 configs/k2hk_evm_defconfig   |  1 +
 configs/k2hk_hs_evm_defconfig|  1 +
 configs/k2l_evm_defconfig|  1 +
 configs/k2l_hs_evm_defconfig |  1 +
 configs/km_kirkwood_128m16_defconfig |  1 +
 configs/km_kirkwood_defconfig|  1 +
 configs/km_kirkwood_pci_defconfig|  1 +
 configs/kmcoge5un_defconfig  |  1 +
 configs/kmnusa_defconfig |  1 +
 configs/kmsugp1_defconfig|  1 +
 configs/kmsuv31_defconfig|  1 +
 configs/lschlv2_defconfig|  1 +
 configs/lsxhl_defconfig  |  1 +
 configs/mgcoge3un_defconfig  |  1 +
 configs/nas220_defconfig |  1 +
 configs/net2big_v2_defconfig |  1 +
 configs/netspace_lite_v2_defconfig   |  1 +
 configs/netspace_max_v2_defconfig|  1 +
 configs/netspace_mini_v2_defconfig   |  1 +
 configs/netspace_v2_defconfig|  1 +
 configs/nsa310s_defconfig|  1 +
 configs/openrd_base_defconfig|  1 +
 configs/openrd_client_defconfig  |  1 +
 configs/openrd_ultimate_defconfig|  1 +
 configs/origen_defconfig |  1 +
 configs/pogo_e02_defconfig   |  1 +
 configs/portl2_defconfig |  1 +
 configs/sheevaplug_defconfig |  1 +
 configs/stv0991_defconfig|  1 +
 configs/woodburn_defconfig   |  1 +
 configs/woodburn_sd_defconfig|  1 +
 configs/work_92105_defconfig |  2 ++
 configs/xilinx_versal_mini_defconfig |  1 +
 configs/xilinx_versal_mini_emmc0_defconfig   |  1 +
 configs/xilinx_versal_mini_emmc1_defconfig   |  1 +
 configs/xilinx_zynqmp_mini_defconfig |  1 +
 configs/xilinx_zynqmp_mini_emmc0_defconfig   |  1 +
 configs/xilinx_zynqmp_mini_emmc1_defconfig   |  1 +
 configs/xilinx_zynqmp_mini_nand_defconfig|  1 +
 configs/xilinx_zynqmp_mini_qspi_defconfig|  1 +
 configs/zynq_cse_nand_defconfig  |  2 ++
 configs/zynq_cse_nor_defconfig   |  2 ++
 configs/zynq_cse_qspi_defconfig  |  2 ++
 include/config

[U-Boot] [PATCH v3 3/5] CONFIG_SYS_[DI]CACHE_OFF: remove commented lines

2019-05-03 Thread Trevor Woerner
Eventually these configuration items will be converted to Kconfig,
therefore there's little point in leaving commented-out versions of
them in include/configs.

Signed-off-by: Trevor Woerner 
---

Changes in v3: None
Changes in v2: None

 include/configs/uniphier.h   | 4 
 include/configs/xilinx_versal_mini.h | 1 -
 2 files changed, 5 deletions(-)

diff --git a/include/configs/uniphier.h b/include/configs/uniphier.h
index 31a9c59ed5..60ea07540f 100644
--- a/include/configs/uniphier.h
+++ b/include/configs/uniphier.h
@@ -45,10 +45,6 @@
  * MMU and Cache Setting
  *--*/
 
-/* Comment out the following to enable L1 cache */
-/* #define CONFIG_SYS_ICACHE_OFF */
-/* #define CONFIG_SYS_DCACHE_OFF */
-
 #define CONFIG_SYS_MALLOC_LEN  (4 * 1024 * 1024)
 
 #define CONFIG_TIMESTAMP
diff --git a/include/configs/xilinx_versal_mini.h 
b/include/configs/xilinx_versal_mini.h
index c15fb5fc3b..b18c0bdc5a 100644
--- a/include/configs/xilinx_versal_mini.h
+++ b/include/configs/xilinx_versal_mini.h
@@ -10,7 +10,6 @@
 #ifndef __CONFIG_VERSAL_MINI_H
 #define __CONFIG_VERSAL_MINI_H
 
-/* #define CONFIG_SYS_DCACHE_OFF */
 #define CONFIG_SYS_ICACHE_OFF
 
 #define CONFIG_SYS_MEMTEST_SCRATCH 0xfffc
-- 
2.21.0.rc2

___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH v3 5/5] CONFIG_SPL_SYS_[DI]CACHE_OFF: add

2019-05-03 Thread Trevor Woerner
While converting CONFIG_SYS_[DI]CACHE_OFF to Kconfig, there are instances
where these configuration items are conditional on SPL. This commit adds SPL
variants of these configuration items, uses CONFIG_IS_ENABLED(), and updates
the configurations as required.

Acked-by: Alexey Brodkin 
Signed-off-by: Trevor Woerner 
---

Changes in v3: None
Changes in v2: None

 arch/arc/Kconfig| 14 ++
 arch/arc/lib/start.S|  4 ++--
 arch/arm/Kconfig| 14 ++
 arch/arm/cpu/arm11/cpu.c| 12 ++--
 arch/arm/cpu/arm926ejs/cache.c  | 12 ++--
 arch/arm/cpu/arm926ejs/cpu.c|  2 +-
 arch/arm/cpu/arm926ejs/start.S  |  4 ++--
 arch/arm/cpu/armv7/cache_v7.c   |  8 
 arch/arm/cpu/armv7/iproc-common/hwinit-common.c |  2 +-
 arch/arm/cpu/armv7/kona-common/hwinit-common.c  |  2 +-
 arch/arm/cpu/armv7/ls102xa/cpu.c|  4 ++--
 arch/arm/cpu/armv7/start.S  |  4 ++--
 arch/arm/cpu/armv7/vf610/generic.c  |  2 +-
 arch/arm/cpu/armv7m/cache.c |  8 
 arch/arm/cpu/armv8/cache_v8.c   | 12 ++--
 arch/arm/cpu/armv8/fsl-layerscape/cpu.c |  4 ++--
 arch/arm/cpu/armv8/s32v234/cpu.c|  2 +-
 arch/arm/cpu/pxa/cache.c|  6 +++---
 arch/arm/cpu/pxa/pxa2xx.c   |  4 ++--
 arch/arm/include/asm/global_data.h  |  2 +-
 arch/arm/lib/cache-cp15.c   |  6 +++---
 arch/arm/lib/cache.c|  2 +-
 arch/arm/mach-exynos/soc.c  |  2 +-
 arch/arm/mach-imx/cache.c   |  2 +-
 arch/arm/mach-imx/imx8/cpu.c|  2 +-
 arch/arm/mach-imx/mx5/soc.c |  2 +-
 arch/arm/mach-keystone/init.c   |  2 +-
 arch/arm/mach-omap2/Makefile|  2 +-
 arch/arm/mach-omap2/omap5/sec_entry_cpu1.S  |  6 +++---
 arch/arm/mach-omap2/sec-common.c|  4 ++--
 arch/arm/mach-rmobile/cpu_info.c|  2 +-
 arch/arm/mach-rockchip/rk3036-board.c   |  2 +-
 arch/arm/mach-rockchip/rk3128-board.c   |  2 +-
 arch/arm/mach-rockchip/rk3188-board.c   |  2 +-
 arch/arm/mach-rockchip/rk322x-board.c   |  2 +-
 arch/arm/mach-rockchip/rk3288-board.c   |  2 +-
 arch/arm/mach-rockchip/rv1108/rv1108.c  |  2 +-
 arch/arm/mach-s5pc1xx/cache.c   |  2 +-
 arch/arm/mach-socfpga/misc.c|  4 ++--
 arch/arm/mach-sunxi/board.c |  2 +-
 arch/arm/mach-tegra/board.c |  2 +-
 arch/arm/mach-zynq/cpu.c|  2 +-
 arch/nds32/Kconfig  | 14 ++
 arch/nds32/cpu/n1213/start.S|  8 
 arch/nds32/lib/cache.c  |  6 +++---
 arch/riscv/Kconfig  | 14 ++
 arch/riscv/cpu/ax25/cache.c |  8 
 arch/xtensa/Kconfig | 14 ++
 arch/xtensa/cpu/start.S |  7 ---
 board/st/stih410-b2260/board.c  |  2 +-
 cmd/bdinfo.c|  2 +-
 common/board_f.c|  2 +-
 common/lcd.c|  2 +-
 configs/bitmain_antminer_s9_defconfig   |  1 +
 configs/imx8mq_evk_defconfig|  2 ++
 configs/imx8qxp_mek_defconfig   |  2 ++
 configs/smartweb_defconfig  |  2 ++
 configs/syzygy_hub_defconfig|  1 +
 configs/taurus_defconfig|  2 ++
 configs/topic_miami_defconfig   |  1 +
 configs/topic_miamilite_defconfig   |  1 +
 configs/topic_miamiplus_defconfig   |  1 +
 configs/zynq_cse_nand_defconfig |  1 +
 configs/zynq_cse_nor_defconfig  |  1 +
 configs/zynq_cse_qspi_defconfig |  1 +
 drivers/dma/apbh_dma.c  |  2 +-
 drivers/mtd/nand/raw/mxs_nand.c |  2 +-
 drivers/net/dwc_eth_qos.c   |  2 +-
 drivers/net/rtl8169.c   |  2 +-
 drivers/net/sh_eth.c|  3 ++-
 drivers/video/video-uclass.c|  2 +-
 include/configs/imx8mq_evk.h|  2 --
 include/configs/imx8qxp_mek.h   |  2 --
 include/configs/mx7ulp_evk.h|  2 +-
 include/configs/smartweb.h  |  5 -
 include/configs/taurus.h|  4 
 include/configs/zynq-common.h   |  5 -
 77 files changed, 188 insertions(+), 118 deletions(-)

diff --git a/arch/arc/Kconfig b/arch

[U-Boot] [PATCH v3 1/5] CONFIG_SYS_[ID]CACHE_OFF: unify the 'any' case

2019-05-03 Thread Trevor Woerner
According to De Morgan's Law[1]:
!(A && B) = !A || !B
!(A || B) = !A && !B

There are 5 places in the code where we find:
#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
and 4 places in the code where we find:
#if (!defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF))

In words, the construct:
!defined(CONFIG_SYS_[DI]CACHE_OFF)
means:
"is the [DI]CACHE on?"
and the construct:
defined(CONFIG_SYS_[DI]CACHE_OFF)
means:
"is the [DI]CACHE off?"

Therefore
!(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
means:
"the opposite of 'are they both off?'"
in other words:
"are either or both on?"
and:
(!defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF)
means:
"are either or both on?"

As a result, I've converted the 4 instances of '(!A || !B)' to '!(A && B)' for
consistency.

[1] https://en.wikipedia.org/wiki/De_Morgan%27s_laws

Signed-off-by: Trevor Woerner 
---

Changes in v3: None
Changes in v2: None

 arch/arm/cpu/arm11/cpu.c | 2 +-
 arch/nds32/cpu/n1213/start.S | 2 +-
 arch/nds32/lib/cache.c   | 2 +-
 arch/xtensa/cpu/start.S  | 3 +--
 4 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/arch/arm/cpu/arm11/cpu.c b/arch/arm/cpu/arm11/cpu.c
index 41feeefec1..4aa704b9ee 100644
--- a/arch/arm/cpu/arm11/cpu.c
+++ b/arch/arm/cpu/arm11/cpu.c
@@ -97,7 +97,7 @@ void flush_dcache_all(void)
 }
 #endif /* #ifndef CONFIG_SYS_DCACHE_OFF */
 
-#if !defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF)
+#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
 void enable_caches(void)
 {
 #ifndef CONFIG_SYS_ICACHE_OFF
diff --git a/arch/nds32/cpu/n1213/start.S b/arch/nds32/cpu/n1213/start.S
index cf966e2132..4e6a0e7a31 100644
--- a/arch/nds32/cpu/n1213/start.S
+++ b/arch/nds32/cpu/n1213/start.S
@@ -129,7 +129,7 @@ set_ivb:
mfsr$r1, $mr8
and $r1, $r1, $r0
mtsr$r1, $mr8
-#if (!defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF))
+#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
 /*
  * MMU_CTL NTC0 Cacheable/Write-Back
  */
diff --git a/arch/nds32/lib/cache.c b/arch/nds32/lib/cache.c
index 9ab30d1965..3e5aa7cda8 100644
--- a/arch/nds32/lib/cache.c
+++ b/arch/nds32/lib/cache.c
@@ -6,7 +6,7 @@
  */
 
 #include 
-#if (!defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF))
+#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
 static inline unsigned long CACHE_SET(unsigned char cache)
 {
if (cache == ICACHE)
diff --git a/arch/xtensa/cpu/start.S b/arch/xtensa/cpu/start.S
index 66acb4c610..0fafb1c4f8 100644
--- a/arch/xtensa/cpu/start.S
+++ b/arch/xtensa/cpu/start.S
@@ -164,8 +164,7 @@ _start:
 * enable data/instruction cache for relocated image.
 */
 #if XCHAL_HAVE_SPANNING_WAY && \
-   (!defined(CONFIG_SYS_DCACHE_OFF) || \
-!defined(CONFIG_SYS_ICACHE_OFF))
+   !(defined(CONFIG_SYS_DCACHE_OFF) && defined(CONFIG_SYS_ICACHE_OFF))
srlia7, a4, 29
sllia7, a7, 29
addia7, a7, XCHAL_SPANNING_WAY
-- 
2.21.0.rc2

___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH v3 0/5] Kconfig conversion: CONFIG_SYS_[DI]CACHE_OFF

2019-05-03 Thread Trevor Woerner
This series of patches starts with a couple clean-up patches for various
items related to CONFIG_SYS_[DI]CACHE_OFF, then converts these two
configuration items to the Kconfig system.

CONFIG_SYS_[DI]CACHE_OFF had been minimally converted to Kconfig, but only for
the arc architecture; all other instances were still #define's in
include/configs.

In some cases a configuration wants to, for example, disable one or both
caches for SPL, but not for full U-Boot (or vice versa). Therefore additional
SPL variants needed to be added. This required the configuration checks to be
modified to use CONFIG_IS_ENABLED().

This conversion has been verified with tools/moveconfig.py

These patches have been verified with tools/buildman.py

Changes in v3:
- rebase on top of U-Boot master:
  b4ee6daad7 Merge tag 'u-boot-imx-20190426' of git://git.denx.de/u-boot-imx

Changes in v2:
- rebased on top of U-Boot master:
  3fbd2dce35 Merge branch '2019-04-22-master-imports'
- fixed up configs/xilinx_zynqmp_mini_qspi_defconfig

Trevor Woerner (5):
  CONFIG_SYS_[ID]CACHE_OFF: unify the 'any' case
  CONFIG_SYS_[DI]CACHE_OFF: remove superfluous "1"
  CONFIG_SYS_[DI]CACHE_OFF: remove commented lines
  CONFIG_SYS_[DI]CACHE_OFF: convert to Kconfig
  CONFIG_SPL_SYS_[DI]CACHE_OFF: add

 README|  2 --
 arch/arc/Kconfig  | 22 ++--
 arch/arc/lib/start.S  |  4 +--
 arch/arm/Kconfig  | 26 +++
 arch/arm/cpu/arm11/cpu.c  | 12 -
 arch/arm/cpu/arm926ejs/cache.c| 12 -
 arch/arm/cpu/arm926ejs/cpu.c  |  2 +-
 arch/arm/cpu/arm926ejs/start.S|  4 +--
 arch/arm/cpu/armv7/cache_v7.c |  8 +++---
 .../cpu/armv7/iproc-common/hwinit-common.c|  2 +-
 .../arm/cpu/armv7/kona-common/hwinit-common.c |  2 +-
 arch/arm/cpu/armv7/ls102xa/cpu.c  |  4 +--
 arch/arm/cpu/armv7/start.S|  4 +--
 arch/arm/cpu/armv7/vf610/generic.c|  2 +-
 arch/arm/cpu/armv7m/cache.c   |  8 +++---
 arch/arm/cpu/armv8/cache_v8.c | 12 -
 arch/arm/cpu/armv8/fsl-layerscape/cpu.c   |  4 +--
 arch/arm/cpu/armv8/s32v234/cpu.c  |  2 +-
 arch/arm/cpu/pxa/cache.c  |  6 ++---
 arch/arm/cpu/pxa/pxa2xx.c |  4 +--
 arch/arm/include/asm/global_data.h|  2 +-
 arch/arm/lib/cache-cp15.c |  6 ++---
 arch/arm/lib/cache.c  |  2 +-
 arch/arm/mach-exynos/soc.c|  2 +-
 arch/arm/mach-imx/cache.c |  2 +-
 arch/arm/mach-imx/imx8/cpu.c  |  2 +-
 arch/arm/mach-imx/mx5/soc.c   |  2 +-
 arch/arm/mach-keystone/init.c |  2 +-
 arch/arm/mach-kirkwood/include/mach/config.h  |  6 -
 arch/arm/mach-omap2/Makefile  |  2 +-
 arch/arm/mach-omap2/omap5/sec_entry_cpu1.S|  6 ++---
 arch/arm/mach-omap2/sec-common.c  |  4 +--
 arch/arm/mach-rmobile/cpu_info.c  |  2 +-
 arch/arm/mach-rockchip/rk3036-board.c |  2 +-
 arch/arm/mach-rockchip/rk3128-board.c |  2 +-
 arch/arm/mach-rockchip/rk3188-board.c |  2 +-
 arch/arm/mach-rockchip/rk322x-board.c |  2 +-
 arch/arm/mach-rockchip/rk3288-board.c |  2 +-
 arch/arm/mach-rockchip/rv1108/rv1108.c|  2 +-
 arch/arm/mach-s5pc1xx/cache.c |  2 +-
 arch/arm/mach-socfpga/misc.c  |  4 +--
 arch/arm/mach-sunxi/board.c   |  2 +-
 arch/arm/mach-tegra/board.c   |  2 +-
 arch/arm/mach-zynq/cpu.c  |  2 +-
 arch/nds32/Kconfig| 26 +++
 arch/nds32/cpu/n1213/start.S  |  8 +++---
 arch/nds32/lib/cache.c|  6 ++---
 arch/riscv/Kconfig| 26 +++
 arch/riscv/cpu/ax25/cache.c   |  8 +++---
 arch/xtensa/Kconfig   | 26 +++
 arch/xtensa/cpu/start.S   |  8 +++---
 board/st/stih410-b2260/board.c|  2 +-
 cmd/bdinfo.c  |  2 +-
 common/board_f.c  |  2 +-
 common/lcd.c  |  2 +-
 configs/SBx81LIFKW_defconfig  |  1 +
 configs/SBx81LIFXCAT_defconfig|  1 +
 configs/armadillo-800eva_defconfig|  1 +
 configs/bcm23550_w1d_defconfig|  2 ++
 configs/bitmain_antminer_s9_defconfig |  1 +
 configs/colibri_pxa270_defconfig  |  1 +
 configs/d2net_v2_defconfig|  1 +
 configs/devkit3250_defconfig  |  2 ++
 configs/dns325_defconfig  |  1 +
 configs/dockstar

[U-Boot] [PATCH v2 4/5] CONFIG_SYS_[DI]CACHE_OFF: convert to Kconfig

2019-04-25 Thread Trevor Woerner
CONFIG_SYS_[DI]CACHE_OFF had been partially converted to Kconfig
parameters; only for the ARC architecture. This patch turns these two
parameters into Kconfig items everywhere else they are found.

All of the include/configs/* and defconfig changes in this patch are
for arm machines only. The Kconfig changes for arc, nds32, riscv,
and xtensa have been included since these symbols are found in code
under arch/{arc,nds32,riscv,xtensa}, however, no currently-defined
include/configs/* or defconfigs for these architectures exist which
include these symbols.

These results have been confirmed with tools/moveconfig.py.

Acked-by: Alexey Brodkin 
Signed-off-by: Trevor Woerner 

---

Changes in v2:
- rebased on top of U-Boot master:
  3fbd2dce35 Merge branch '2019-04-22-master-imports'
- fixed up configs/xilinx_zynqmp_mini_qspi_defconfig

 README   |  2 --
 arch/arc/Kconfig |  8 ++--
 arch/arm/Kconfig | 12 
 arch/arm/mach-kirkwood/include/mach/config.h |  6 --
 arch/nds32/Kconfig   | 12 
 arch/riscv/Kconfig   | 12 
 arch/xtensa/Kconfig  | 12 
 configs/SBx81LIFKW_defconfig |  1 +
 configs/SBx81LIFXCAT_defconfig   |  1 +
 configs/armadillo-800eva_defconfig   |  1 +
 configs/bcm23550_w1d_defconfig   |  2 ++
 configs/colibri_pxa270_defconfig |  1 +
 configs/d2net_v2_defconfig   |  1 +
 configs/devkit3250_defconfig |  2 ++
 configs/dns325_defconfig |  1 +
 configs/dockstar_defconfig   |  1 +
 configs/dreamplug_defconfig  |  1 +
 configs/ds109_defconfig  |  1 +
 configs/evb-ast2500_defconfig|  1 +
 configs/flea3_defconfig  |  1 +
 configs/goflexhome_defconfig |  1 +
 configs/gplugd_defconfig |  1 +
 configs/guruplug_defconfig   |  1 +
 configs/highbank_defconfig   |  1 +
 configs/ib62x0_defconfig |  1 +
 configs/iconnect_defconfig   |  1 +
 configs/inetspace_v2_defconfig   |  1 +
 configs/k2e_evm_defconfig|  1 +
 configs/k2e_hs_evm_defconfig |  1 +
 configs/k2g_evm_defconfig|  1 +
 configs/k2g_hs_evm_defconfig |  1 +
 configs/k2hk_evm_defconfig   |  1 +
 configs/k2hk_hs_evm_defconfig|  1 +
 configs/k2l_evm_defconfig|  1 +
 configs/k2l_hs_evm_defconfig |  1 +
 configs/km_kirkwood_128m16_defconfig |  1 +
 configs/km_kirkwood_defconfig|  1 +
 configs/km_kirkwood_pci_defconfig|  1 +
 configs/kmcoge5un_defconfig  |  1 +
 configs/kmnusa_defconfig |  1 +
 configs/kmsugp1_defconfig|  1 +
 configs/kmsuv31_defconfig|  1 +
 configs/lschlv2_defconfig|  1 +
 configs/lsxhl_defconfig  |  1 +
 configs/mgcoge3un_defconfig  |  1 +
 configs/nas220_defconfig |  1 +
 configs/net2big_v2_defconfig |  1 +
 configs/netspace_lite_v2_defconfig   |  1 +
 configs/netspace_max_v2_defconfig|  1 +
 configs/netspace_mini_v2_defconfig   |  1 +
 configs/netspace_v2_defconfig|  1 +
 configs/nsa310s_defconfig|  1 +
 configs/openrd_base_defconfig|  1 +
 configs/openrd_client_defconfig  |  1 +
 configs/openrd_ultimate_defconfig|  1 +
 configs/origen_defconfig |  1 +
 configs/pogo_e02_defconfig   |  1 +
 configs/portl2_defconfig |  1 +
 configs/sheevaplug_defconfig |  1 +
 configs/stv0991_defconfig|  1 +
 configs/woodburn_defconfig   |  1 +
 configs/woodburn_sd_defconfig|  1 +
 configs/work_92105_defconfig |  2 ++
 configs/xilinx_versal_mini_defconfig |  1 +
 configs/xilinx_versal_mini_emmc0_defconfig   |  1 +
 configs/xilinx_versal_mini_emmc1_defconfig   |  1 +
 configs/xilinx_zynqmp_mini_defconfig |  1 +
 configs/xilinx_zynqmp_mini_emmc0_defconfig   |  1 +
 configs/xilinx_zynqmp_mini_emmc1_defconfig   |  1 +
 configs/xilinx_zynqmp_mini_nand_defconfig|  1 +
 configs/xilinx_zynqmp_mini_qspi_defconfig|  1 +
 configs/zynq_cse_nand_defconfig  |  2 ++
 configs/zynq_cse_nor_defconfig   |  2 ++
 configs/zynq_cse_qspi_defconfig  |  2 ++
 include/configs/armadillo-800eva.h   |  1 -
 include/configs/aspeed-common.h  |  3 ---
 include/configs/bcm23550_w1d.h   |  2 -

[U-Boot] [PATCH v2 5/5] CONFIG_SPL_SYS_[DI]CACHE_OFF: add

2019-04-25 Thread Trevor Woerner
While converting CONFIG_SYS_[DI]CACHE_OFF to Kconfig, there are instances
where these configuration items are conditional on SPL. This commit adds SPL
variants of these configuration items, uses CONFIG_IS_ENABLED(), and updates
the configurations as required.

Acked-by: Alexey Brodkin 
Signed-off-by: Trevor Woerner 
---

Changes in v2: None

 arch/arc/Kconfig| 14 ++
 arch/arc/lib/start.S|  4 ++--
 arch/arm/Kconfig| 14 ++
 arch/arm/cpu/arm11/cpu.c| 12 ++--
 arch/arm/cpu/arm926ejs/cache.c  | 12 ++--
 arch/arm/cpu/arm926ejs/cpu.c|  2 +-
 arch/arm/cpu/arm926ejs/start.S  |  4 ++--
 arch/arm/cpu/armv7/cache_v7.c   |  8 
 arch/arm/cpu/armv7/iproc-common/hwinit-common.c |  2 +-
 arch/arm/cpu/armv7/kona-common/hwinit-common.c  |  2 +-
 arch/arm/cpu/armv7/ls102xa/cpu.c|  4 ++--
 arch/arm/cpu/armv7/start.S  |  4 ++--
 arch/arm/cpu/armv7/vf610/generic.c  |  2 +-
 arch/arm/cpu/armv7m/cache.c |  8 
 arch/arm/cpu/armv8/cache_v8.c   | 12 ++--
 arch/arm/cpu/armv8/fsl-layerscape/cpu.c |  4 ++--
 arch/arm/cpu/armv8/s32v234/cpu.c|  2 +-
 arch/arm/cpu/pxa/cache.c|  6 +++---
 arch/arm/cpu/pxa/pxa2xx.c   |  4 ++--
 arch/arm/include/asm/global_data.h  |  2 +-
 arch/arm/lib/cache-cp15.c   |  6 +++---
 arch/arm/lib/cache.c|  2 +-
 arch/arm/mach-exynos/soc.c  |  2 +-
 arch/arm/mach-imx/cache.c   |  2 +-
 arch/arm/mach-imx/imx8/cpu.c|  2 +-
 arch/arm/mach-imx/mx5/soc.c |  2 +-
 arch/arm/mach-keystone/init.c   |  2 +-
 arch/arm/mach-omap2/Makefile|  2 +-
 arch/arm/mach-omap2/omap5/sec_entry_cpu1.S  |  6 +++---
 arch/arm/mach-omap2/sec-common.c|  4 ++--
 arch/arm/mach-rmobile/cpu_info.c|  2 +-
 arch/arm/mach-rockchip/rk3036-board.c   |  2 +-
 arch/arm/mach-rockchip/rk3128-board.c   |  2 +-
 arch/arm/mach-rockchip/rk3188-board.c   |  2 +-
 arch/arm/mach-rockchip/rk322x-board.c   |  2 +-
 arch/arm/mach-rockchip/rk3288-board.c   |  2 +-
 arch/arm/mach-rockchip/rv1108/rv1108.c  |  2 +-
 arch/arm/mach-s5pc1xx/cache.c   |  2 +-
 arch/arm/mach-socfpga/misc.c|  4 ++--
 arch/arm/mach-sunxi/board.c |  2 +-
 arch/arm/mach-tegra/board.c |  2 +-
 arch/arm/mach-zynq/cpu.c|  2 +-
 arch/nds32/Kconfig  | 14 ++
 arch/nds32/cpu/n1213/start.S|  8 
 arch/nds32/lib/cache.c  |  6 +++---
 arch/riscv/Kconfig  | 14 ++
 arch/riscv/cpu/ax25/cache.c |  8 
 arch/xtensa/Kconfig | 14 ++
 arch/xtensa/cpu/start.S |  7 ---
 board/st/stih410-b2260/board.c  |  2 +-
 cmd/bdinfo.c|  2 +-
 common/board_f.c|  2 +-
 common/lcd.c|  2 +-
 configs/bitmain_antminer_s9_defconfig   |  1 +
 configs/imx8mq_evk_defconfig|  2 ++
 configs/imx8qxp_mek_defconfig   |  2 ++
 configs/smartweb_defconfig  |  2 ++
 configs/syzygy_hub_defconfig|  1 +
 configs/taurus_defconfig|  2 ++
 configs/topic_miami_defconfig   |  1 +
 configs/topic_miamilite_defconfig   |  1 +
 configs/topic_miamiplus_defconfig   |  1 +
 configs/zynq_cse_nand_defconfig |  1 +
 configs/zynq_cse_nor_defconfig  |  1 +
 configs/zynq_cse_qspi_defconfig |  1 +
 drivers/dma/apbh_dma.c  |  2 +-
 drivers/mtd/nand/raw/mxs_nand.c |  2 +-
 drivers/net/dwc_eth_qos.c   |  2 +-
 drivers/net/rtl8169.c   |  2 +-
 drivers/net/sh_eth.c|  3 ++-
 drivers/video/video-uclass.c|  2 +-
 include/configs/imx8mq_evk.h|  2 --
 include/configs/imx8qxp_mek.h   |  2 --
 include/configs/mx7ulp_evk.h|  2 +-
 include/configs/smartweb.h  |  5 -
 include/configs/taurus.h|  4 
 include/configs/zynq-common.h   |  5 -
 77 files changed, 188 insertions(+), 118 deletions(-)

diff --git a/arch/arc/Kconfig b/arch/arc/Kconfig
index

[U-Boot] [PATCH v2 3/5] CONFIG_SYS_[DI]CACHE_OFF: remove commented lines

2019-04-25 Thread Trevor Woerner
Eventually these configuration items will be converted to Kconfig,
therefore there's little point in leaving commented-out versions of
them in include/configs.

Signed-off-by: Trevor Woerner 
---

Changes in v2: None

 include/configs/uniphier.h   | 4 
 include/configs/xilinx_versal_mini.h | 1 -
 2 files changed, 5 deletions(-)

diff --git a/include/configs/uniphier.h b/include/configs/uniphier.h
index 1e509ce9ad..2d1f67fa62 100644
--- a/include/configs/uniphier.h
+++ b/include/configs/uniphier.h
@@ -45,10 +45,6 @@
  * MMU and Cache Setting
  *--*/
 
-/* Comment out the following to enable L1 cache */
-/* #define CONFIG_SYS_ICACHE_OFF */
-/* #define CONFIG_SYS_DCACHE_OFF */
-
 #define CONFIG_SYS_MALLOC_LEN  (4 * 1024 * 1024)
 
 #define CONFIG_TIMESTAMP
diff --git a/include/configs/xilinx_versal_mini.h 
b/include/configs/xilinx_versal_mini.h
index c15fb5fc3b..b18c0bdc5a 100644
--- a/include/configs/xilinx_versal_mini.h
+++ b/include/configs/xilinx_versal_mini.h
@@ -10,7 +10,6 @@
 #ifndef __CONFIG_VERSAL_MINI_H
 #define __CONFIG_VERSAL_MINI_H
 
-/* #define CONFIG_SYS_DCACHE_OFF */
 #define CONFIG_SYS_ICACHE_OFF
 
 #define CONFIG_SYS_MEMTEST_SCRATCH 0xfffc
-- 
2.21.0.rc2

___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH v2 2/5] CONFIG_SYS_[DI]CACHE_OFF: remove superfluous "1"

2019-04-25 Thread Trevor Woerner
This config is the only config that uses:
#define CONFIG_SYS_DCACHE_OFF 1
in its #define.

Remove the superfluous "1" so this cache #define is like all the others.

Signed-off-by: Trevor Woerner 
---

Changes in v2: None

 include/configs/origen.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/configs/origen.h b/include/configs/origen.h
index 1acc42f964..c9b1566ac3 100644
--- a/include/configs/origen.h
+++ b/include/configs/origen.h
@@ -14,7 +14,7 @@
 #define CONFIG_EXYNOS4210  1   /* which is a EXYNOS4210 SoC */
 #define CONFIG_ORIGEN  1   /* working with ORIGEN*/
 
-#define CONFIG_SYS_DCACHE_OFF  1
+#define CONFIG_SYS_DCACHE_OFF
 
 /* ORIGEN has 4 bank of DRAM */
 #define CONFIG_SYS_SDRAM_BASE  0x4000
-- 
2.21.0.rc2

___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH v2 1/5] CONFIG_SYS_[ID]CACHE_OFF: unify the 'any' case

2019-04-25 Thread Trevor Woerner
According to De Morgan's Law[1]:
!(A && B) = !A || !B
!(A || B) = !A && !B

There are 5 places in the code where we find:
#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
and 4 places in the code where we find:
#if (!defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF))

In words, the construct:
!defined(CONFIG_SYS_[DI]CACHE_OFF)
means:
"is the [DI]CACHE on?"
and the construct:
defined(CONFIG_SYS_[DI]CACHE_OFF)
means:
"is the [DI]CACHE off?"

Therefore
!(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
means:
"the opposite of 'are they both off?'"
in other words:
"are either or both on?"
and:
(!defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF)
means:
"are either or both on?"

As a result, I've converted the 4 instances of '(!A || !B)' to '!(A && B)' for
consistency.

[1] https://en.wikipedia.org/wiki/De_Morgan%27s_laws

Signed-off-by: Trevor Woerner 
---

Changes in v2: None

 arch/arm/cpu/arm11/cpu.c | 2 +-
 arch/nds32/cpu/n1213/start.S | 2 +-
 arch/nds32/lib/cache.c   | 2 +-
 arch/xtensa/cpu/start.S  | 3 +--
 4 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/arch/arm/cpu/arm11/cpu.c b/arch/arm/cpu/arm11/cpu.c
index 41feeefec1..4aa704b9ee 100644
--- a/arch/arm/cpu/arm11/cpu.c
+++ b/arch/arm/cpu/arm11/cpu.c
@@ -97,7 +97,7 @@ void flush_dcache_all(void)
 }
 #endif /* #ifndef CONFIG_SYS_DCACHE_OFF */
 
-#if !defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF)
+#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
 void enable_caches(void)
 {
 #ifndef CONFIG_SYS_ICACHE_OFF
diff --git a/arch/nds32/cpu/n1213/start.S b/arch/nds32/cpu/n1213/start.S
index cf966e2132..4e6a0e7a31 100644
--- a/arch/nds32/cpu/n1213/start.S
+++ b/arch/nds32/cpu/n1213/start.S
@@ -129,7 +129,7 @@ set_ivb:
mfsr$r1, $mr8
and $r1, $r1, $r0
mtsr$r1, $mr8
-#if (!defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF))
+#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
 /*
  * MMU_CTL NTC0 Cacheable/Write-Back
  */
diff --git a/arch/nds32/lib/cache.c b/arch/nds32/lib/cache.c
index 9ab30d1965..3e5aa7cda8 100644
--- a/arch/nds32/lib/cache.c
+++ b/arch/nds32/lib/cache.c
@@ -6,7 +6,7 @@
  */
 
 #include 
-#if (!defined(CONFIG_SYS_ICACHE_OFF) || !defined(CONFIG_SYS_DCACHE_OFF))
+#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF))
 static inline unsigned long CACHE_SET(unsigned char cache)
 {
if (cache == ICACHE)
diff --git a/arch/xtensa/cpu/start.S b/arch/xtensa/cpu/start.S
index 66acb4c610..0fafb1c4f8 100644
--- a/arch/xtensa/cpu/start.S
+++ b/arch/xtensa/cpu/start.S
@@ -164,8 +164,7 @@ _start:
 * enable data/instruction cache for relocated image.
 */
 #if XCHAL_HAVE_SPANNING_WAY && \
-   (!defined(CONFIG_SYS_DCACHE_OFF) || \
-!defined(CONFIG_SYS_ICACHE_OFF))
+   !(defined(CONFIG_SYS_DCACHE_OFF) && defined(CONFIG_SYS_ICACHE_OFF))
srlia7, a4, 29
sllia7, a7, 29
addia7, a7, XCHAL_SPANNING_WAY
-- 
2.21.0.rc2

___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH v2 0/5] Kconfig conversion: CONFIG_SYS_[DI]CACHE_OFF

2019-04-25 Thread Trevor Woerner
This series of patches starts with a couple clean-up patches for various
items related to CONFIG_SYS_[DI]CACHE_OFF, then converts these two
configuration items to the Kconfig system.

CONFIG_SYS_[DI]CACHE_OFF had been minimally converted to Kconfig, but only for
the arc architecture; all other instances were still #define's in
include/configs.

In some cases a configuration wants to, for example, disable one or both
caches for SPL, but not for full U-Boot (or vice versa). Therefore additional
SPL variants needed to be added. This required the configuration checks to be
modified to use CONFIG_IS_ENABLED().

This conversion has been verified with tools/moveconfig.py

These patches have been verified with tools/buildman.py

Changes in v2:
- rebased on top of U-Boot master:
  3fbd2dce35 Merge branch '2019-04-22-master-imports'
- fixed up configs/xilinx_zynqmp_mini_qspi_defconfig

Trevor Woerner (5):
  CONFIG_SYS_[ID]CACHE_OFF: unify the 'any' case
  CONFIG_SYS_[DI]CACHE_OFF: remove superfluous "1"
  CONFIG_SYS_[DI]CACHE_OFF: remove commented lines
  CONFIG_SYS_[DI]CACHE_OFF: convert to Kconfig
  CONFIG_SPL_SYS_[DI]CACHE_OFF: add

 README|  2 --
 arch/arc/Kconfig  | 22 ++--
 arch/arc/lib/start.S  |  4 +--
 arch/arm/Kconfig  | 26 +++
 arch/arm/cpu/arm11/cpu.c  | 12 -
 arch/arm/cpu/arm926ejs/cache.c| 12 -
 arch/arm/cpu/arm926ejs/cpu.c  |  2 +-
 arch/arm/cpu/arm926ejs/start.S|  4 +--
 arch/arm/cpu/armv7/cache_v7.c |  8 +++---
 .../cpu/armv7/iproc-common/hwinit-common.c|  2 +-
 .../arm/cpu/armv7/kona-common/hwinit-common.c |  2 +-
 arch/arm/cpu/armv7/ls102xa/cpu.c  |  4 +--
 arch/arm/cpu/armv7/start.S|  4 +--
 arch/arm/cpu/armv7/vf610/generic.c|  2 +-
 arch/arm/cpu/armv7m/cache.c   |  8 +++---
 arch/arm/cpu/armv8/cache_v8.c | 12 -
 arch/arm/cpu/armv8/fsl-layerscape/cpu.c   |  4 +--
 arch/arm/cpu/armv8/s32v234/cpu.c  |  2 +-
 arch/arm/cpu/pxa/cache.c  |  6 ++---
 arch/arm/cpu/pxa/pxa2xx.c |  4 +--
 arch/arm/include/asm/global_data.h|  2 +-
 arch/arm/lib/cache-cp15.c |  6 ++---
 arch/arm/lib/cache.c  |  2 +-
 arch/arm/mach-exynos/soc.c|  2 +-
 arch/arm/mach-imx/cache.c |  2 +-
 arch/arm/mach-imx/imx8/cpu.c  |  2 +-
 arch/arm/mach-imx/mx5/soc.c   |  2 +-
 arch/arm/mach-keystone/init.c |  2 +-
 arch/arm/mach-kirkwood/include/mach/config.h  |  6 -
 arch/arm/mach-omap2/Makefile  |  2 +-
 arch/arm/mach-omap2/omap5/sec_entry_cpu1.S|  6 ++---
 arch/arm/mach-omap2/sec-common.c  |  4 +--
 arch/arm/mach-rmobile/cpu_info.c  |  2 +-
 arch/arm/mach-rockchip/rk3036-board.c |  2 +-
 arch/arm/mach-rockchip/rk3128-board.c |  2 +-
 arch/arm/mach-rockchip/rk3188-board.c |  2 +-
 arch/arm/mach-rockchip/rk322x-board.c |  2 +-
 arch/arm/mach-rockchip/rk3288-board.c |  2 +-
 arch/arm/mach-rockchip/rv1108/rv1108.c|  2 +-
 arch/arm/mach-s5pc1xx/cache.c |  2 +-
 arch/arm/mach-socfpga/misc.c  |  4 +--
 arch/arm/mach-sunxi/board.c   |  2 +-
 arch/arm/mach-tegra/board.c   |  2 +-
 arch/arm/mach-zynq/cpu.c  |  2 +-
 arch/nds32/Kconfig| 26 +++
 arch/nds32/cpu/n1213/start.S  |  8 +++---
 arch/nds32/lib/cache.c|  6 ++---
 arch/riscv/Kconfig| 26 +++
 arch/riscv/cpu/ax25/cache.c   |  8 +++---
 arch/xtensa/Kconfig   | 26 +++
 arch/xtensa/cpu/start.S   |  8 +++---
 board/st/stih410-b2260/board.c|  2 +-
 cmd/bdinfo.c  |  2 +-
 common/board_f.c  |  2 +-
 common/lcd.c  |  2 +-
 configs/SBx81LIFKW_defconfig  |  1 +
 configs/SBx81LIFXCAT_defconfig|  1 +
 configs/armadillo-800eva_defconfig|  1 +
 configs/bcm23550_w1d_defconfig|  2 ++
 configs/bitmain_antminer_s9_defconfig |  1 +
 configs/colibri_pxa270_defconfig  |  1 +
 configs/d2net_v2_defconfig|  1 +
 configs/devkit3250_defconfig  |  2 ++
 configs/dns325_defconfig  |  1 +
 configs/dockstar_defconfig|  1 +
 configs/dreamplug_defconfig   |  1 +
 configs/ds109_defconfig   | 

Re: [U-Boot] [PATCH v1 4/5] CONFIG_SYS_[DI]CACHE_OFF: convert to Kconfig

2019-04-18 Thread Trevor Woerner
On Thu 2019-04-18 @ 04:49:30 PM, Alexey Brodkin wrote:
> Hi Trevor,
> 
> > -Original Message-
>  
> > CONFIG_SYS_[DI]CACHE_OFF had been partially converted to Kconfig
> > parameters; only for the ARC architecture. This patch turns these two
> > parameters into Kconfig items everywhere else they are found.
> > 
> > All of the include/configs/* and defconfig changes in this patch are
> > for arm machines only. The Kconfig changes for arc, nds32, riscv,
> > and xtensa have been included since these symbols are found in code
> > under arch/{arc,nds32,riscv,xtensa}, however, no currently-defined
> > include/configs/* or defconfigs for these architectures exist which
> > include these symbols.
> > 
> > These results have been confirmed with tools/moveconfig.py.
> > 
> > Signed-off-by: Trevor Woerner 
> > 
> > ---
> > 
> >  README   |  2 --
> >  arch/arc/Kconfig |  8 ++--
> 
> Even though I'm ok with ARC changes (which are just
> rephrases in help message) I'm wondering if we now may finally
> move both items (for D$ & I$) to a higher level to reduce duplication?
> 
> Acked-by: Alexey Brodkin 

Hi Alexey,

Thank you for your review!

The changes I made to the ARC menu were just to make all the text the same
between all the architectures.

Regarding moving the cache configuration up to a higher level, I had asked
myself the same question as I prepared these patches.

I wouldn't want people to think they have have the ability to affect
whether of not the caches are enabled on architectures where no such
ability is possible in the code. So I either had to enable it on a
per-architecture basis, or I would have to add "depends on ARC || ARM ||
..." if I moved it to a higher level.

In my first pass through this change, I had done exactly that. I had moved
these options out from ARC and put them at a higher level with a "depends
on ..." clause. However I wasn't happy with the result, because, to me, I
would rather be asked questions about enabling caches in the
architecture-specific menus, rather than at a higher-level "general" menu.

Does that seem like a good idea? Does it make more sense to ask people
questions about the cache in an architecture-specific menu rather than in a
general or higher-level menu?

Best regards,
Trevor
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH v1 5/5] CONFIG_SPL_SYS_[DI]CACHE_OFF: add

2019-04-18 Thread Trevor Woerner
While converting CONFIG_SYS_[DI]CACHE_OFF to Kconfig, there are instances
where these configuration items are conditional on SPL. This commit adds SPL
variants of these configuration items, uses CONFIG_IS_ENABLED(), and updates
the configurations as required.

Signed-off-by: Trevor Woerner 
---

 arch/arc/Kconfig| 14 ++
 arch/arc/lib/start.S|  4 ++--
 arch/arm/Kconfig| 14 ++
 arch/arm/cpu/arm11/cpu.c| 12 ++--
 arch/arm/cpu/arm926ejs/cache.c  | 12 ++--
 arch/arm/cpu/arm926ejs/cpu.c|  2 +-
 arch/arm/cpu/arm926ejs/start.S  |  4 ++--
 arch/arm/cpu/armv7/cache_v7.c   |  8 
 arch/arm/cpu/armv7/iproc-common/hwinit-common.c |  2 +-
 arch/arm/cpu/armv7/kona-common/hwinit-common.c  |  2 +-
 arch/arm/cpu/armv7/ls102xa/cpu.c|  4 ++--
 arch/arm/cpu/armv7/start.S  |  4 ++--
 arch/arm/cpu/armv7/vf610/generic.c  |  2 +-
 arch/arm/cpu/armv7m/cache.c |  8 
 arch/arm/cpu/armv8/cache_v8.c   | 12 ++--
 arch/arm/cpu/armv8/fsl-layerscape/cpu.c |  4 ++--
 arch/arm/cpu/armv8/s32v234/cpu.c|  2 +-
 arch/arm/cpu/pxa/cache.c|  6 +++---
 arch/arm/cpu/pxa/pxa2xx.c   |  4 ++--
 arch/arm/include/asm/global_data.h  |  2 +-
 arch/arm/lib/cache-cp15.c   |  6 +++---
 arch/arm/lib/cache.c|  2 +-
 arch/arm/mach-exynos/soc.c  |  2 +-
 arch/arm/mach-imx/cache.c   |  2 +-
 arch/arm/mach-imx/imx8/cpu.c|  2 +-
 arch/arm/mach-imx/mx5/soc.c |  2 +-
 arch/arm/mach-keystone/init.c   |  2 +-
 arch/arm/mach-omap2/Makefile|  2 +-
 arch/arm/mach-omap2/omap5/sec_entry_cpu1.S  |  6 +++---
 arch/arm/mach-omap2/sec-common.c|  4 ++--
 arch/arm/mach-rmobile/cpu_info.c|  2 +-
 arch/arm/mach-rockchip/rk3036-board.c   |  2 +-
 arch/arm/mach-rockchip/rk3128-board.c   |  2 +-
 arch/arm/mach-rockchip/rk3188-board.c   |  2 +-
 arch/arm/mach-rockchip/rk322x-board.c   |  2 +-
 arch/arm/mach-rockchip/rk3288-board.c   |  2 +-
 arch/arm/mach-rockchip/rv1108/rv1108.c  |  2 +-
 arch/arm/mach-s5pc1xx/cache.c   |  2 +-
 arch/arm/mach-socfpga/misc.c|  4 ++--
 arch/arm/mach-sunxi/board.c |  2 +-
 arch/arm/mach-tegra/board.c |  2 +-
 arch/arm/mach-zynq/cpu.c|  2 +-
 arch/nds32/Kconfig  | 14 ++
 arch/nds32/cpu/n1213/start.S|  8 
 arch/nds32/lib/cache.c  |  6 +++---
 arch/riscv/Kconfig  | 14 ++
 arch/riscv/cpu/ax25/cache.c |  8 
 arch/xtensa/Kconfig | 14 ++
 arch/xtensa/cpu/start.S |  7 ---
 board/st/stih410-b2260/board.c  |  2 +-
 cmd/bdinfo.c|  2 +-
 common/board_f.c|  2 +-
 common/lcd.c|  2 +-
 configs/bitmain_antminer_s9_defconfig   |  1 +
 configs/imx8mq_evk_defconfig|  2 ++
 configs/imx8qxp_mek_defconfig   |  2 ++
 configs/smartweb_defconfig  |  2 ++
 configs/syzygy_hub_defconfig|  1 +
 configs/taurus_defconfig|  2 ++
 configs/topic_miami_defconfig   |  1 +
 configs/topic_miamilite_defconfig   |  1 +
 configs/topic_miamiplus_defconfig   |  1 +
 configs/zynq_cse_nand_defconfig |  1 +
 configs/zynq_cse_nor_defconfig  |  1 +
 configs/zynq_cse_qspi_defconfig |  1 +
 drivers/dma/apbh_dma.c  |  2 +-
 drivers/mtd/nand/raw/mxs_nand.c |  2 +-
 drivers/net/dwc_eth_qos.c   |  2 +-
 drivers/net/rtl8169.c   |  2 +-
 drivers/net/sh_eth.c|  3 ++-
 drivers/video/video-uclass.c|  2 +-
 include/configs/imx8mq_evk.h|  2 --
 include/configs/imx8qxp_mek.h   |  2 --
 include/configs/mx7ulp_evk.h|  2 +-
 include/configs/smartweb.h  |  5 -
 include/configs/taurus.h|  4 
 include/configs/zynq-common.h   |  5 -
 77 files changed, 188 insertions(+), 118 deletions(-)

diff --git a/arch/arc/Kconfig b/arch/arc/Kconfig
index 240d3bbedc..7d00666a3b 100644
--- a/arch/arc

[U-Boot] [PATCH v1 4/5] CONFIG_SYS_[DI]CACHE_OFF: convert to Kconfig

2019-04-18 Thread Trevor Woerner
CONFIG_SYS_[DI]CACHE_OFF had been partially converted to Kconfig
parameters; only for the ARC architecture. This patch turns these two
parameters into Kconfig items everywhere else they are found.

All of the include/configs/* and defconfig changes in this patch are
for arm machines only. The Kconfig changes for arc, nds32, riscv,
and xtensa have been included since these symbols are found in code
under arch/{arc,nds32,riscv,xtensa}, however, no currently-defined
include/configs/* or defconfigs for these architectures exist which
include these symbols.

These results have been confirmed with tools/moveconfig.py.

Signed-off-by: Trevor Woerner 

---

 README   |  2 --
 arch/arc/Kconfig |  8 ++--
 arch/arm/Kconfig | 12 
 arch/arm/mach-kirkwood/include/mach/config.h |  6 --
 arch/nds32/Kconfig   | 12 
 arch/riscv/Kconfig   | 12 
 arch/xtensa/Kconfig  | 12 
 configs/SBx81LIFKW_defconfig |  1 +
 configs/SBx81LIFXCAT_defconfig   |  1 +
 configs/armadillo-800eva_defconfig   |  1 +
 configs/bcm23550_w1d_defconfig   |  2 ++
 configs/colibri_pxa270_defconfig |  1 +
 configs/d2net_v2_defconfig   |  1 +
 configs/devkit3250_defconfig |  2 ++
 configs/dns325_defconfig |  1 +
 configs/dockstar_defconfig   |  1 +
 configs/dreamplug_defconfig  |  1 +
 configs/ds109_defconfig  |  1 +
 configs/evb-ast2500_defconfig|  1 +
 configs/flea3_defconfig  |  1 +
 configs/goflexhome_defconfig |  1 +
 configs/gplugd_defconfig |  1 +
 configs/guruplug_defconfig   |  1 +
 configs/highbank_defconfig   |  1 +
 configs/ib62x0_defconfig |  1 +
 configs/iconnect_defconfig   |  1 +
 configs/inetspace_v2_defconfig   |  1 +
 configs/k2e_evm_defconfig|  1 +
 configs/k2e_hs_evm_defconfig |  1 +
 configs/k2g_evm_defconfig|  1 +
 configs/k2g_hs_evm_defconfig |  1 +
 configs/k2hk_evm_defconfig   |  1 +
 configs/k2hk_hs_evm_defconfig|  1 +
 configs/k2l_evm_defconfig|  1 +
 configs/k2l_hs_evm_defconfig |  1 +
 configs/km_kirkwood_128m16_defconfig |  1 +
 configs/km_kirkwood_defconfig|  1 +
 configs/km_kirkwood_pci_defconfig|  1 +
 configs/kmcoge5un_defconfig  |  1 +
 configs/kmnusa_defconfig |  1 +
 configs/kmsugp1_defconfig|  1 +
 configs/kmsuv31_defconfig|  1 +
 configs/lschlv2_defconfig|  1 +
 configs/lsxhl_defconfig  |  1 +
 configs/mgcoge3un_defconfig  |  1 +
 configs/nas220_defconfig |  1 +
 configs/net2big_v2_defconfig |  1 +
 configs/netspace_lite_v2_defconfig   |  1 +
 configs/netspace_max_v2_defconfig|  1 +
 configs/netspace_mini_v2_defconfig   |  1 +
 configs/netspace_v2_defconfig|  1 +
 configs/nsa310s_defconfig|  1 +
 configs/openrd_base_defconfig|  1 +
 configs/openrd_client_defconfig  |  1 +
 configs/openrd_ultimate_defconfig|  1 +
 configs/origen_defconfig |  1 +
 configs/pogo_e02_defconfig   |  1 +
 configs/portl2_defconfig |  1 +
 configs/sheevaplug_defconfig |  1 +
 configs/stv0991_defconfig|  1 +
 configs/woodburn_defconfig   |  1 +
 configs/woodburn_sd_defconfig|  1 +
 configs/work_92105_defconfig |  2 ++
 configs/xilinx_versal_mini_defconfig |  1 +
 configs/xilinx_versal_mini_emmc0_defconfig   |  1 +
 configs/xilinx_versal_mini_emmc1_defconfig   |  1 +
 configs/xilinx_zynqmp_mini_defconfig |  1 +
 configs/xilinx_zynqmp_mini_emmc0_defconfig   |  1 +
 configs/xilinx_zynqmp_mini_emmc1_defconfig   |  1 +
 configs/xilinx_zynqmp_mini_nand_defconfig|  1 +
 configs/xilinx_zynqmp_mini_qspi_defconfig|  1 +
 configs/zynq_cse_nand_defconfig  |  2 ++
 configs/zynq_cse_nor_defconfig   |  2 ++
 configs/zynq_cse_qspi_defconfig  |  2 ++
 include/configs/armadillo-800eva.h   |  1 -
 include/configs/aspeed-common.h  |  3 ---
 include/configs/bcm23550_w1d.h   |  2 --
 include/configs/colibri_pxa270.h |  3 ---
 include/configs/devkit3250.h |  2 --
 include/configs/flea3.h  |  2 --
 include/configs/gplugd.h

  1   2   >