aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2024-01-08 18:31:27 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2024-01-08 18:31:27 -0800
commit669d089a7fe1eacf4e86160297f32c678ee71ec5 (patch)
tree967f2218e5e78af065ae57e5731801bd3a152172
parentMerge tag 'locking-core-2024-01-08' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip (diff)
parentobjtool: Fix calloc call for new -Walloc-size (diff)
downloadwireguard-linux-669d089a7fe1eacf4e86160297f32c678ee71ec5.tar.xz
wireguard-linux-669d089a7fe1eacf4e86160297f32c678ee71ec5.zip
Merge tag 'objtool-core-2024-01-08' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull objtool fixlet from Ingo Molnar: "Address a GCC-14 warning: there's no real bug, but indeed the calloc order doesn't match the prototype. (Side note: we should really add zalloc() for such cases)" * tag 'objtool-core-2024-01-08' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: objtool: Fix calloc call for new -Walloc-size
-rw-r--r--tools/objtool/check.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/objtool/check.c b/tools/objtool/check.c
index e94756e09ca9..548ec3cd7c00 100644
--- a/tools/objtool/check.c
+++ b/tools/objtool/check.c
@@ -291,7 +291,7 @@ static void init_insn_state(struct objtool_file *file, struct insn_state *state,
static struct cfi_state *cfi_alloc(void)
{
- struct cfi_state *cfi = calloc(sizeof(struct cfi_state), 1);
+ struct cfi_state *cfi = calloc(1, sizeof(struct cfi_state));
if (!cfi) {
WARN("calloc failed");
exit(1);