Drop support for kernels < 4.4 from 'wrapper/page_alloc.h'
[lttng-modules.git] / include / wrapper / page_alloc.h
... / ...
CommitLineData
1/* SPDX-License-Identifier: (GPL-2.0-only or LGPL-2.1-only)
2 *
3 * wrapper/page_alloc.h
4 *
5 * wrapper around get_pfnblock_flags_mask. Using KALLSYMS to get its address
6 * when available, else we need to have a kernel that exports this function to
7 * GPL modules.
8 *
9 * Copyright (C) 2015 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 */
11
12#ifndef _LTTNG_WRAPPER_PAGE_ALLOC_H
13#define _LTTNG_WRAPPER_PAGE_ALLOC_H
14
15#include <linux/mm_types.h>
16
17/*
18 * We need to redefine get_pfnblock_flags_mask to our wrapper, because
19 * the get_pageblock_migratetype() macro uses it.
20 */
21#ifdef CONFIG_KALLSYMS
22
23#define get_pfnblock_flags_mask wrapper_get_pfnblock_flags_mask
24
25int wrapper_get_pfnblock_flags_mask_init(void);
26
27#else
28
29static inline
30int wrapper_get_pfnblock_flags_mask_init(void)
31{
32 return 0;
33}
34
35#endif
36
37#endif /* _LTTNG_WRAPPER_PAGE_ALLOC_H */
This page took 0.022255 seconds and 4 git commands to generate.