From: Lee Jones <lee.jones@linaro.org>
To: Lars-Peter Clausen <lars@metafoo.de>
Cc: jic23@kernel.org, pmeerw@pmeerw.net, linux-iio@vger.kernel.org
Subject: Re: [PATCH 1/1] iio: industrialio-trigger: Use 'gnu_printf' format notation
Date: Mon, 2 Nov 2020 11:37:23 +0000 [thread overview]
Message-ID: <20201102113723.GM4127@dell> (raw)
In-Reply-To: <6b5807c1-08af-2633-3352-bd7ae084cbe2@metafoo.de>
On Mon, 02 Nov 2020, Lars-Peter Clausen wrote:
> On 11/2/20 12:17 PM, Lee Jones wrote:
> > Fixes the following W=1 kernel build warning(s):
> >
> > drivers/iio/industrialio-trigger.c: In function ‘iio_alloc_pollfunc’:
> > drivers/iio/industrialio-trigger.c:338:2: warning: function ‘iio_alloc_pollfunc’ might be a candidate for ‘gnu_printf’ format attribute [-Wsuggest-attribute=format]
>
> Jonathan already sent a similar patch. See
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=cd7798cbd28044a3026619e36993160ba8fa118d
> <https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=cd7798cbd28044a3026619e36993160ba8fa118d>
So adding this to the prototype also squashes the warning?
> > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > ---
> > drivers/iio/industrialio-trigger.c | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/drivers/iio/industrialio-trigger.c b/drivers/iio/industrialio-trigger.c
> > index 583bb51f65a75..1d65c83439d84 100644
> > --- a/drivers/iio/industrialio-trigger.c
> > +++ b/drivers/iio/industrialio-trigger.c
> > @@ -320,6 +320,7 @@ irqreturn_t iio_pollfunc_store_time(int irq, void *p)
> > }
> > EXPORT_SYMBOL(iio_pollfunc_store_time);
> > +__printf(5, 6)
> > struct iio_poll_func
> > *iio_alloc_pollfunc(irqreturn_t (*h)(int irq, void *p),
> > irqreturn_t (*thread)(int irq, void *p),
>
>
--
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
next prev parent reply other threads:[~2020-11-02 11:37 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-02 11:17 [PATCH 1/1] iio: industrialio-trigger: Use 'gnu_printf' format notation Lee Jones
2020-11-02 11:23 ` Lars-Peter Clausen
2020-11-02 11:37 ` Lee Jones [this message]
2020-11-14 15:39 ` Jonathan Cameron
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=20201102113723.GM4127@dell \
--to=lee.jones@linaro.org \
--cc=jic23@kernel.org \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=pmeerw@pmeerw.net \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.