Forward System call macros for Linux

Source: Internet
Author: User

The following macros have been defined in Linux/include/linux/syscalls.h:

Copy Code
#define SYSCALL_DEFINE1 (name, ...) Syscall_definex (1, _# #name, __va_args__)

#define SYSCALL_DEFINE2 (name, ...) Syscall_definex (2, _# #name, __va_args__)

#define SYSCALL_DEFINE3 (name, ...) Syscall_definex (3, _# #name, __va_args__)

#define SYSCALL_DEFINE4 (name, ...) Syscall_definex (4, _# #name, __va_args__)

#define SYSCALL_DEFINE5 (name, ...) Syscall_definex (5, _# #name, __va_args__)

#define SYSCALL_DEFINE6 (name, ...) Syscall_definex (6, _# #name, __va_args__)
Copy Code

And also:

Copy Code
#define SYSCALL_DEFINEX (x, sname, ...) \

__syscall_definex (x, sname, __va_args__)

#define __SYSCALL_DEFINEX (x, Name, ...) \

Asmlinkage long sys# #name (__sc_decl# #x (__va_args__)); \

Static inline long sysc# #name (__sc_decl# #x (__va_args__)); \

Asmlinkage long sys# #name (__sc_long# #x (__va_args__)) \

{                                                      \

__sc_test# #x (__va_args__); \

Return (long) sysc# #name (__sc_cast# #x (__va_args__)); \

}                                                      \

Syscall_alias (sys# #name, sys# #name); \

Static inline long sysc# #name (__sc_decl# #x (__va_args__))
Copy Code

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.