mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-03-18 04:54:52 +00:00
tools/nolibc: make sys_mmap() automatically use the right __NR_mmap definition
__NR_mmap2 was used for i386 but it's also needed for other archs such as RISCV32 or ARM. Let's decide to use it based on the __NR_mmap2 definition as it's not defined on other archs. Signed-off-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
This commit is contained in:
parent
8b53e83b08
commit
364702f755
1 changed files with 1 additions and 1 deletions
|
@ -697,7 +697,7 @@ void *sys_mmap(void *addr, size_t length, int prot, int flags, int fd,
|
|||
|
||||
int n;
|
||||
|
||||
#if defined(__i386__)
|
||||
#if defined(__NR_mmap2)
|
||||
n = __NR_mmap2;
|
||||
offset >>= 12;
|
||||
#else
|
||||
|
|
Loading…
Add table
Reference in a new issue