mirror of
https://github.com/koverstreet/bcachefs-tools.git
synced 2025-12-09 00:00:17 +03:00
Some checks are pending
build / bcachefs-tools-deb (ubuntu-22.04) (push) Waiting to run
build / bcachefs-tools-deb (ubuntu-24.04) (push) Waiting to run
build / bcachefs-tools-rpm (push) Waiting to run
build / bcachefs-tools-msrv (push) Waiting to run
Nix Flake actions / nix-matrix (push) Waiting to run
Nix Flake actions / ${{ matrix.name }} (${{ matrix.system }}) (push) Blocked by required conditions
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
23 lines
600 B
C
23 lines
600 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#ifndef _LINUX_STATIC_KEY_H
|
|
#define _LINUX_STATIC_KEY_H
|
|
|
|
struct static_key {
|
|
int v;
|
|
};
|
|
|
|
static inline void static_key_enable(struct static_key *key) {}
|
|
static inline void static_key_disable(struct static_key *key) {}
|
|
static inline bool static_key_enabled(struct static_key *key) { return false; }
|
|
|
|
struct static_key_false {
|
|
struct static_key key;
|
|
};
|
|
|
|
#define DEFINE_STATIC_KEY_FALSE(n) struct static_key_false n = {}
|
|
|
|
#define static_branch_unlikely(x) unlikely((x)->key.v)
|
|
#define static_branch_likely(x) likely((x)->key.v)
|
|
|
|
#endif /* _LINUX_STATIC_KEY_H */
|