• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2015 The Chromium OS Authors. All rights reserved.
3  * Use of this source code is governed by a BSD-style license that can be
4  * found in the LICENSE file.
5  */
6 
7 #include <stdlib.h>
8 #include <unistd.h>
9 
10 #include <sys/prctl.h>
11 
12 #ifndef PR_ALT_SYSCALL
13 #define PR_ALT_SYSCALL 0x43724f53
14 #define PR_ALT_SYSCALL_SET_SYSCALL_TABLE 1
15 #endif
16 
main(void)17 int main(void)
18 {
19 	int ret;
20 
21 	ret = prctl(PR_ALT_SYSCALL, PR_ALT_SYSCALL_SET_SYSCALL_TABLE,
22 		    "read_write_test");
23 	if (ret < 0)
24 		return 1;
25 
26 	return 0;
27 }
28