]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/blame - arch/powerpc/kernel/setup.h
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152
[mirror_ubuntu-focal-kernel.git] / arch / powerpc / kernel / setup.h
CommitLineData
2874c5fd 1/* SPDX-License-Identifier: GPL-2.0-or-later */
b1923caa
BH
2/*
3 * Prototypes for functions that are shared between setup_(32|64|common).c
4 *
5 * Copyright 2016 Michael Ellerman, IBM Corporation.
b1923caa
BH
6 */
7
8#ifndef __ARCH_POWERPC_KERNEL_SETUP_H
9#define __ARCH_POWERPC_KERNEL_SETUP_H
10
11void initialize_cache_info(void);
12void irqstack_early_init(void);
13
14#ifdef CONFIG_PPC32
15void setup_power_save(void);
16#else
17static inline void setup_power_save(void) { };
18#endif
19
20#if defined(CONFIG_PPC64) && defined(CONFIG_SMP)
21void check_smt_enabled(void);
22#else
23static inline void check_smt_enabled(void) { };
24#endif
25
26#if defined(CONFIG_PPC_BOOK3E) && defined(CONFIG_SMP)
27void setup_tlb_core_data(void);
28#else
29static inline void setup_tlb_core_data(void) { };
30#endif
31
32#if defined(CONFIG_PPC_BOOK3E) || defined(CONFIG_BOOKE) || defined(CONFIG_40x)
33void exc_lvl_early_init(void);
34#else
35static inline void exc_lvl_early_init(void) { };
36#endif
37
38#ifdef CONFIG_PPC64
39void emergency_stack_init(void);
40#else
41static inline void emergency_stack_init(void) { };
42#endif
43
1af19331
NP
44#ifdef CONFIG_PPC64
45u64 ppc64_bolted_size(void);
c0abd0c7
NP
46
47/* Default SPR values from firmware/kexec */
48extern unsigned long spr_default_dscr;
1af19331
NP
49#endif
50
b1923caa
BH
51/*
52 * Having this in kvm_ppc.h makes include dependencies too
53 * tricky to solve for setup-common.c so have it here.
54 */
55#ifdef CONFIG_KVM_BOOK3S_HV_POSSIBLE
56void kvm_cma_reserve(void);
57#else
58static inline void kvm_cma_reserve(void) { };
59#endif
60
bd13ac95
MM
61#ifdef CONFIG_TAU
62u32 cpu_temp(unsigned long cpu);
63u32 cpu_temp_both(unsigned long cpu);
64u32 tau_interrupts(unsigned long cpu);
65#endif /* CONFIG_TAU */
66
b1923caa 67#endif /* __ARCH_POWERPC_KERNEL_SETUP_H */