Re: [U-Boot] instruction "xchgb" for x86_64

Hi,
(James please can you use plain-text email for the mailing list?)
OK. Thanks Simon for pointing out this. I am using outlook, so most likely will have "newline" difference. Hope can find a way out for this.
For chromebook_link64 I get:
output: '/usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/arch/x86/include/asm/byteorder.h: Assembler messages: /usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/arch/x86/include/asm/byteorder.h:22: Error: register type mismatch for `xchg' make[2]: *** [/usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/scripts/Makefile.build:278: net/tftp.o] Error 1 make[2]: *** Waiting for unfinished jobs.... /usr/local/google/home/sjg/cosarm/src/third_party/u-boot/files/net/net.c: In function 'net_process_received_packet': /usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/net/net.c:1324:1: error: extended registers have no high halves } ^ /usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/arch/x86/include/asm/byteorder.h: Assembler messages: /usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/arch/x86/include/asm/byteorder.h:22: Error: register type mismatch for `xchg' /usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/arch/x86/include/asm/byteorder.h:22: Error: register type mismatch for `xchg' /usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/arch/x86/include/asm/byteorder.h:22: Error: register type mismatch for `xchg' make[2]: *** [/usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/scripts/Makefile.build:278: net/net.o] Error 1 make[1]: *** [/usr/local/google/home/sjg/cosarm/src/third_party/u- boot/files/Makefile:1588: net] Error 2 make[1]: *** Waiting for unfinished jobs.... make: *** [Makefile:148: sub-make] Error 2
Perhaps there is another way to fix this?
I tested two toolchains: 1. With gcc version 7.3-win32 20180312 (the MinGW-w64 cross compiling), it can assemble the xchgb without error. 2. With gcc version 7.3.0 (Ubuntu 7.3.0-27ubuntu1~18.04), it uses /usr/include/x86_64-linux-gnu/asm/byteorder.h, (not the one in uboot), and that file is only to include the <little_endian.h> file
As the assembler you use reports error for xchgb (no matter what's the cause), we may use ONLY the C version of implementation and remove the assembly version and relevant CONFIG_IS_ENABLED checking (if performance is not critical here)?
How do you think, Simon and Bin?
Best regards James Wang Jinmin
participants (1)
-
James Wang