ppc64: fix struct stat
authorAurelien Jarno <aurelien@aurel32.net>
Sat, 25 Apr 2015 12:16:16 +0000 (14:16 +0200)
committerRaspbian forward porter <root@raspbian.org>
Tue, 17 May 2016 23:45:58 +0000 (23:45 +0000)
commit92d456e6c8d8fabc2a7c27aef53a41f596664133
tree777637a9036b30b17f8ddd3d21ad217181ac09b9
parent2c9f97112861912082baeb3390b787575d3a8348
ppc64: fix struct stat

On ppc64 the struct stat defined by klibc matches the kernel one.
However it contains implicit padding before the st_rdev field due to the
64-bit alignement. For internal reasons, klibc defines st_rdev as a pair
of 32-bit values (using the __stdev64 macro). They only need to be
32-bit aligned and as a consequence st->st_rdev is incorrectly defined.

The solution is to add an explicit padding in the structure. This fixes
the resume binary on ppc64 BE and LE, and probably other things.

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Gbp-Pq: Name klibc-ppc64-fix-struct-stat.patch
usr/include/arch/ppc64/klibc/archstat.h