]> git.proxmox.com Git - mirror_qemu.git/blob - include/qemu-common.h
include: move cpu_exec* declarations to cpu-common.h
[mirror_qemu.git] / include / qemu-common.h
1 /*
2 * This file is supposed to be included only by .c files. No header file should
3 * depend on qemu-common.h, as this would easily lead to circular header
4 * dependencies.
5 *
6 * If a header file uses a definition from qemu-common.h, that definition
7 * must be moved to a separate header file, and the header that uses it
8 * must include that header.
9 */
10 #ifndef QEMU_COMMON_H
11 #define QEMU_COMMON_H
12
13 /* Copyright string for -version arguments, About dialogs, etc */
14 #define QEMU_COPYRIGHT "Copyright (c) 2003-2022 " \
15 "Fabrice Bellard and the QEMU Project developers"
16
17 /* Bug reporting information for --help arguments, About dialogs, etc */
18 #define QEMU_HELP_BOTTOM \
19 "See <https://qemu.org/contribute/report-a-bug> for how to report bugs.\n" \
20 "More information on the QEMU project at <https://qemu.org>."
21
22 /* main function, renamed */
23 #if defined(CONFIG_COCOA)
24 int qemu_main(int argc, char **argv, char **envp);
25 #endif
26
27 /**
28 * set_preferred_target_page_bits:
29 * @bits: number of bits needed to represent an address within the page
30 *
31 * Set the preferred target page size (the actual target page
32 * size may be smaller than any given CPU's preference).
33 * Returns true on success, false on failure (which can only happen
34 * if this is called after the system has already finalized its
35 * choice of page size and the requested page size is smaller than that).
36 */
37 bool set_preferred_target_page_bits(int bits);
38
39 /**
40 * finalize_target_page_bits:
41 * Commit the final value set by set_preferred_target_page_bits.
42 */
43 void finalize_target_page_bits(void);
44
45 void qemu_progress_init(int enabled, float min_skip);
46 void qemu_progress_end(void);
47 void qemu_progress_print(float delta, int max);
48 const char *qemu_get_vm_name(void);
49
50 /* OS specific functions */
51 void os_setup_early_signal_handling(void);
52 int os_parse_cmd_args(int index, const char *optarg);
53
54 void page_size_init(void);
55
56 #endif