Commit 3eb87773 authored by Shuah Khan's avatar Shuah Khan Committed by Mauro Carvalho Chehab

media: replace WARN_ON in __media_pipeline_start()

__media_pipeline_start() does WARN_ON() when active pipe doesn't
match the input arg entity's pipe.

Replace WARN_ON with a conditional and error message that includes
names of both entities.
Signed-off-by: default avatarShuah Khan <shuah@kernel.org>
Signed-off-by: default avatarHans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+samsung@kernel.org>
parent e855165f
...@@ -435,7 +435,10 @@ __must_check int __media_pipeline_start(struct media_entity *entity, ...@@ -435,7 +435,10 @@ __must_check int __media_pipeline_start(struct media_entity *entity,
entity->stream_count++; entity->stream_count++;
if (WARN_ON(entity->pipe && entity->pipe != pipe)) { if (entity->pipe && entity->pipe != pipe) {
pr_err("Pipe active for %s. Can't start for %s\n",
entity->name,
entity_err->name);
ret = -EBUSY; ret = -EBUSY;
goto error; goto error;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment