Messages in this thread | | | Date | Wed, 24 Aug 2022 12:29:29 -0500 | From | Segher Boessenkool <> | Subject | Re: [PATCH] x86/sev: Mark snp_abort() noreturn |
| |
Hi!
On Wed, Aug 24, 2022 at 05:24:20PM +0200, Borislav Petkov wrote: > Mark both the function prototype and definition as noreturn in order to > prevent the compiler from doing transformations which confuse objtool > like so: > > vmlinux.o: warning: objtool: sme_enable+0x71: unreachable instruction
Would -Wmissing-noreturn have caught this? It sounds like you need this (and then fix all resulting warnings) to not upset objtool?
It is nice to have this anyway (if there aren't a zillion false positives), but it seems objtool is very fragile.
Segher
| |