]> git.baikalelectronics.ru Git - kernel.git/commit
IB/mthca: NULL arg to pci_dev_put is OK
authorMarkus Elfring <elfring@users.sourceforge.net>
Sat, 23 Jul 2016 08:05:12 +0000 (10:05 +0200)
committerDoug Ledford <dledford@redhat.com>
Thu, 4 Aug 2016 01:03:35 +0000 (21:03 -0400)
commitbb7d9843eb71bdada43f53c1ce66e09c787cffa9
tree5ec8e5b1adde002a02e1cbcfce4fe8ba7aa068f5
parent09b07d115fdb4b7ef205add179140769595c4794
IB/mthca: NULL arg to pci_dev_put is OK

The pci_dev_put() function tests whether its argument is NULL and then
returns immediately. Thus the test around the call is not needed.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Reviewed-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/mthca/mthca_reset.c