summaryrefslogtreecommitdiff
path: root/drivers/media/platform/s5p-mfc
diff options
context:
space:
mode:
authorShuah Khan <shuahkh@osg.samsung.com>2017-11-03 22:01:57 -0400
committerMauro Carvalho Chehab <mchehab@s-opensource.com>2017-12-18 15:10:33 -0500
commita465321ac1bd90ffe2de030e29ef5738af046603 (patch)
tree91a85f2f38a0d69fb695cec624c95ceaed126b0e /drivers/media/platform/s5p-mfc
parentbc7eb5d7e2d70e027f5846f71b70d6c99b8f176f (diff)
media: s5p-mfc: Remove firmware buf null check in s5p_mfc_load_firmware()
s5p_mfc_load_firmware() will not get called if fw_buf.virt allocation fails. The allocation happens very early on in the probe routine and probe fails if allocation fails. There is no need to check if it is null in s5p_mfc_load_firmware(). Remove the check. Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/platform/s5p-mfc')
-rw-r--r--drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c b/drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c
index 69ef9c23a99a..46c9d67b78e4 100644
--- a/drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c
+++ b/drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c
@@ -75,11 +75,6 @@ int s5p_mfc_load_firmware(struct s5p_mfc_dev *dev)
release_firmware(fw_blob);
return -ENOMEM;
}
- if (!dev->fw_buf.virt) {
- mfc_err("MFC firmware is not allocated\n");
- release_firmware(fw_blob);
- return -EINVAL;
- }
memcpy(dev->fw_buf.virt, fw_blob->data, fw_blob->size);
wmb();
release_firmware(fw_blob);