From: Joe Perches <joe@perches•com>
To: Yuval Mintz <Yuval.Mintz@qlogic•com>,
kbuild test robot <fengguang.wu@intel•com>,
David Miller <davem@davemloft•net>
Cc: "kbuild-all@01•org" <kbuild-all@01•org>,
netdev <netdev@vger•kernel.org>,
Ariel Elior <Ariel.Elior@qlogic•com>,
Dept-Eng Everest Linux L2 <Dept-EngEverestLinuxL2@qlogic•com>,
linux-kernel <linux-kernel@vger•kernel.org>,
Sudarsana Kalluru <Sudarsana.Kalluru@qlogic•com>
Subject: Re: [PATCH] qed: fix kzalloc-simple.cocci warnings
Date: Fri, 02 Sep 2016 10:44:21 -0700 [thread overview]
Message-ID: <1472838261.6758.74.camel@perches.com> (raw)
In-Reply-To: <DM5PR11MB1723927908802E0D1C38C94D97E20@DM5PR11MB1723.namprd11.prod.outlook.com>
On Thu, 2016-09-01 at 07:37 +0000, Yuval Mintz wrote:
> > drivers/net/ethernet/qlogic/qed/qed_dcbx.c:1230:13-20: WARNING: kzalloc
> > should be used for dcbx_info, instead of kmalloc/memset
> > drivers/net/ethernet/qlogic/qed/qed_dcbx.c:1192:13-20: WARNING: kzalloc
> > should be used for dcbx_info, instead of kmalloc/memset
> >
> > Use kzalloc rather than kmalloc followed by memset with 0
[]
> One question the automated script -
> Can't it [relative] easily be upgraded to also have 'Fixes:' as part
> of its message?
It's really not a "fix" as it has no real effect on behavior.
The code is perfectly fine as is really.
It is a code size reduction though.
Another thing with a behavior change and one that would also
reduce code size would be to remove the unnecessary OOM
messages after the allocs.
I'll send a patch for that.
next prev parent reply other threads:[~2016-09-02 17:44 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-01 6:45 [net:master 27/28] drivers/net/ethernet/qlogic/qed/qed_dcbx.c:1230:13-20: WARNING: kzalloc should be used for dcbx_info, instead of kmalloc/memset kbuild test robot
2016-09-01 6:45 ` [PATCH] qed: fix kzalloc-simple.cocci warnings kbuild test robot
2016-09-01 7:37 ` Yuval Mintz
2016-09-01 16:48 ` David Miller
2016-09-02 17:44 ` Joe Perches [this message]
2016-09-02 17:48 ` [PATCH] qed: Remove OOM messages Joe Perches
2016-09-04 8:18 ` Yuval Mintz
2016-09-04 20:28 ` David Miller
2016-09-04 21:22 ` Joe Perches
-- strict thread matches above, loose matches on Subject: below --
2017-04-21 0:20 [net:master 15/18] drivers/net/ethernet/qlogic/qed/qed_dcbx.c:1267:13-20: WARNING: kzalloc should be used for dcbx_info, instead of kmalloc/memset kbuild test robot
2017-04-21 0:20 ` [PATCH] qed: fix kzalloc-simple.cocci warnings kbuild test robot
2017-04-24 16:03 ` David Miller
[not found] <201509302130.SXWHwgAF%fengguang.wu@intel.com>
2015-09-30 13:03 ` [RFC v3 net-next 01/10] qed: Add module with basic common support Yuval Mintz
2015-09-30 13:33 ` [PATCH] qed: fix kzalloc-simple.cocci warnings kbuild test robot
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=1472838261.6758.74.camel@perches.com \
--to=joe@perches$(echo .)com \
--cc=Ariel.Elior@qlogic$(echo .)com \
--cc=Dept-EngEverestLinuxL2@qlogic$(echo .)com \
--cc=Sudarsana.Kalluru@qlogic$(echo .)com \
--cc=Yuval.Mintz@qlogic$(echo .)com \
--cc=davem@davemloft$(echo .)net \
--cc=fengguang.wu@intel$(echo .)com \
--cc=kbuild-all@01$(echo .)org \
--cc=linux-kernel@vger$(echo .)kernel.org \
--cc=netdev@vger$(echo .)kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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