File Index
Files and directories
Sign in
FILE

pi.h

File preview with syntax highlighting.

linux-6.19.14/arch/arm64/kernel/pi/pi.h C
 1// SPDX-License-Identifier: GPL-2.0-only
 2// Copyright 2023 Google LLC
 3// Author: Ard Biesheuvel <ardb@google.com>
 4
 5#include <linux/types.h>
 6
 7#define __prel64_initconst	__section(".init.rodata.prel64")
 8
 9#define PREL64(type, name)	union { type *name; prel64_t name ## _prel; }
10
11#define prel64_pointer(__d)	(typeof(__d))prel64_to_pointer(&__d##_prel)
12
13typedef volatile signed long prel64_t;
14
15static inline void *prel64_to_pointer(const prel64_t *offset)
16{
17	if (!*offset)
18		return NULL;
19	return (void *)offset + *offset;
20}
21
22extern bool dynamic_scs_is_enabled;
23
24extern pgd_t init_idmap_pg_dir[], init_idmap_pg_end[];
25extern pgd_t init_pg_dir[], init_pg_end[];
26
27void init_feature_override(u64 boot_status, const void *fdt, int chosen);
28u64 kaslr_early_init(void *fdt, int chosen);
29void relocate_kernel(u64 offset);
30int scs_patch(const u8 eh_frame[], int size, bool skip_dry_run);
31
32void map_range(phys_addr_t *pte, u64 start, u64 end, phys_addr_t pa,
33	       pgprot_t prot, int level, pte_t *tbl, bool may_use_cont,
34	       u64 va_offset);
35
36asmlinkage void early_map_kernel(u64 boot_status, phys_addr_t fdt);
37
38asmlinkage phys_addr_t create_init_idmap(pgd_t *pgd, ptdesc_t clrmask);
~/ Read-only file preview.