Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1586863 > unrolled thread
| Started by | kbuild test robot <fengguang.wu@intel.com> |
|---|---|
| First post | 2017-02-23 13:50 +0100 |
| Last post | 2017-02-24 17:20 +0100 |
| Articles | 4 — 3 participants |
Back to article view | Back to linux.kernel
net/rds/ib.c:115:2-7: WARNING: NULL check before freeing functions like kfree, debugfs_remove, debugfs_remove_recursive or usb_free_urb is not needed. Maybe consider reorganizing relevant code to avoid passing NULL values. kbuild test robot <fengguang.wu@intel.com> - 2017-02-23 13:50 +0100
[PATCH] RDS: IB: fix ifnullfree.cocci warnings kbuild test robot <fengguang.wu@intel.com> - 2017-02-23 13:50 +0100
Re: [PATCH] RDS: IB: fix ifnullfree.cocci warnings Santosh Shilimkar <santosh.shilimkar@oracle.com> - 2017-02-23 17:40 +0100
Re: [PATCH] RDS: IB: fix ifnullfree.cocci warnings David Miller <davem@davemloft.net> - 2017-02-24 17:20 +0100
| From | kbuild test robot <fengguang.wu@intel.com> |
|---|---|
| Date | 2017-02-23 13:50 +0100 |
| Subject | net/rds/ib.c:115:2-7: WARNING: NULL check before freeing functions like kfree, debugfs_remove, debugfs_remove_recursive or usb_free_urb is not needed. Maybe consider reorganizing relevant code to avoid passing NULL values. |
| Message-ID | <te10m-1jJ-9@gated-at.bofh.it> |
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: bc49a7831b1137ce1c2dda1c57e3631655f5d2ae commit: be2f76eacc278c272f26d46e4168efe5a55f5383 RDS: IB: Add vector spreading for cqs date: 7 weeks ago coccinelle warnings: (new ones prefixed by >>) >> net/rds/ib.c:115:2-7: WARNING: NULL check before freeing functions like kfree, debugfs_remove, debugfs_remove_recursive or usb_free_urb is not needed. Maybe consider reorganizing relevant code to avoid passing NULL values. Please review and possibly fold the followup patch. --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation
[toc] | [next] | [standalone]
| From | kbuild test robot <fengguang.wu@intel.com> |
|---|---|
| Date | 2017-02-23 13:50 +0100 |
| Subject | [PATCH] RDS: IB: fix ifnullfree.cocci warnings |
| Message-ID | <te10m-1jJ-27@gated-at.bofh.it> |
| In reply to | #1586863 |
net/rds/ib.c:115:2-7: WARNING: NULL check before freeing functions like kfree, debugfs_remove, debugfs_remove_recursive or usb_free_urb is not needed. Maybe consider reorganizing relevant code to avoid passing NULL values. NULL check before some freeing functions is not needed. Based on checkpatch warning "kfree(NULL) is safe this check is probably not required" and kfreeaddr.cocci by Julia Lawall. Generated by: scripts/coccinelle/free/ifnullfree.cocci Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> --- ib.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) --- a/net/rds/ib.c +++ b/net/rds/ib.c @@ -111,8 +111,7 @@ static void rds_ib_dev_free(struct work_ kfree(i_ipaddr); } - if (rds_ibdev->vector_load) - kfree(rds_ibdev->vector_load); + kfree(rds_ibdev->vector_load); kfree(rds_ibdev); }
[toc] | [prev] | [next] | [standalone]
| From | Santosh Shilimkar <santosh.shilimkar@oracle.com> |
|---|---|
| Date | 2017-02-23 17:40 +0100 |
| Subject | Re: [PATCH] RDS: IB: fix ifnullfree.cocci warnings |
| Message-ID | <te4AV-3Pf-15@gated-at.bofh.it> |
| In reply to | #1586867 |
On 2/23/2017 4:47 AM, kbuild test robot wrote: > net/rds/ib.c:115:2-7: WARNING: NULL check before freeing functions like kfree, debugfs_remove, debugfs_remove_recursive or usb_free_urb is not needed. Maybe consider reorganizing relevant code to avoid passing NULL values. > > NULL check before some freeing functions is not needed. > > Based on checkpatch warning > "kfree(NULL) is safe this check is probably not required" > and kfreeaddr.cocci by Julia Lawall. > > Generated by: scripts/coccinelle/free/ifnullfree.cocci > > Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> > --- Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com>
[toc] | [prev] | [next] | [standalone]
| From | David Miller <davem@davemloft.net> |
|---|---|
| Date | 2017-02-24 17:20 +0100 |
| Subject | Re: [PATCH] RDS: IB: fix ifnullfree.cocci warnings |
| Message-ID | <teqL7-2Ds-5@gated-at.bofh.it> |
| In reply to | #1586867 |
From: kbuild test robot <fengguang.wu@intel.com> Date: Thu, 23 Feb 2017 20:47:01 +0800 > net/rds/ib.c:115:2-7: WARNING: NULL check before freeing functions like kfree, debugfs_remove, debugfs_remove_recursive or usb_free_urb is not needed. Maybe consider reorganizing relevant code to avoid passing NULL values. > > NULL check before some freeing functions is not needed. > > Based on checkpatch warning > "kfree(NULL) is safe this check is probably not required" > and kfreeaddr.cocci by Julia Lawall. > > Generated by: scripts/coccinelle/free/ifnullfree.cocci > > Signed-off-by: Fengguang Wu <fengguang.wu@intel.com> Applied.
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web