* [PATCH] objtool: Fix false "ignoring unreachables" warning
@ 2025-04-09 22:49 Josh Poimboeuf
2025-04-10 6:14 ` [tip: objtool/urgent] objtool: Fix false-positive " tip-bot2 for Josh Poimboeuf
2025-04-10 21:04 ` tip-bot2 for Josh Poimboeuf
0 siblings, 2 replies; 5+ messages in thread
From: Josh Poimboeuf @ 2025-04-09 22:49 UTC (permalink / raw)
To: x86; +Cc: linux-kernel, Peter Zijlstra, Ingo Molnar, kernel test robot
There's no need to try to automatically disable unreachable warnings if
they've already been manually disabled due to CONFIG_KCOV quirks.
This avoids a spurious warning with a KCOV kernel:
fs/smb/client/cifs_unicode.o: warning: objtool: cifsConvertToUTF16.part.0+0xce5: ignoring unreachables due to jump table quirk
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/r/202504090910.QkvTAR36-lkp@intel.com/
Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
---
tools/objtool/arch/x86/special.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/objtool/arch/x86/special.c b/tools/objtool/arch/x86/special.c
index 403e587676f1..06ca4a2659a4 100644
--- a/tools/objtool/arch/x86/special.c
+++ b/tools/objtool/arch/x86/special.c
@@ -126,7 +126,7 @@ struct reloc *arch_find_switch_table(struct objtool_file *file,
* indicates a rare GCC quirk/bug which can leave dead
* code behind.
*/
- if (reloc_type(text_reloc) == R_X86_64_PC32) {
+ if (!file->ignore_unreachables && reloc_type(text_reloc) == R_X86_64_PC32) {
WARN_INSN(insn, "ignoring unreachables due to jump table quirk");
file->ignore_unreachables = true;
}
--
2.49.0
^ permalink raw reply [flat|nested] 5+ messages in thread* [tip: objtool/urgent] objtool: Fix false-positive "ignoring unreachables" warning
2025-04-09 22:49 [PATCH] objtool: Fix false "ignoring unreachables" warning Josh Poimboeuf
@ 2025-04-10 6:14 ` tip-bot2 for Josh Poimboeuf
2025-04-10 19:13 ` Josh Poimboeuf
2025-04-10 21:04 ` tip-bot2 for Josh Poimboeuf
1 sibling, 1 reply; 5+ messages in thread
From: tip-bot2 for Josh Poimboeuf @ 2025-04-10 6:14 UTC (permalink / raw)
To: linux-tip-commits
Cc: kernel test robot, Josh Poimboeuf, Ingo Molnar, x86, linux-kernel
The following commit has been merged into the objtool/urgent branch of tip:
Commit-ID: 8af6f0fe9c4340ed97f0ba4f3f6cc7bb16558e87
Gitweb: https://git.kernel.org/tip/8af6f0fe9c4340ed97f0ba4f3f6cc7bb16558e87
Author: Josh Poimboeuf <jpoimboe@kernel.org>
AuthorDate: Wed, 09 Apr 2025 15:49:36 -07:00
Committer: Ingo Molnar <mingo@kernel.org>
CommitterDate: Thu, 10 Apr 2025 08:03:05 +02:00
objtool: Fix false-positive "ignoring unreachables" warning
There's no need to try to automatically disable unreachable warnings if
they've already been manually disabled due to CONFIG_KCOV quirks.
This avoids a spurious warning with a KCOV kernel:
fs/smb/client/cifs_unicode.o: warning: objtool: cifsConvertToUTF16.part.0+0xce5: ignoring unreachables due to jump table quirk
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/5eb28eeb6a724b7d945a961cfdcf8d41e6edf3dc.1744238814.git.jpoimboe@kernel.org
Closes: https://lore.kernel.org/r/202504090910.QkvTAR36-lkp@intel.com/
---
tools/objtool/arch/x86/special.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/objtool/arch/x86/special.c b/tools/objtool/arch/x86/special.c
index 403e587..06ca4a2 100644
--- a/tools/objtool/arch/x86/special.c
+++ b/tools/objtool/arch/x86/special.c
@@ -126,7 +126,7 @@ struct reloc *arch_find_switch_table(struct objtool_file *file,
* indicates a rare GCC quirk/bug which can leave dead
* code behind.
*/
- if (reloc_type(text_reloc) == R_X86_64_PC32) {
+ if (!file->ignore_unreachables && reloc_type(text_reloc) == R_X86_64_PC32) {
WARN_INSN(insn, "ignoring unreachables due to jump table quirk");
file->ignore_unreachables = true;
}
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [tip: objtool/urgent] objtool: Fix false-positive "ignoring unreachables" warning
2025-04-10 6:14 ` [tip: objtool/urgent] objtool: Fix false-positive " tip-bot2 for Josh Poimboeuf
@ 2025-04-10 19:13 ` Josh Poimboeuf
2025-04-10 20:55 ` Ingo Molnar
0 siblings, 1 reply; 5+ messages in thread
From: Josh Poimboeuf @ 2025-04-10 19:13 UTC (permalink / raw)
To: tip-bot2 for Josh Poimboeuf
Cc: linux-tip-commits, kernel test robot, Ingo Molnar, x86, linux-kernel
On Thu, Apr 10, 2025 at 06:14:43AM +0000, tip-bot2 for Josh Poimboeuf wrote:
> The following commit has been merged into the objtool/urgent branch of tip:
>
> Commit-ID: 8af6f0fe9c4340ed97f0ba4f3f6cc7bb16558e87
> Gitweb: https://git.kernel.org/tip/8af6f0fe9c4340ed97f0ba4f3f6cc7bb16558e87
> Author: Josh Poimboeuf <jpoimboe@kernel.org>
> AuthorDate: Wed, 09 Apr 2025 15:49:36 -07:00
> Committer: Ingo Molnar <mingo@kernel.org>
> CommitterDate: Thu, 10 Apr 2025 08:03:05 +02:00
>
> objtool: Fix false-positive "ignoring unreachables" warning
>
> There's no need to try to automatically disable unreachable warnings if
> they've already been manually disabled due to CONFIG_KCOV quirks.
>
> This avoids a spurious warning with a KCOV kernel:
>
> fs/smb/client/cifs_unicode.o: warning: objtool: cifsConvertToUTF16.part.0+0xce5: ignoring unreachables due to jump table quirk
>
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
> Signed-off-by: Ingo Molnar <mingo@kernel.org>
> Link: https://lore.kernel.org/r/5eb28eeb6a724b7d945a961cfdcf8d41e6edf3dc.1744238814.git.jpoimboe@kernel.org
>
> Closes: https://lore.kernel.org/r/202504090910.QkvTAR36-lkp@intel.com/
Superfluous newline there.
Also, this probably could use a fixes tag:
Fixes: eeff7ac61526 ("objtool: Warn when disabling unreachable warnings")
Thanks!
--
Josh
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [tip: objtool/urgent] objtool: Fix false-positive "ignoring unreachables" warning
2025-04-10 19:13 ` Josh Poimboeuf
@ 2025-04-10 20:55 ` Ingo Molnar
0 siblings, 0 replies; 5+ messages in thread
From: Ingo Molnar @ 2025-04-10 20:55 UTC (permalink / raw)
To: Josh Poimboeuf
Cc: tip-bot2 for Josh Poimboeuf, linux-tip-commits,
kernel test robot, x86, linux-kernel
* Josh Poimboeuf <jpoimboe@kernel.org> wrote:
> On Thu, Apr 10, 2025 at 06:14:43AM +0000, tip-bot2 for Josh Poimboeuf wrote:
> > The following commit has been merged into the objtool/urgent branch of tip:
> >
> > Commit-ID: 8af6f0fe9c4340ed97f0ba4f3f6cc7bb16558e87
> > Gitweb: https://git.kernel.org/tip/8af6f0fe9c4340ed97f0ba4f3f6cc7bb16558e87
> > Author: Josh Poimboeuf <jpoimboe@kernel.org>
> > AuthorDate: Wed, 09 Apr 2025 15:49:36 -07:00
> > Committer: Ingo Molnar <mingo@kernel.org>
> > CommitterDate: Thu, 10 Apr 2025 08:03:05 +02:00
> >
> > objtool: Fix false-positive "ignoring unreachables" warning
> >
> > There's no need to try to automatically disable unreachable warnings if
> > they've already been manually disabled due to CONFIG_KCOV quirks.
> >
> > This avoids a spurious warning with a KCOV kernel:
> >
> > fs/smb/client/cifs_unicode.o: warning: objtool: cifsConvertToUTF16.part.0+0xce5: ignoring unreachables due to jump table quirk
> >
> > Reported-by: kernel test robot <lkp@intel.com>
> > Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
> > Signed-off-by: Ingo Molnar <mingo@kernel.org>
> > Link: https://lore.kernel.org/r/5eb28eeb6a724b7d945a961cfdcf8d41e6edf3dc.1744238814.git.jpoimboe@kernel.org
> >
> > Closes: https://lore.kernel.org/r/202504090910.QkvTAR36-lkp@intel.com/
>
> Superfluous newline there.
Fixed. Not sure what happened there.
> Also, this probably could use a fixes tag:
>
> Fixes: eeff7ac61526 ("objtool: Warn when disabling unreachable warnings")
Added that one too.
Thanks!
Ingo
^ permalink raw reply [flat|nested] 5+ messages in thread
* [tip: objtool/urgent] objtool: Fix false-positive "ignoring unreachables" warning
2025-04-09 22:49 [PATCH] objtool: Fix false "ignoring unreachables" warning Josh Poimboeuf
2025-04-10 6:14 ` [tip: objtool/urgent] objtool: Fix false-positive " tip-bot2 for Josh Poimboeuf
@ 2025-04-10 21:04 ` tip-bot2 for Josh Poimboeuf
1 sibling, 0 replies; 5+ messages in thread
From: tip-bot2 for Josh Poimboeuf @ 2025-04-10 21:04 UTC (permalink / raw)
To: linux-tip-commits
Cc: kernel test robot, Josh Poimboeuf, Ingo Molnar, x86, linux-kernel
The following commit has been merged into the objtool/urgent branch of tip:
Commit-ID: 87cb582d2f55d379ce95b5bcc4ec596e29b0a65e
Gitweb: https://git.kernel.org/tip/87cb582d2f55d379ce95b5bcc4ec596e29b0a65e
Author: Josh Poimboeuf <jpoimboe@kernel.org>
AuthorDate: Wed, 09 Apr 2025 15:49:36 -07:00
Committer: Ingo Molnar <mingo@kernel.org>
CommitterDate: Thu, 10 Apr 2025 22:55:00 +02:00
objtool: Fix false-positive "ignoring unreachables" warning
There's no need to try to automatically disable unreachable warnings if
they've already been manually disabled due to CONFIG_KCOV quirks.
This avoids a spurious warning with a KCOV kernel:
fs/smb/client/cifs_unicode.o: warning: objtool: cifsConvertToUTF16.part.0+0xce5: ignoring unreachables due to jump table quirk
Fixes: eeff7ac61526 ("objtool: Warn when disabling unreachable warnings")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/5eb28eeb6a724b7d945a961cfdcf8d41e6edf3dc.1744238814.git.jpoimboe@kernel.org
Closes: https://lore.kernel.org/r/202504090910.QkvTAR36-lkp@intel.com/
---
tools/objtool/arch/x86/special.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/objtool/arch/x86/special.c b/tools/objtool/arch/x86/special.c
index 403e587..06ca4a2 100644
--- a/tools/objtool/arch/x86/special.c
+++ b/tools/objtool/arch/x86/special.c
@@ -126,7 +126,7 @@ struct reloc *arch_find_switch_table(struct objtool_file *file,
* indicates a rare GCC quirk/bug which can leave dead
* code behind.
*/
- if (reloc_type(text_reloc) == R_X86_64_PC32) {
+ if (!file->ignore_unreachables && reloc_type(text_reloc) == R_X86_64_PC32) {
WARN_INSN(insn, "ignoring unreachables due to jump table quirk");
file->ignore_unreachables = true;
}
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-04-10 21:04 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-04-09 22:49 [PATCH] objtool: Fix false "ignoring unreachables" warning Josh Poimboeuf
2025-04-10 6:14 ` [tip: objtool/urgent] objtool: Fix false-positive " tip-bot2 for Josh Poimboeuf
2025-04-10 19:13 ` Josh Poimboeuf
2025-04-10 20:55 ` Ingo Molnar
2025-04-10 21:04 ` tip-bot2 for Josh Poimboeuf
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®