AIO userspace for sparc 32-bit userspace
The attached patch adds sparc support to libaio. It works with sparc and the 32 bit userland of sparc64.
This is only the userland side, kernel patches are needed, as the system call numbers are duplicated.
To get the base libaio tarball, go to ftp://ftp.kernel.org/pub/linux/kernel/people/bcrl/aio
It passes all test cases, except case 5.t, where it expects an -EFAULT, but sees a -EHOSTDOWN. The message with the kernel patch points towards the problem.
Enjoy!
Dave
src/libaio.h +4 -0
@@ -47,6 +47,10 @@#define PADDED (x, y) x; unsigned y#define PADDEDptr (x, y) x; unsigned y#define PADDEDul (x, y) unsigned long x; unsigned y +#elif defined(__sparc__)/* big endian, 32 bits */ +#define PADDED (x, y) unsigned y; x +#define PADDEDptr (x, y) unsigned y; x +#define PADDEDul (x, y) unsigned y; unsigned long x#elif defined(__ia64__) || defined(__x86_64__)#define PADDED (x, y) x, y#define PADDEDptr (x, y) x
src/syscall.h +2 -0
@@ -10,6 +10,8 @@#include "syscall-x86_64.h" #elif defined(__ia64__)#include "syscall-ia64.h" +#elif defined(__sparc__) +#include "syscall-sparc.h" #else #error "add syscall-arch.h"#endif
src/syscall-sparc.h +104 -0
104 lines not on this page · raw message