Merge tag 'for-5.4-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave...
[sfrench/cifs-2.6.git] / arch / x86 / include / asm / uv / uv.h
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _ASM_X86_UV_UV_H
3 #define _ASM_X86_UV_UV_H
4
5 #include <asm/tlbflush.h>
6
7 enum uv_system_type {UV_NONE, UV_LEGACY_APIC, UV_X2APIC, UV_NON_UNIQUE_APIC};
8
9 struct cpumask;
10 struct mm_struct;
11
12 #ifdef CONFIG_X86_UV
13 #include <linux/efi.h>
14
15 extern unsigned long uv_systab_phys;
16
17 extern enum uv_system_type get_uv_system_type(void);
18 static inline bool is_early_uv_system(void)
19 {
20         return uv_systab_phys && uv_systab_phys != EFI_INVALID_TABLE_ADDR;
21 }
22 extern int is_uv_system(void);
23 extern int is_uv_hubless(void);
24 extern void uv_cpu_init(void);
25 extern void uv_nmi_init(void);
26 extern void uv_system_init(void);
27 extern const struct cpumask *uv_flush_tlb_others(const struct cpumask *cpumask,
28                                                  const struct flush_tlb_info *info);
29
30 #else   /* X86_UV */
31
32 static inline enum uv_system_type get_uv_system_type(void) { return UV_NONE; }
33 static inline bool is_early_uv_system(void)     { return 0; }
34 static inline int is_uv_system(void)    { return 0; }
35 static inline int is_uv_hubless(void)   { return 0; }
36 static inline void uv_cpu_init(void)    { }
37 static inline void uv_system_init(void) { }
38 static inline const struct cpumask *
39 uv_flush_tlb_others(const struct cpumask *cpumask,
40                     const struct flush_tlb_info *info)
41 { return cpumask; }
42
43 #endif  /* X86_UV */
44
45 #endif  /* _ASM_X86_UV_UV_H */