media: atomisp: pci: Remove checks before kfree/kvfree
authorFabio M. De Francesco <fmdefrancesco@gmail.com>
Thu, 27 May 2021 19:39:22 +0000 (21:39 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Thu, 22 Jul 2021 12:01:56 +0000 (14:01 +0200)
commit179b1fce5d80f7d1b075bf9cb00cb78cb16ea09c
tree3710bd86d5bc5a441fddd857203c07822d63ed42
parenta5d46d9afbdf9d1755d421052dcdeaf2f3725f52
media: atomisp: pci: Remove checks before kfree/kvfree

Removed checks for pointers != NULL before freeing memory. If kvfree()
and kfree() are given NULL pointers no operations are performed, so
there is no need for the above-mentioned checks. Coccinelle detected the
second of the two unnecessary checks.

Link: https://lore.kernel.org/linux-media/20210527193922.25225-1-fmdefrancesco@gmail.com
Signed-off-by: Fabio M. De Francesco <fmdefrancesco@gmail.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/staging/media/atomisp/pci/sh_css_firmware.c