]> git.baikalelectronics.ru Git - kernel.git/commit
netdevsim: fix ptr_ret.cocci warnings
authorkbuild test robot <lkp@intel.com>
Tue, 4 Feb 2020 14:22:02 +0000 (22:22 +0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 5 Feb 2020 12:55:32 +0000 (13:55 +0100)
commit432c96013bbf44fea2e2d83101fcca9ea6376f1a
treed87fbbc327babaef24cfb90ddce987a0762a16b8
parent2ff141c09d2197bdb38ca1dec5a5374e4144cae4
netdevsim: fix ptr_ret.cocci warnings

drivers/net/netdevsim/dev.c:937:1-3: WARNING: PTR_ERR_OR_ZERO can be used

 Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR

Generated by: scripts/coccinelle/api/ptr_ret.cocci

Fixes: abdac68b7a13 ("netdevsim: use IS_ERR instead of IS_ERR_OR_NULL for debugfs")
CC: Taehee Yoo <ap420073@gmail.com>
Signed-off-by: kbuild test robot <lkp@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/netdevsim/dev.c