Skip to content

Fix for kernel 4.2: don't use 64 bits syscalls/types #6

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: hexagon
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 1 addition & 21 deletions arch/hexagon/bits/syscall.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -276,26 +276,6 @@
#define __NR_pkey_alloc 289
#define __NR_pkey_free 290
#define __NR_statx 291
#define __NR_clock_gettime64 403
#define __NR_clock_settime64 404
#define __NR_clock_adjtime64 405
#define __NR_clock_getres_time64 406
#define __NR_clock_nanosleep_time64 407
#define __NR_timer_gettime64 408
#define __NR_timer_settime64 409
#define __NR_timerfd_gettime64 410
#define __NR_timerfd_settime64 411
#define __NR_utimensat_time64 412
#define __NR_pselect6_time64 413
#define __NR_ppoll_time64 414
#define __NR_io_pgetevents_time64 416
#define __NR_recvmmsg_time64 417
#define __NR_mq_timedsend_time64 418
#define __NR_mq_timedreceive_time64 419
#define __NR_semtimedop_time64 420
#define __NR_rt_sigtimedwait_time64 421
#define __NR_futex_time64 422
#define __NR_sched_rr_get_interval_time64 423
#define __NR_pidfd_send_signal 424
#define __NR_io_uring_setup 425
#define __NR_io_uring_enter 426
Expand All @@ -310,9 +290,9 @@
#define __NR_close_range 436
#define __NR_openat2 437
#define __NR_pidfd_getfd 438
#define __NR_faccessat2 439
#define __NR_process_madvise 440
#define __NR_syscalls (__NR_process_madvise+1)
#define __NR_faccessat2 __NR_faccessat
#define __NR_newfstatat __NR_fstatat
#define __NR_fcntl64 __NR_fcntl
#define __NR_statfs64 __NR_statfs
Expand Down
4 changes: 2 additions & 2 deletions include/alltypes.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ TYPEDEF _Addr ssize_t;
TYPEDEF _Addr intptr_t;
TYPEDEF _Addr regoff_t;
TYPEDEF _Reg register_t;
TYPEDEF _Int64 time_t;
TYPEDEF _Int64 suseconds_t;
TYPEDEF long time_t;
TYPEDEF long suseconds_t;

TYPEDEF signed char int8_t;
TYPEDEF signed short int16_t;
Expand Down
4 changes: 2 additions & 2 deletions include/endian.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ static __inline uint16_t __bswap16(uint16_t __x)

static __inline uint32_t __bswap32(uint32_t __x)
{
return __x>>24 | __x>>8&0xff00 | __x<<8&0xff0000 | __x<<24;
return __x>>24 | ((__x>>8)&0xff00) | ((__x<<8)&0xff0000) | __x<<24;
}

static __inline uint64_t __bswap64(uint64_t __x)
{
return __bswap32(__x)+0ULL<<32 | __bswap32(__x>>32);
return (__bswap32(__x)+0ULL)<<32 | __bswap32(__x>>32);
}

#if __BYTE_ORDER == __LITTLE_ENDIAN
Expand Down