1 /* SPDX-License-Identifier: LGPL-2.1-or-later */
3 * Copyright (C) 2022 Paul Cercueil <paul@crapouillou.net>
6 #ifndef __LIGHTREC_MEM_H__
7 #define __LIGHTREC_MEM_H__
11 #define CODE_BUFFER_SIZE (8 * 1024 * 1024)
13 extern void *code_buffer;
15 int lightrec_init_mmap(void);
16 void lightrec_free_mmap(void);
18 #else /* if !LIGHTREC */
20 #define lightrec_init_mmap() -1 /* should not be called */
21 #define lightrec_free_mmap()
23 #undef LIGHTREC_CUSTOM_MAP
24 #define LIGHTREC_CUSTOM_MAP 0
28 #endif /* __LIGHTREC_MEM_H__ */