]>
Commit | Line | Data |
---|---|---|
2874c5fd | 1 | // SPDX-License-Identifier: GPL-2.0-or-later |
ac5f89c7 ME |
2 | /* |
3 | * Copyright 2010 Michael Ellerman, IBM Corp. | |
ac5f89c7 ME |
4 | */ |
5 | ||
6 | #include <linux/kernel.h> | |
7 | #include <linux/jump_label.h> | |
8 | #include <asm/code-patching.h> | |
9 | ||
10 | void arch_jump_label_transform(struct jump_entry *entry, | |
11 | enum jump_label_type type) | |
12 | { | |
13 | u32 *addr = (u32 *)(unsigned long)entry->code; | |
14 | ||
76b235c6 | 15 | if (type == JUMP_LABEL_JMP) |
ac5f89c7 ME |
16 | patch_branch(addr, entry->target, 0); |
17 | else | |
18 | patch_instruction(addr, PPC_INST_NOP); | |
19 | } |