From: Julian Wiedmann <jwi@linux.ibm.com>
To: David Miller <davem@davemloft.net>, Jakub Kicinski <kuba@kernel.org>
Cc: linux-netdev <netdev@vger.kernel.org>,
linux-s390 <linux-s390@vger.kernel.org>,
Heiko Carstens <hca@linux.ibm.com>,
Karsten Graul <kgraul@linux.ibm.com>,
Julian Wiedmann <jwi@linux.ibm.com>
Subject: [PATCH net-next 7/9] s390/qeth: add __printf format attribute to qeth_dbf_longtext
Date: Mon, 25 Oct 2021 11:56:56 +0200 [thread overview]
Message-ID: <20211025095658.3527635-8-jwi@linux.ibm.com> (raw)
In-Reply-To: <20211025095658.3527635-1-jwi@linux.ibm.com>
From: Heiko Carstens <hca@linux.ibm.com>
Allow the compiler to recognize and check format strings and parameters.
As reported with allmodconfig and W=1:
drivers/s390/net/qeth_core_main.c: In function ‘qeth_dbf_longtext’:
drivers/s390/net/qeth_core_main.c:6190:9: error: function ‘qeth_dbf_longtext’ might be a candidate for ‘gnu_printf’ format attribute [-Werror=suggest-attribute=format]
6190 | vsnprintf(dbf_txt_buf, sizeof(dbf_txt_buf), fmt, args);
| ^~~~~~~~~
Acked-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
---
drivers/s390/net/qeth_core.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/s390/net/qeth_core.h b/drivers/s390/net/qeth_core.h
index 09e1d2da3e48..20dca4c0384a 100644
--- a/drivers/s390/net/qeth_core.h
+++ b/drivers/s390/net/qeth_core.h
@@ -1084,6 +1084,7 @@ int qeth_setadpparms_set_access_ctrl(struct qeth_card *card,
int qeth_do_ioctl(struct net_device *dev, struct ifreq *rq, int cmd);
int qeth_siocdevprivate(struct net_device *dev, struct ifreq *rq,
void __user *data, int cmd);
+__printf(3, 4)
void qeth_dbf_longtext(debug_info_t *id, int level, char *text, ...);
int qeth_configure_cq(struct qeth_card *, enum qeth_cq);
int qeth_hw_trap(struct qeth_card *, enum qeth_diags_trap_action);
--
2.25.1
next prev parent reply other threads:[~2021-10-25 9:57 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-25 9:56 [PATCH net-next 0/9] s390/qeth: updates 2021-10-25 Julian Wiedmann
2021-10-25 9:56 ` [PATCH net-next 1/9] s390/qeth: improve trace entries for MAC address (un)registration Julian Wiedmann
2021-10-25 9:56 ` [PATCH net-next 2/9] s390/qeth: remove .do_ioctl() callback from driver discipline Julian Wiedmann
2021-10-25 9:56 ` [PATCH net-next 3/9] s390/qeth: move qdio's QAOB cache into qeth Julian Wiedmann
2021-10-25 9:56 ` [PATCH net-next 4/9] s390/qeth: clarify remaining dev_kfree_skb_any() users Julian Wiedmann
2021-10-25 9:56 ` [PATCH net-next 5/9] s390/qeth: don't keep track of Input Queue count Julian Wiedmann
2021-10-25 9:56 ` [PATCH net-next 6/9] s390/qeth: fix various format strings Julian Wiedmann
2021-10-25 13:22 ` Vladimir Oltean
2021-10-25 13:35 ` Julian Wiedmann
2021-10-25 14:32 ` Vladimir Oltean
2021-10-25 9:56 ` Julian Wiedmann [this message]
2021-10-25 9:56 ` [PATCH net-next 8/9] s390/qeth: fix kernel doc comments Julian Wiedmann
2021-10-25 9:56 ` [PATCH net-next 9/9] s390/qeth: update kerneldoc for qeth_add_hw_header() Julian Wiedmann
2021-10-25 13:00 ` [PATCH net-next 0/9] s390/qeth: updates 2021-10-25 patchwork-bot+netdevbpf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211025095658.3527635-8-jwi@linux.ibm.com \
--to=jwi@linux.ibm.com \
--cc=davem@davemloft.net \
--cc=hca@linux.ibm.com \
--cc=kgraul@linux.ibm.com \
--cc=kuba@kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).