ltp-testsuite fails to build with AArch64

Bug #1236027 reported by Thomas Petazzoni on 2013-10-06
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Linaro AArch64 cross-distro work

Bug Description

The ltp-testsuite, version 20130904 fails to build on Aarch64 with the latest Linaro 2013.08 toolchain:

/home/thomas/projets/buildroot/output/host/usr/bin/aarch64-linux-gnu-gcc -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -pipe -Os -g -O2 -fno-strict-aliasing -pipe -Wall -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FORTIFY_SOURCE=2 -I/home/thomas/projets/buildroot/output/build/ltp-testsuite-20130904/testcases/kernel/include -I../../../../include -I../../../../include -L../../../../lib cacheflush01.c -lltp -o cacheflush01
cacheflush01.c:52:26: fatal error: asm/cachectl.h: Aucun fichier ou dossier de ce type
 #include <asm/cachectl.h>

This is caused by the following bit of code in ltp-testsuite:

#if __NR_cacheflush != __LTP__NR_INVALID_SYSCALL
#include <asm/cachectl.h>
#ifndef ICACHE
#define ICACHE (1<<0) /* flush instruction cache */
#ifndef DCACHE
#define DCACHE (1<<1) /* writeback and flush data cache */
#ifndef BCACHE
#define BCACHE (ICACHE|DCACHE) /* flush both caches */

Riku Voipio (riku-voipio) wrote :

We had a fix for this against the previous ltp version, but seems I forgot to send the patch to ltp mailing list.

Changed in linaro-aarch64:
status: New → Triaged
Riku Voipio (riku-voipio) wrote :
Changed in linaro-aarch64:
status: Triaged → In Progress
Riku Voipio (riku-voipio) wrote :

Aarch64 build fails with:

cacheflush01.c:52:26: fatal error: asm/cachectl.h: No such file or directory
 #include <asm/cachectl.h>

This is caused by bogus definitions of cacheflush and set_tls, which are
private 32bit ARM system calls. These should not be used on native
Aarch64 binaries. If they need to be tested, it is better done using ltp
compiled for 32bit ARM.

Riku Voipio (riku-voipio) wrote :
Changed in linaro-aarch64:
importance: Undecided → Medium
status: In Progress → Fix Committed
Riku Voipio (riku-voipio) wrote :

Released again in 20140115

Changed in linaro-aarch64:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers