Porting U-Boot to a QCA9531 board?

Daniel Schwierzeck daniel.schwierzeck at gmail.com
Mon Nov 30 20:01:34 CET 2020


Am Mittwoch, den 18.11.2020, 17:54 +0000 schrieb Richard Thanki:
> Hi Heinrich
> 
> > On 18 Nov 2020, at 17:27, Heinrich Schuchardt <xypron.debian at gmx.de> wrote:
> > 
> > 
> > The driver will not be compiled because your config does not select
> > CONFIG_AG7XXX.
> 
> So clear when you point it out. I’ll modify this, and retest, thank you.
> 
> > > - With OpenWrt 18.06 (Kernel 4.4 - ar71xx mach target) and 19.07 (kernel 4.14 -
> > >  ath79 dts target) the boot process doesn't complete and stalls at [link]. With
> > >  OpenWrt Master (5.4) the boot process completes but the system displays the
> > >  following issues: -- Within OpenWrt the watchdog timer (usually on GPIO 2)
> > >  does not respond to writes on sysfs and therefore the device reboots every 4
> > >  minutes -- The second USB hub on the board is not detected by OpenWrt during
> > >  boot and therefore some devices do not come up on the operating system such as
> > >  the modem.
> > 
> > These seem to be questions about Linux configuration, not U-Boot.
> 
> Sorry, I think we phrased this badly. We only get these issues when using mainline U-Boot 
> and not a) the manufacturer default bootloader or b) the Pepe2K mod - both of which work 
> perfectly with our test images. In each case we’re using the same OpenWrt OS images 
> we’ve built ourselves between the tests with these different botloaders.
> 
> I guess the deeper understanding we’re trying to get to is the proper relationship between 
> bootloader and Linux:
> 
> - Why would the very same OpenWrt image be able to find and use the USB hub or make 
> use of GPIO 2 using these other two U-Boot variants but not mainline? 
> - Does this point to us not performing important set-up steps in U-Boot or does our problem
>   lie in our OpenWrt setup? (If the latter, why do these other U-Boots work properly?)
> - Are we stumbling into a common beginners’ problem?
> 
> 

Usually this means the Linux driver does not properly setup the
hardware and relies to much on register reset values or relies on the
bootloader to do some setup. At least the ladder should be avoided. A
Linux driver must work independently of the bootloader.

You could compare driver code and device-tree between mainline U-Boot
and pepe2k mod to find differences in HW init. If you find any, patch
mainline U-Boot first for testing. If the patch works, check if the
updated HW init code should rather be added to the according Linux
driver. Otherwise send the patch to the mailing list along with your
board support patch for review.

Maybe it's just as simple as some missing GPIO/pinmux settings, so you
should check that at first.

-- 
- Daniel



More information about the U-Boot mailing list