162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
262306a36Sopenharmony_ci#ifndef FADVISE_H_INCLUDED
362306a36Sopenharmony_ci#define FADVISE_H_INCLUDED
462306a36Sopenharmony_ci
562306a36Sopenharmony_ci#define POSIX_FADV_NORMAL	0 /* No further special treatment.  */
662306a36Sopenharmony_ci#define POSIX_FADV_RANDOM	1 /* Expect random page references.  */
762306a36Sopenharmony_ci#define POSIX_FADV_SEQUENTIAL	2 /* Expect sequential page references.  */
862306a36Sopenharmony_ci#define POSIX_FADV_WILLNEED	3 /* Will need these pages.  */
962306a36Sopenharmony_ci
1062306a36Sopenharmony_ci/*
1162306a36Sopenharmony_ci * The advise values for POSIX_FADV_DONTNEED and POSIX_ADV_NOREUSE
1262306a36Sopenharmony_ci * for s390-64 differ from the values for the rest of the world.
1362306a36Sopenharmony_ci */
1462306a36Sopenharmony_ci#if defined(__s390x__)
1562306a36Sopenharmony_ci#define POSIX_FADV_DONTNEED	6 /* Don't need these pages.  */
1662306a36Sopenharmony_ci#define POSIX_FADV_NOREUSE	7 /* Data will be accessed once.  */
1762306a36Sopenharmony_ci#else
1862306a36Sopenharmony_ci#define POSIX_FADV_DONTNEED	4 /* Don't need these pages.  */
1962306a36Sopenharmony_ci#define POSIX_FADV_NOREUSE	5 /* Data will be accessed once.  */
2062306a36Sopenharmony_ci#endif
2162306a36Sopenharmony_ci
2262306a36Sopenharmony_ci#endif	/* FADVISE_H_INCLUDED */
23