AnsweredAssumed Answered

Issue booting 64bit elf file from uboot on t2080 rdb

Question asked by Michael Sawyer on Dec 31, 2018
Latest reply on Jan 11, 2019 by Pavel Chubakov

Questions:

1) Is uboot capable of booting a 64bit elf file on the T2080RDB?

2) Do some of the configuration options need to be changed to successfully load a 64bit elf file on uboot?

3) Is there a version of uboot I can flash on the target to load a 64bit elf binary?

 

Details:

I’m trying to boot a 64bit elf file from uboot on the T2080RDB-PC rev.C board, the version of uboot I am using is:

=> version

 

U-Boot 2016.012.0+ga9b437f (May 15 2016 - 10:38:22 +0800)

powerpc-fslmllib32-linux-gcc (GCC) 4.9.2

GNU ld (GNU Binutils) 2.25

 

And the output of readelf on the header of the file I am trying to load looks like so:

ELF Header:

  Magic:   7f 45 4c 46 02 02 01 00 00 00 00 00 00 00 00 00

  Class:                             ELF64

  Data:                              2's complement, big endian

  Version:                           1 (current)

  OS/ABI:                            UNIX - System V

  ABI Version:                       0

  Type:                              EXEC (Executable file)

  Machine:                           PowerPC64

  Version:                           0x1

  Entry point address:               0x43a00

  Start of program headers:          64 (bytes into file)

  Start of section headers:          748560 (bytes into file)

  Flags:                             0x1

  Size of this header:               64 (bytes)

  Size of program headers:           56 (bytes)

  Number of program headers:         49

 Size of section headers:           64 (bytes)

  Number of section headers:         95

  Section header string table index: 94

 

When I try to boot the application (using tftpboot and then bootelf) I get output like below:

=> tftpboot HelloWorld

Using FM1@DTSEC3 device

TFTP from server 192.168.6.120; our IP address is 192.168.6.230

Filename 'HelloWorld'.

Load address: 0x1000000

Loading: #################################################################

         #################################################################

         ##################

         3.2 MiB/s

done

Bytes transferred = 754640 (b83d0 hex)

=> bootelf

## Starting application at 0x00000000 ...

Bad trap at PC: ffff98e8, SR: 16024900, vector=e00

NIP: FFFF98E8 XER: 00000000 LR: 7FEF0B6C REGS: 7faedbe0 TRAP: 0e00 DAR: 00000000

MSR: 16024900 EE: 0 PR: 1 FP: 0 ME: 0 IR/DR: 00

 

GPR00: 7FF02040 7FAEDCD0 7FAEDEF8 00000000 7FAF4D24 7FAEDB9B 00000020 7FAEDB9C

GPR08: FFFFFFFE 00000020 00000020 7FAEDCD0 44022082 80000000 7FF5FA48 7FAF4D20

GPR16: 7FF5FA38 0000000A 7FAF4D10 00000000 7FAF4D40 00000000 00000000 FFFF98E8

GPR24: 00000000 7FFB029C 00000001 00000000 7FAF4D24 00000000 7FF745C0 00000001

Call backtrace:

7FF02040 7FF1D060 7FEFDDDC 7FEFE59C 7FEFE64C 7FF1BA4C 7FEFBE9C

7FEFEED8 7FF4DCEC 7FEFF2E4 7FEF0F50

Exception in kernel pc ffff98e8 signal 0

 

 

It looks like it trying to start the application at 0x00000000, which really doesn’t seem correct when the start address from the elf header is 0x43a00.

 

Is uboot capable of booting a 64bit elf file?

Do some of the configuration options need to be changed to successfully load a 64bit elf file on uboot?

Is there a version of uboot I can flash on the target to load a 64bit elf binary?

 

Any help would be appreciated. 

 

Thanks,

 

t2080rdb 

64-bit

elf

uboot;

t2080 uboot

Outcomes