From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751926AbeAAVmA (ORCPT + 1 other); Mon, 1 Jan 2018 16:42:00 -0500 Received: from smtprelay0102.hostedemail.com ([216.40.44.102]:34985 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751487AbeAAVl7 (ORCPT ); Mon, 1 Jan 2018 16:41:59 -0500 X-Session-Marker: 6A6F6540706572636865732E636F6D X-HE-Tag: sign27_85714202fc142 X-Filterd-Recvd-Size: 1864 Message-ID: <1514842915.1967.44.camel@perches.com> Subject: Re: [PATCH] arch/x86: add __noreturn __cold to fortify_panic() From: Joe Perches To: Joey Pabalinas , x86@kernel.org Cc: hpa@zytor.com, tglx@linutronix.de, mingo@redhat.com, linux-kernel@vger.kernel.org Date: Mon, 01 Jan 2018 13:41:55 -0800 In-Reply-To: <20180101213608.3enfuk7noaui4ull@gmail.com> References: <20180101213608.3enfuk7noaui4ull@gmail.com> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.26.1-1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: On Mon, 2018-01-01 at 11:36 -1000, Joey Pabalinas wrote: > Definition of `fortify_panic()` doesn't match the declaration > in include/linux/string.h. Add the missing __noreturn __cold > attributes to `fortify_panic()`. This should not be necessary as the prototype has those attributes. Otherwise, all the __printf attributes would also have to be added to the definitions and not the just the declarations. > Signed-off-by: Joey Pabalinas > --- > arch/x86/boot/compressed/misc.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/x86/boot/compressed/misc.c b/arch/x86/boot/compressed/misc.c > index 98761a1576ceb5c21b..707cf3f339e37f7f8c 100644 > --- a/arch/x86/boot/compressed/misc.c > +++ b/arch/x86/boot/compressed/misc.c > @@ -428,7 +428,7 @@ asmlinkage __visible void *extract_kernel(void *rmode, memptr heap, > return output; > } > > -void fortify_panic(const char *name) > +void __noreturn __cold fortify_panic(const char *name) > { > error("detected buffer overflow"); > }