]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/blame - include/xfs.h
xfs: automatic dfops buffer relogging
[thirdparty/xfsprogs-dev.git] / include / xfs.h
CommitLineData
959ef981 1// SPDX-License-Identifier: LGPL-2.1
1bdd986b
NS
2/*
3 * Copyright (c) 2005 Silicon Graphics, Inc. All Rights Reserved.
1bdd986b
NS
4 */
5#ifndef __XFS_H__
6#define __XFS_H__
7
dcabd4e7
CH
8#if defined(__linux__)
9#include <xfs/linux.h>
10#elif defined(__FreeBSD__)
11#include <xfs/freebsd.h>
12#elif defined(__FreeBSD_kernel__)
13#include <xfs/gnukfreebsd.h>
14#elif defined(__APPLE__)
15#include <xfs/darwin.h>
dcabd4e7
CH
16#else
17# error unknown platform... have fun porting!
18#endif
19
7fda99a0
FJ
20/*
21 * make sure that any user of the xfs headers has a 64bit off_t type
22 */
23extern int xfs_assert_largefile[sizeof(off_t)-8];
24
dcabd4e7
CH
25/*
26 * sparse kernel source annotations
27 */
28#ifndef __user
29#define __user
30#endif
31
34f7aca6
CH
32/*
33 * kernel struct packing shortcut
34 */
35#ifndef __packed
36#define __packed __attribute__((packed))
37#endif
38
fc60b66d
ES
39#ifndef BUILD_BUG_ON
40#define BUILD_BUG_ON(condition) ((void)sizeof(char[1 - 2*!!(condition)]))
41#endif
42
f8d94331
CH
43#include <xfs/xfs_types.h>
44#include <xfs/xfs_fs.h>
1bdd986b
NS
45
46#endif /* __XFS_H__ */