Yup, that's broken not only on s390, but on every arch with alignof(u64) == 8
in 32 bits mode.
The assumption was that for cases like the above, you simply wouldn't wire
the compat_ version. That is true for epoll_wait and epoll_ctl, where the
only need for compat was the "struct epoll_event". But that's not true for
epoll_pwait, since this one needs to be wired because of the sigset_t.
On top of sigset_t, epoll_pwait may need "struct epoll_event" translation.
Now, that *really* sux because two versions of compat_epoll_pwait are
needed, once that does sigset_t translation only, and one that does
sigset_t + "struct epoll_event".
i386 does not, for example ;)
No, it won't work. Unless there is (or we define) a per-arch macro that
tells us how the 32 bits mode align an u64, I'm afraid we can't do any
smart tricks and we need to have the double compat_epoll_pwait.
- Davide
-