Skip to contentSkip to conversation

objtool: add bch2_trans_unlocked_error to bcachefs noreturns.

PATCH Applied [email protected] 3 participants 4 messages Dec 20, 2024 – Dec 29, 2024 objtool

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 objtool: add bch2_trans_unlocked_error to bcachefs noreturns.

From: chenchangcheng <[email protected]>

fix the following objtool warning during build time:
fs/bcachefs/btree_trans_commit.o: warning: objtool: bch2_trans_commit_write_locked.isra.0() falls through to next function do_bch2_trans_commit.isra.0() fs/bcachefs/btree_trans_commit.o: warning: objtool: .text: unexpected end of section
......
fs/bcachefs/btree_update.o: warning: objtool: bch2_trans_update_get_key_cache() falls through to next function flush_new_cached_update() fs/bcachefs/btree_update.o: warning: objtool: flush_new_cached_update() falls through to next function bch2_trans_update_by_path()

Fixes fd104e2967b7 ("bcachefs: bch2_trans_verify_not_unlocked()")
---
 tools/objtool/noreturns.h | 1 +
 1 file changed, 1 insertion(+)
tools/objtool/noreturns.h +1 -0
index f37614cc2c1b..b2174894f9f7 100644
@@ -19,6 +19,7 @@ NORETURN(__x64_sys_exit_group)
 NORETURN(arch_cpu_idle_dead)
 NORETURN(bch2_trans_in_restart_error)
 NORETURN(bch2_trans_restart_error)
+NORETURN(bch2_trans_unlocked_error)
 NORETURN(cpu_bringup_and_idle)
 NORETURN(cpu_startup_entry)
 NORETURN(do_exit)

base-commit: 78d4f34e2115b517bcbfe7ec0d018bbbb6f9b0b8

Signature · 1 line
2.25.1
maintainer
#1 lore raw
Quoted 11 lines · On Fri, Dec 20, 2024 at 03:48:47PM +0800, [email protected] wrote:

From: chenchangcheng <[email protected]>

fix the following objtool warning during build time:
fs/bcachefs/btree_trans_commit.o: warning: objtool: bch2_trans_commit_write_locked.isra.0() falls through to next function do_bch2_trans_commit.isra.0() fs/bcachefs/btree_trans_commit.o: warning: objtool: .text: unexpected end of section
......
fs/bcachefs/btree_update.o: warning: objtool: bch2_trans_update_get_key_cache() falls through to next function flush_new_cached_update() fs/bcachefs/btree_update.o: warning: objtool: flush_new_cached_update() falls through to next function bch2_trans_update_by_path()

Fixes fd104e2967b7 ("bcachefs: bch2_trans_verify_not_unlocked()")

Thanks!

merge bot Applied
#2 lore raw
In reply to [email protected]
The following commit has been merged into the objtool/urgent branch of tip:

The following commit has been merged into the objtool/urgent branch of tip:

Commit-ID:     0b56a9cc3fcb4eb12c9f3592a052b8aff2d4a3ee
Gitweb:        https://git.kernel.org/tip/0b56a9cc3fcb4eb12c9f3592a052b8aff2d4a3ee
Author:        chenchangcheng <[email protected]>
AuthorDate:    Fri, 20 Dec 2024 15:48:47 +08:00
Committer:     Peter Zijlstra <[email protected]>
CommitterDate: Fri, 20 Dec 2024 15:31:26 +01:00

objtool: add bch2_trans_unlocked_error to bcachefs noreturns.

fix the following objtool warning during build time:
fs/bcachefs/btree_trans_commit.o: warning: objtool: bch2_trans_commit_write_locked.isra.0() falls through to next function do_bch2_trans_commit.isra.0() fs/bcachefs/btree_trans_commit.o: warning: objtool: .text: unexpected end of section
......
fs/bcachefs/btree_update.o: warning: objtool: bch2_trans_update_get_key_cache() falls through to next function flush_new_cached_update() fs/bcachefs/btree_update.o: warning: objtool: flush_new_cached_update() falls through to next function bch2_trans_update_by_path()

Fixes fd104e2967b7 ("bcachefs: bch2_trans_verify_not_unlocked()")
---
 tools/objtool/noreturns.h | 1 +
 1 file changed, 1 insertion(+)
tools/objtool/noreturns.h +1 -0
index f37614c..b217489 100644
@@ -19,6 +19,7 @@ NORETURN(__x64_sys_exit_group)
 NORETURN(arch_cpu_idle_dead)
 NORETURN(bch2_trans_in_restart_error)
 NORETURN(bch2_trans_restart_error)
+NORETURN(bch2_trans_unlocked_error)
 NORETURN(cpu_bringup_and_idle)
 NORETURN(cpu_startup_entry)
 NORETURN(do_exit)
merge bot Applied
#3 lore raw

[tip: objtool/urgent] objtool: Add bch2_trans_unlocked_error() to bcachefs noreturns

In reply to [email protected]
The following commit has been merged into the objtool/urgent branch of tip:

The following commit has been merged into the objtool/urgent branch of tip:

Commit-ID:     31ad36a271290648e7c2288a03d7b933d20254d6
Gitweb:        https://git.kernel.org/tip/31ad36a271290648e7c2288a03d7b933d20254d6
Author:        chenchangcheng <[email protected]>
AuthorDate:    Fri, 20 Dec 2024 15:48:47 +08:00
Committer:     Ingo Molnar <[email protected]>
CommitterDate: Sun, 29 Dec 2024 09:52:21 +01:00

objtool: Add bch2_trans_unlocked_error() to bcachefs noreturns

Fix the following objtool warning during build time:

fs/bcachefs/btree_trans_commit.o: warning: objtool: bch2_trans_commit_write_locked.isra.0() falls through to next function do_bch2_trans_commit.isra.0() fs/bcachefs/btree_trans_commit.o: warning: objtool: .text: unexpected end of section
......
fs/bcachefs/btree_update.o: warning: objtool: bch2_trans_update_get_key_cache() falls through to next function flush_new_cached_update() fs/bcachefs/btree_update.o: warning: objtool: flush_new_cached_update() falls through to next function bch2_trans_update_by_path()

bch2_trans_unlocked_error() is an Obviously Correct (tm) panic() wrapper, add it to the list of known noreturns.

[ mingo: Improved the changelog ]

Fixes fd104e2967b7 ("bcachefs: bch2_trans_verify_not_unlocked()")
---
 tools/objtool/noreturns.h | 1 +
 1 file changed, 1 insertion(+)
tools/objtool/noreturns.h +1 -0
index f37614c..b217489 100644
@@ -19,6 +19,7 @@ NORETURN(__x64_sys_exit_group)
 NORETURN(arch_cpu_idle_dead)
 NORETURN(bch2_trans_in_restart_error)
 NORETURN(bch2_trans_restart_error)
+NORETURN(bch2_trans_unlocked_error)
 NORETURN(cpu_bringup_and_idle)
 NORETURN(cpu_startup_entry)
 NORETURN(do_exit)