atomisp2: remove cast from memory allocation
Subsystems (4)
PATCH 1/1 atomisp2: remove cast from memory allocation
Patch removes the following warning issued was coccicheck:
WARNING: casting value returned by memory allocation function to (char *) is useless.
Signed-off-by Aishwarya Pant <[email protected]>
--- drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_firmware.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_firmware.c +2 -2
@@ -145,8 +145,8 @@ sh_css_load_blob_info(const char *fw, const struct ia_css_fw_info *bi, struct iasize_t configstruct_size =sizeof (struct ia_css_config_memory_offsets );size_t statestruct_size =sizeof (struct ia_css_state_memory_offsets ); -char *parambuf = (char *)kmalloc (paramstruct_size + configstruct_size + statestruct_size, -GFP_KERNEL ); +char *parambuf =kmalloc (paramstruct_size + configstruct_size + statestruct_size, +GFP_KERNEL );if (parambuf ==NULL )return IA_CSS_ERR_CANNOT_ALLOCATE_MEMORY ;
Signature · 1 line
2.7.4