Merge branch 'for-next/asm-const' into for-next/core

* for-next/asm-const:
  arm64: alternative: constify alternative_has_feature_* argument
  arm64: jump_label: mark arguments as const to satisfy asm constraints
This commit is contained in:
Will Deacon
2022-12-06 10:42:33 +00:00
2 changed files with 6 additions and 6 deletions

View File

@@ -224,7 +224,7 @@ alternative_endif
#include <linux/types.h>
static __always_inline bool
alternative_has_feature_likely(unsigned long feature)
alternative_has_feature_likely(const unsigned long feature)
{
compiletime_assert(feature < ARM64_NCAPS,
"feature must be < ARM64_NCAPS");
@@ -242,7 +242,7 @@ alternative_has_feature_likely(unsigned long feature)
}
static __always_inline bool
alternative_has_feature_unlikely(unsigned long feature)
alternative_has_feature_unlikely(const unsigned long feature)
{
compiletime_assert(feature < ARM64_NCAPS,
"feature must be < ARM64_NCAPS");

View File

@@ -15,8 +15,8 @@
#define JUMP_LABEL_NOP_SIZE AARCH64_INSN_SIZE
static __always_inline bool arch_static_branch(struct static_key *key,
bool branch)
static __always_inline bool arch_static_branch(struct static_key * const key,
const bool branch)
{
asm_volatile_goto(
"1: nop \n\t"
@@ -32,8 +32,8 @@ static __always_inline bool arch_static_branch(struct static_key *key,
return true;
}
static __always_inline bool arch_static_branch_jump(struct static_key *key,
bool branch)
static __always_inline bool arch_static_branch_jump(struct static_key * const key,
const bool branch)
{
asm_volatile_goto(
"1: b %l[l_yes] \n\t"