lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20190822102729.GA29026@arm.com>
Date:   Thu, 22 Aug 2019 10:27:30 +0000
From:   Ayan Halder <Ayan.Halder@....com>
To:     "james qian wang (Arm Technology China)" <james.qian.wang@....com>
CC:     Liviu Dudau <Liviu.Dudau@....com>,
        "airlied@...ux.ie" <airlied@...ux.ie>,
        Brian Starkey <Brian.Starkey@....com>,
        "maarten.lankhorst@...ux.intel.com" 
        <maarten.lankhorst@...ux.intel.com>,
        "sean@...rly.run" <sean@...rly.run>,
        "Jonathan Chai (Arm Technology China)" <Jonathan.Chai@....com>,
        "Julien Yin (Arm Technology China)" <Julien.Yin@....com>,
        "Thomas Sun (Arm Technology China)" <thomas.Sun@....com>,
        "Lowry Li (Arm Technology China)" <Lowry.Li@....com>,
        "Tiannan Zhu (Arm Technology China)" <Tiannan.Zhu@....com>,
        "Yiqi Kang (Arm Technology China)" <Yiqi.Kang@....com>,
        nd <nd@....com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
        Ben Davis <Ben.Davis@....com>,
        "Oscar Zhang (Arm Technology China)" <Oscar.Zhang@....com>,
        "Channing Chen (Arm Technology China)" <Channing.Chen@....com>,
        Mihail Atanassov <Mihail.Atanassov@....com>
Subject: Re: [PATCH] drm/komeda: Clean warning 'komeda_component_add' might be
 a candidate for 'gnu_printf'

On Tue, Aug 13, 2019 at 11:08:20AM +0000, james qian wang (Arm Technology China) wrote:
> komeda/komeda_pipeline.c: In function 'komeda_component_add':
> komeda/komeda_pipeline.c:212:3: warning: function 'komeda_component_add' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
>    vsnprintf(c->name, sizeof(c->name), name_fmt, args);
>    ^~~~~~~~~
> 
> Signed-off-by: james qian wang (Arm Technology China) <james.qian.wang@....com>
> ---
>  drivers/gpu/drm/arm/display/komeda/komeda_pipeline.h | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_pipeline.h b/drivers/gpu/drm/arm/display/komeda/komeda_pipeline.h
> index a90bcbb3cb23..14b683164544 100644
> --- a/drivers/gpu/drm/arm/display/komeda/komeda_pipeline.h
> +++ b/drivers/gpu/drm/arm/display/komeda/komeda_pipeline.h
> @@ -480,6 +480,7 @@ void komeda_pipeline_dump_register(struct komeda_pipeline *pipe,
>  				   struct seq_file *sf);
>  
>  /* component APIs */
> +extern __printf(10, 11)

Took me a while to understand this and found this link very helpful :) :-
https://www.avrfreaks.net/forum/gnuprintf-format-attribute

Reviewed-by: Ayan Kumar Halder <ayan.halder@....com>
>  struct komeda_component *
>  komeda_component_add(struct komeda_pipeline *pipe,
>  		     size_t comp_sz, u32 id, u32 hw_id,
> -- 
> 2.20.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ