File: __fadvise.c

package info (click to toggle)
dietlibc 0.34~cvs20160606-10
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 11,336 kB
  • sloc: ansic: 71,631; asm: 13,006; cpp: 1,860; makefile: 799; sh: 292; perl: 62
file content (16 lines) | stat: -rw-r--r-- 525 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include "syscalls.h"
#define _LINUX_SOURCE
#include <fcntl.h>
#include <unistd.h>

#ifndef __NR_fadvise64
long fadvise64_64(int fd, off64_t offset, off64_t len, int advice)
{
  extern long __parisc_fadvise64_64(int fd, long offset_hi, long offset_lo, long len_hi, long len_lo, int advice);

  return __parisc_fadvise64_64(fd, (long)(offset >> 32), (long)offset, (long)(len >> 32), (long)len, advice);
}

int posix_fadvise(int fd, off64_t offset, off64_t len, int advise)
  __attribute__((__alias__("fadvise64_64")));
#endif