Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lxc
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
lxc
Commits
befb6f0d
Unverified
Commit
befb6f0d
authored
Jul 22, 2020
by
Christian Brauner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
syscalls: add fsopen()
Signed-off-by:
Christian Brauner
<
christian.brauner@ubuntu.com
>
parent
551301ff
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
1 deletion
+31
-1
configure.ac
configure.ac
+1
-1
syscall_numbers.h
src/lxc/syscall_numbers.h
+20
-0
syscall_wrappers.h
src/lxc/syscall_wrappers.h
+10
-0
No files found.
configure.ac
View file @
befb6f0d
...
@@ -622,7 +622,7 @@ AC_CHECK_HEADER([ifaddrs.h],
...
@@ -622,7 +622,7 @@ AC_CHECK_HEADER([ifaddrs.h],
AC_HEADER_MAJOR
AC_HEADER_MAJOR
# Check for some syscalls functions
# Check for some syscalls functions
AC_CHECK_FUNCS([setns pivot_root sethostname unshare rand_r confstr faccessat gettid memfd_create move_mount open_tree execveat clone3])
AC_CHECK_FUNCS([setns pivot_root sethostname unshare rand_r confstr faccessat gettid memfd_create move_mount open_tree execveat clone3
fsopen
])
AC_CHECK_TYPES([struct clone_args], [], [], [[#include <linux/sched.h>]])
AC_CHECK_TYPES([struct clone_args], [], [], [[#include <linux/sched.h>]])
AC_CHECK_MEMBERS([struct clone_args.set_tid],[],[],[[#include <linux/sched.h>]])
AC_CHECK_MEMBERS([struct clone_args.set_tid],[],[],[[#include <linux/sched.h>]])
AC_CHECK_MEMBERS([struct clone_args.cgroup],[],[],[[#include <linux/sched.h>]])
AC_CHECK_MEMBERS([struct clone_args.cgroup],[],[],[[#include <linux/sched.h>]])
...
...
src/lxc/syscall_numbers.h
View file @
befb6f0d
...
@@ -563,4 +563,24 @@
...
@@ -563,4 +563,24 @@
#endif
#endif
#endif
#endif
#ifndef __NR_fsopen
#if defined __alpha__
#define __NR_fsopen 540
#elif defined _MIPS_SIM
#if _MIPS_SIM == _MIPS_SIM_ABI32
/* o32 */
#define __NR_fsopen 4430
#endif
#if _MIPS_SIM == _MIPS_SIM_NABI32
/* n32 */
#define __NR_fsopen 6430
#endif
#if _MIPS_SIM == _MIPS_SIM_ABI64
/* n64 */
#define __NR_fsopen 5430
#endif
#elif defined __ia64__
#define __NR_fsopen (430 + 1024)
#else
#define __NR_fsopen 430
#endif
#endif
#endif
/* __LXC_SYSCALL_NUMBERS_H */
#endif
/* __LXC_SYSCALL_NUMBERS_H */
src/lxc/syscall_wrappers.h
View file @
befb6f0d
...
@@ -161,4 +161,14 @@ static inline int open_tree_lxc(int dfd, const char *filename, unsigned int flag
...
@@ -161,4 +161,14 @@ static inline int open_tree_lxc(int dfd, const char *filename, unsigned int flag
extern
int
open_tree
(
int
dfd
,
const
char
*
filename
,
unsigned
int
flags
);
extern
int
open_tree
(
int
dfd
,
const
char
*
filename
,
unsigned
int
flags
);
#endif
#endif
#ifndef HAVE_FSOPEN
static
inline
int
fsopen_lxc
(
const
char
*
fs_name
,
unsigned
int
flags
)
{
return
syscall
(
__NR_fsopen
,
fs_name
,
flags
);
}
#define fsopen fsopen_lxc
#else
extern
int
fsopen
(
const
char
*
fs_name
,
unsigned
int
flags
);
#endif
#endif
/* __LXC_SYSCALL_WRAPPER_H */
#endif
/* __LXC_SYSCALL_WRAPPER_H */
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment