(root)/
strace-6.5/
tests-m32/
ioperm.c
       1  /*
       2   * Copyright (c) 2016-2019 The strace developers.
       3   * All rights reserved.
       4   *
       5   * SPDX-License-Identifier: GPL-2.0-or-later
       6   */
       7  
       8  #include "tests.h"
       9  #include "scno.h"
      10  
      11  #ifdef __NR_ioperm
      12  
      13  # include <stdio.h>
      14  # include <unistd.h>
      15  
      16  int
      17  main(void)
      18  {
      19  	const unsigned long port = (unsigned long) 0xdeafbeefffffffffULL;
      20  
      21  	long rc = syscall(__NR_ioperm, port, 1, 0);
      22  	printf("ioperm(%#lx, %#lx, %d) = %ld %s (%m)\n",
      23  	       port, 1UL, 0, rc, errno2name());
      24  
      25  	puts("+++ exited with 0 +++");
      26  	return 0;
      27  }
      28  
      29  #else
      30  
      31  SKIP_MAIN_UNDEFINED("__NR_ioperm")
      32  
      33  #endif