Bug 1624751 - Reboot loop on Orange Pi PC
Summary: Reboot loop on Orange Pi PC
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: binutils
Version: 29
Hardware: armv7hl
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Nick Clifton
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Keywords:
Depends On:
Blocks: ARMTracker
TreeView+ depends on / blocked
 
Reported: 2018-09-03 08:13 UTC by Alessio
Modified: 2018-09-12 13:10 UTC (History)
22 users (show)

(edit)
Cause: 
  A change to linker meant that configurable constants
  such as the pagesize were evaluated after the parsing
  of linker scripts.  This in turn meant that if a linker
  script referred to one of these constants, it could use
  the wrong value.

Consequence: 
  Packages that use linker scripts that refer to these
  constants could end up using the wrong values, which
  could result in failure of the package to execute 
  properly.

Fix: 
  Delay the evaluation of expressions in linker scripts
  until after the configurable constants have been 
  assigned their values.

Result: 
  Packages no longer break.
Clone Of:
(edit)
Last Closed: 2018-09-11 12:44:01 UTC


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Sourceware 23571 None None None 2018-09-03 20:05 UTC

Description Alessio 2018-09-03 08:13:59 UTC
Booting Fedora-Minimal-armhfp-29-20180901.n.0 on an Orange Pi PC, the system continuosly reboot.

This is a snippet of what appears on the serial console.


Retrieving file: /extlinux/extlinux.conf
537 bytes read in 8 ms (65.4 KiB/s)
Ignoring unknown command: ui
Ignoring malformed menu command:  autoboot
Ignoring malformed menu command:  hidden
Ignoring unknown command: totaltimeout
Fedora-Server-armhfp-29-20180901.n.0 Boot Options.
1:	Fedora-Server-armhfp-29-20180901.n.0 (4.18.5-300.fc29.armv7hl)
Enter choice: 1:	Fedora-Server-armhfp-29-20180901.n.0 (4.18.5-300.fc29.armv7hl)
Retrieving file: /initramfs-4.18.5-300.fc29.armv7hl.img
56356993 bytes read in 2544 ms (21.1 MiB/s)
Retrieving file: /vmlinuz-4.18.5-300.fc29.armv7hl
7004672 bytes read in 321 ms (20.8 MiB/s)
append: ro root=UUID=0cf502cf-f6aa-4d7d-9357-9f4d0b1fbaa0 
Retrieving file: /dtb-4.18.5-300.fc29.armv7hl/sun8i-h3-orangepi-pc.dtb
19096 bytes read in 242 ms (76.2 KiB/s)
## Flattened Device Tree blob at 43000000
   Booting using the fdt blob at 0x43000000
EHCI failed to shut down host controller.
EHCI failed to shut down host controller.
EHCI failed to shut down host controller.
EHCI failed to shut down host controller.
   Loading Ramdisk to 46a40000, end 49fff081 ... OK
   Loading Device Tree to 46a38000, end 46a3fa97 ... OK

Starting kernel ...

data abort
pc : [<7dfab90c>]	   lr : [<7df7915f>]
reloc pc : [<4a03390c>]	   lr : [<4a00115f>]
sp : 79f509f8  ip : 00000010	 fp : 79fc01f0
r10: 79f50b08  r9 : 79f57ed8	 r8 : 00000400
r7 : 00000000  r6 : 42000000	 r5 : 46a38000  r4 : 00000000
r3 : 46a38000  r2 : 46a38000	 r1 : 00000000  r0 : 00000000
Flags: nZCv  IRQs off  FIQs off  Mode UK6_32
Code: e12fff1e e52de008 fa000001 e3a00000 (e49df008) 
Resetting CPU ...

resetting ...

U-Boot SPL 2018.09-rc2 (Aug 14 2018 - 18:17:47 +0000)

Comment 1 Peter Robinson 2018-09-03 20:04:02 UTC
It's not a kernel issue but actually a U-Boot issue caused by a binutils issue now fixed upstream, we just need to rebuild once the fix lands in Fedora.

https://lists.denx.de/pipermail/u-boot/2018-September/339967.html

https://sourceware.org/bugzilla/show_bug.cgi?id=23571

Comment 2 Peter Robinson 2018-09-03 20:04:44 UTC
It's not a kernel issue but actually a U-Boot issue caused by a binutils issue now fixed upstream, we just need to rebuild once the fix lands in Fedora.

https://lists.denx.de/pipermail/u-boot/2018-September/339967.html

https://sourceware.org/bugzilla/show_bug.cgi?id=23571

Comment 3 Nick Clifton 2018-09-04 12:01:01 UTC
I have added the patch to the binutils sources and built new rpms.  Please try:

  binutils-2.31.1-13.fc29
  binutils-2.31.1-13.fc30

It should also be noted that this problem can be avoided in the U-Boot linker
script if the align expression is put on the left of the colon.  Like this:

        .__secure_start
  #ifndef CONFIG_ARMV7_SECURE_BASE
                ALIGN(CONSTANT(COMMONPAGESIZE))
  #endif
        : {
                KEEP(*(.__secure_start))
        }

This has the advantage that the solution will work with older versions of the
binutils package.

Comment 4 Peter Robinson 2018-09-04 12:33:08 UTC
>   binutils-2.31.1-13.fc30

Tried this one and it works as expected and fixes the problem for me on a u-boot scratch build, will push a proper build shortly.
 
> It should also be noted that this problem can be avoided in the U-Boot linker
> script if the align expression is put on the left of the colon.  Like this:
> 
>         .__secure_start
>   #ifndef CONFIG_ARMV7_SECURE_BASE
>                 ALIGN(CONSTANT(COMMONPAGESIZE))
>   #endif
>         : {
>                 KEEP(*(.__secure_start))
>         }
> 
> This has the advantage that the solution will work with older versions of the
> binutils package.

Reported that upstream for the maintainer of the affected devices to deal with. Thanks a lot nick, this is much appreciated.

Comment 5 Fedora Update System 2018-09-05 22:08:53 UTC
arm-trusted-firmware-1.5-4.20180830.fc29 bcm283x-firmware-20180829-3.ec3f856.fc29 uboot-tools-2018.09-0.4.rc3.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2018-56bc88dfb2

Comment 6 Fedora Update System 2018-09-07 05:59:42 UTC
arm-trusted-firmware-1.5-4.20180830.fc29, bcm283x-firmware-20180829-3.ec3f856.fc29, uboot-tools-2018.09-0.4.rc3.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-56bc88dfb2

Comment 7 Fedora Update System 2018-09-11 12:44:01 UTC
arm-trusted-firmware-1.5-4.20180830.fc29, bcm283x-firmware-20180829-3.ec3f856.fc29, uboot-tools-2018.09-0.4.rc3.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.

Comment 8 Alessio 2018-09-12 13:10:58 UTC
I can confirm that now the Orange Pi PC boots.
Thanks.


Note You need to log in before you can comment on or make changes to this bug.