Message ID | 61017c012617e6f633ac9f9a3c2659ae38e1f2fb.1694613528.git.geert@linux-m68k.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9ecd:0:b0:3f2:4152:657d with SMTP id t13csp1120243vqx; Wed, 13 Sep 2023 07:19:47 -0700 (PDT) X-Google-Smtp-Source: AGHT+IG3UjjoTbLCZdJC19drBqflLUZMKFYeMSa1PwEF216T7KFLwUMJ+swCNohNida9383Cgcgj X-Received: by 2002:a05:6a20:9758:b0:153:860e:47ef with SMTP id hs24-20020a056a20975800b00153860e47efmr2282591pzc.47.1694614787193; Wed, 13 Sep 2023 07:19:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694614787; cv=none; d=google.com; s=arc-20160816; b=i0qUVGtg40YAkUedC6aQQj8GN5sVJ2EmqKtcP0i33EwvtsXjdF5UiA/wAtzDUtqIix wHopYW1YBfCWpymE9NtMIXJdiOWYZRsbeaTjeqL2zViUI647HeJAHPapB5gEheRhULox BMSEpWqAWsuFClRoVnNrolarAJaiU6HDz0lULxCel7oj3EreuvWxGq8dKVvK5Wo3bM/z OHHMfwqwJJo0tBsFs5tI5zJBsiBZwLDTPnIDGhESmbUHTxcCO1JsMiAsNIb5gq9Y1aDz dMYzX4V1ZFHuoMENYMxv7S5TleUhBfLTt7c2omCX0RL/LKGnfoRx/QKQpXlNGo6ltIZW C/fg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=8zndX+tehjwHI9Wt8FeRvLjBGPn7+WOnr2f7q0CTjs8=; fh=fKMC3BTGjlLXl5EvEhzqt3WHCynqYJKK7wAqLAOkWUw=; b=aAj4/AUywOif6p2+9vJadKuxvI1fUPf1gZK3KBSY88d0IVFD3iaRB34BpctJ2JwHcw Psl4RXGHxExKZb9jYJhj0+P4sLYesCHGWpEEDR3h6lTEKpuy+l4Lr6Lioh2RaawGYxBN VUsBNmVlMEVcoeDV5lK5/lIMSLZY9/0mI7G2rJKjPjI2XyZnITC+qdb0+SabTSfUGFwn PktE1kUMvcrENKvQNznNxlgaxTudxhY36oCnnqPmc7r6Nww7NszDWWXV24p7XTe9/vmp KWXMaG3x/ioMrsKdFa8hWQ46womNtVjEIrsNywvAemIj4XEzPOEBjw50tYXMNYcoNQKg tn+g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id fb14-20020a056a002d8e00b0068ff3a3c9bfsi2715644pfb.8.2023.09.13.07.19.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Sep 2023 07:19:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 7DF1080C0A5D; Wed, 13 Sep 2023 07:10:51 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241621AbjIMOK3 (ORCPT <rfc822;pwkd43@gmail.com> + 36 others); Wed, 13 Sep 2023 10:10:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59960 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241398AbjIMOJc (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 13 Sep 2023 10:09:32 -0400 Received: from cantor.telenet-ops.be (cantor.telenet-ops.be [IPv6:2a02:1800:120:4::f00:10]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 86D6D1FC0 for <linux-kernel@vger.kernel.org>; Wed, 13 Sep 2023 07:08:53 -0700 (PDT) Received: from baptiste.telenet-ops.be (baptiste.telenet-ops.be [IPv6:2a02:1800:120:4::f00:13]) by cantor.telenet-ops.be (Postfix) with ESMTPS id 4Rm2PF3XHKz4x7b6 for <linux-kernel@vger.kernel.org>; Wed, 13 Sep 2023 16:08:49 +0200 (CEST) Received: from ramsan.of.borg ([84.195.187.55]) by baptiste.telenet-ops.be with bizsmtp id lS8o2A0031C8whw01S8oqP; Wed, 13 Sep 2023 16:08:49 +0200 Received: from rox.of.borg ([192.168.97.57]) by ramsan.of.borg with esmtp (Exim 4.95) (envelope-from <geert@linux-m68k.org>) id 1qgQXe-003ctp-HY; Wed, 13 Sep 2023 16:08:47 +0200 Received: from geert by rox.of.borg with local (Exim 4.95) (envelope-from <geert@linux-m68k.org>) id 1qgQXv-00FV6y-Sj; Wed, 13 Sep 2023 16:08:47 +0200 From: Geert Uytterhoeven <geert@linux-m68k.org> To: linux-m68k@lists.linux-m68k.org Cc: Arnd Bergmann <arnd@arndb.de>, Finn Thain <fthain@linux-m68k.org>, Michael Schmitz <schmitzmic@gmail.com>, Philip Blundell <philb@gnu.org>, Greg Ungerer <gerg@linux-m68k.org>, Joshua Thompson <funaho@jurai.org>, Sam Creasey <sammy@sammy.net>, Laurent Vivier <laurent@vivier.eu>, linux-kernel@vger.kernel.org, Geert Uytterhoeven <geert@linux-m68k.org> Subject: [PATCH v2 45/52] m68k: sun3: Annotate prom_printf() with __printf() Date: Wed, 13 Sep 2023 16:08:35 +0200 Message-Id: <61017c012617e6f633ac9f9a3c2659ae38e1f2fb.1694613528.git.geert@linux-m68k.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <cover.1694613528.git.geert@linux-m68k.org> References: <cover.1694613528.git.geert@linux-m68k.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Wed, 13 Sep 2023 07:10:51 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1776932395176959784 X-GMAIL-MSGID: 1776932395176959784 |
Series |
m68k: W=1 fixes
|
|
Commit Message
Geert Uytterhoeven
Sept. 13, 2023, 2:08 p.m. UTC
When building with W=1: arch/m68k/sun3/prom/printf.c: In function ‘prom_printf’: arch/m68k/sun3/prom/printf.c:35:9: warning: function ‘prom_printf’ might be a candidate for ‘gnu_printf’ format attribute [-Wsuggest-attribute=format] 35 | vsprintf(ppbuf, fmt, args); | ^~~~~~~~ Fix this by annotating prom_printf() with __printf(1, 2). Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Arnd Bergmann <arnd@arndb.de> --- v2: - Add Acked-by. --- arch/m68k/include/asm/oplib.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/m68k/include/asm/oplib.h b/arch/m68k/include/asm/oplib.h index 48cb4fd09f8d9cce..6d5ea67c65d044c1 100644 --- a/arch/m68k/include/asm/oplib.h +++ b/arch/m68k/include/asm/oplib.h @@ -9,6 +9,8 @@ #ifndef __SPARC_OPLIB_H #define __SPARC_OPLIB_H +#include <linux/compiler.h> + #include <asm/openprom.h> /* The master romvec pointer... */ @@ -149,7 +151,7 @@ extern char prom_getchar(void); extern void prom_putchar(char character); /* Prom's internal printf routine, don't use in kernel/boot code. */ -void prom_printf(char *fmt, ...); +__printf(1, 2) void prom_printf(char *fmt, ...); /* Query for input device type */