mirror of
https://github.com/rwinkhart/sys.git
synced 2026-09-05 08:37:31 -04:00
unix: fix EpollEvent padding on mips64{,le}
Like on other 64-bit GOARCHes, EpollEvent needs padding before Fd for mips64 and mips64le. Change-Id: I934368ba22ef7bf3a25949649613c2a03928bf83 Reviewed-on: https://go-review.googlesource.com/c/sys/+/207278 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
committed by
Tobias Klauser
parent
4c7a9d0fe0
commit
52ab431487
+2
-1
@@ -283,7 +283,8 @@ struct my_epoll_event {
|
|||||||
// padding is not specified in linux/eventpoll.h but added to conform to the
|
// padding is not specified in linux/eventpoll.h but added to conform to the
|
||||||
// alignment requirements of EABI
|
// alignment requirements of EABI
|
||||||
int32_t padFd;
|
int32_t padFd;
|
||||||
#elif defined(__powerpc64__) || defined(__s390x__) || defined(__sparc__) || defined(__riscv)
|
#elif defined(__powerpc64__) || defined(__s390x__) || defined(__sparc__) || defined(__riscv) \
|
||||||
|
|| (defined(__mips__) && _MIPS_SIM == _MIPS_SIM_ABI64)
|
||||||
int32_t _padFd;
|
int32_t _padFd;
|
||||||
#endif
|
#endif
|
||||||
int32_t fd;
|
int32_t fd;
|
||||||
|
|||||||
@@ -783,6 +783,7 @@ type Ustat_t struct {
|
|||||||
|
|
||||||
type EpollEvent struct {
|
type EpollEvent struct {
|
||||||
Events uint32
|
Events uint32
|
||||||
|
_ int32
|
||||||
Fd int32
|
Fd int32
|
||||||
Pad int32
|
Pad int32
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -783,6 +783,7 @@ type Ustat_t struct {
|
|||||||
|
|
||||||
type EpollEvent struct {
|
type EpollEvent struct {
|
||||||
Events uint32
|
Events uint32
|
||||||
|
_ int32
|
||||||
Fd int32
|
Fd int32
|
||||||
Pad int32
|
Pad int32
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user