From: Helen Koike <helen.koike@collabora.com>
To: linux-media@vger.kernel.org
Cc: mchehab@kernel.org, linux-kernel@vger.kernel.org,
tfiga@chromium.org, linux-rockchip@lists.infradead.org,
hans.verkuil@cisco.com, kernel@collabora.com,
Helen Koike <helen.koike@collabora.com>
Subject: [PATCH 0/3] media: staging: rkisp1: allow simultaneous streaming from multiple capture devices
Date: Thu, 12 Mar 2020 22:46:23 -0300 [thread overview]
Message-ID: <20200313014626.3103091-1-helen.koike@collabora.com> (raw)
Hi,
This series adds support for simultaneous streaming from both capture
devices (rkisp1_selfpath and rkisp1_mainpath).
Patch 1/3 fixes return error handling from pm functions, which was
preventing the second stream to start.
Patch 2/3 don't allow .s_stream entity callback to be called if a stream is
already enabled. Which fixes the issue when stopping one stream would
also stop the other.
Patch 3/3 serializes start/stop streaming calls, since they both read
and modify the streaming status of all the entities in the piipeline.
This series was tested with:
SEN_DEV=/dev/v4l-subdev3
ISP_DEV=/dev/v4l-subdev0
RSZ_SP_DEV=/dev/v4l-subdev2
RSZ_MP_DEV=/dev/v4l-subdev1
CAP_SP_DEV=/dev/video1
CAP_MP_DEV=/dev/video0
WIDTH=1920
HEIGHT=1080
RAW_CODE=SRGGB10_1X10
YUV_CODE=YUYV8_2X8
v4l2-ctl --set-subdev-fmt pad=0,width=$WIDTH,height=$HEIGHT,code=$RAW_CODE -d $SEN_DEV
v4l2-ctl --set-subdev-fmt pad=0,width=$WIDTH,height=$HEIGHT,code=$RAW_CODE -d $ISP_DEV
v4l2-ctl --set-subdev-selection pad=0,target=crop,top=0,left=0,width=$WIDTH,height=$HEIGHT -d $ISP_DEV
v4l2-ctl --set-subdev-selection pad=2,target=crop,top=0,left=0,width=$WIDTH,height=$HEIGHT -d $ISP_DEV
v4l2-ctl --set-subdev-fmt pad=2,width=$WIDTH,height=$HEIGHT,code=$YUV_CODE -d $ISP_DEV
v4l2-ctl --set-subdev-fmt pad=0,width=$WIDTH,height=$HEIGHT,code=$YUV_CODE -d $RSZ_SP_DEV
v4l2-ctl --set-subdev-fmt pad=1,width=$WIDTH,height=$HEIGHT,code=$YUV_CODE -d $RSZ_SP_DEV
v4l2-ctl --set-subdev-selection pad=0,target=crop,top=0,left=0,width=$WIDTH,height=$HEIGHT -d $RSZ_SP_DEV
v4l2-ctl --set-subdev-fmt pad=0,width=$WIDTH,height=$HEIGHT,code=$YUV_CODE -d $RSZ_MP_DEV
v4l2-ctl --set-subdev-fmt pad=1,width=$WIDTH,height=$HEIGHT,code=$YUV_CODE -d $RSZ_MP_DEV
v4l2-ctl --set-subdev-selection pad=0,target=crop,top=0,left=0,width=$WIDTH,height=$HEIGHT -d $RSZ_MP_DEV
v4l2-ctl -v width=$WIDTH,height=$HEIGHT,pixelformat=NV12 -d $CAP_SP_DEV
v4l2-ctl -v width=$WIDTH,height=$HEIGHT,pixelformat=NV12 -d $CAP_MP_DEV
sleep 1
v4l2-ctl --stream-mmap --stream-count=100 -d $CAP_SP_DEV --stream-to=/tmp/test_sp.raw &
v4l2-ctl --stream-mmap --stream-count=100 -d $CAP_MP_DEV --stream-to=/tmp/test_mp.raw &
wait
echo "Completed"
Helen Koike (3):
media: staging: rkisp1: cap: fix return values from pm functions
media: staging: rkisp1: do not call s_stream if the entity is still in
use
media: staging: rkisp1: cap: serialize start/stop stream
drivers/staging/media/rkisp1/rkisp1-capture.c | 25 ++++++++++++++++---
drivers/staging/media/rkisp1/rkisp1-common.h | 2 ++
drivers/staging/media/rkisp1/rkisp1-dev.c | 2 ++
3 files changed, 25 insertions(+), 4 deletions(-)
--
2.25.0
next reply other threads:[~2020-03-13 1:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-13 1:46 Helen Koike [this message]
2020-03-13 1:46 ` [PATCH 1/3] media: staging: rkisp1: cap: fix return values from pm functions Helen Koike
2020-03-13 1:46 ` [PATCH 2/3] media: staging: rkisp1: do not call s_stream if the entity is still in use Helen Koike
2020-03-13 1:46 ` [PATCH 3/3] media: staging: rkisp1: cap: serialize start/stop stream Helen Koike
2020-03-13 16:51 ` [PATCH 0/3] media: staging: rkisp1: allow simultaneous streaming from multiple capture devices Helen Koike
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200313014626.3103091-1-helen.koike@collabora.com \
--to=helen.koike@collabora.com \
--cc=hans.verkuil@cisco.com \
--cc=kernel@collabora.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=mchehab@kernel.org \
--cc=tfiga@chromium.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®