projects/linux·blob master · refs

16 lines · 323 B

1// SPDX-License-Identifier: GPL-2.0
2/* Data whose value differs between the two builds. */
3
4static const char __modinfo[]
5 __attribute__((section(".modinfo"), used, aligned(1))) = "\0name=vmlinux";
6
7#ifdef PATCHED
8int klp_test_data = 2;
9#else
10int klp_test_data = 1;
11#endif
12
13int target(int x)
14{
15 return x + klp_test_data;
16}