@@ -413,7 +413,6 @@ aspect_ratio_crop(struct ia_css_pipe *curr_pipe,
static void
sh_css_pipe_free_shading_table(struct ia_css_pipe *pipe)
{
- assert(pipe);
if (!pipe) {
IA_CSS_ERROR("NULL input parameter");
return;
@@ -1080,7 +1079,6 @@ sh_css_config_input_network(struct ia_css_stream *stream)
}
}
- assert(pipe);
if (!pipe)
return -EINVAL;
@@ -1382,10 +1380,11 @@ start_copy_on_sp(struct ia_css_pipe *pipe,
struct ia_css_frame *out_frame)
{
(void)out_frame;
- assert(pipe);
- assert(pipe->stream);
- if ((!pipe) || (!pipe->stream))
+ if (!pipe)
+ return -EINVAL;
+
+ if (!pipe->stream)
return -EINVAL;
#if !defined(ISP2401)
Remove assert() in places where the condition is already handled. Signed-off-by: Martiros Shakhzadyan <vrzh@vrzh.net> --- drivers/staging/media/atomisp/pci/sh_css.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-)