[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID:
<SE1P216MB13033133B562E91A23CE6DBAED802@SE1P216MB1303.KORP216.PROD.OUTLOOK.COM>
Date: Tue, 29 Apr 2025 05:59:48 +0000
From: jackson.lee <jackson.lee@...psnmedia.com>
To: Nicolas Dufresne <nicolas.dufresne@...labora.com>, "mchehab@...nel.org"
<mchehab@...nel.org>, "hverkuil-cisco@...all.nl" <hverkuil-cisco@...all.nl>,
"bob.beckett@...labora.com" <bob.beckett@...labora.com>
CC: "linux-media@...r.kernel.org" <linux-media@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>, lafley.kim
<lafley.kim@...psnmedia.com>, "b-brnich@...com" <b-brnich@...com>,
"hverkuil@...all.nl" <hverkuil@...all.nl>, Nas Chung
<nas.chung@...psnmedia.com>
Subject: RE: [RESEND PATCH v1 0/7] Performance improvement of decoder
Hi Nicolas
> -----Original Message-----
> From: Nicolas Dufresne <nicolas.dufresne@...labora.com>
> Sent: Monday, April 14, 2025 10:29 PM
> To: jackson.lee <jackson.lee@...psnmedia.com>; mchehab@...nel.org;
> hverkuil-cisco@...all.nl; bob.beckett@...labora.com
> Cc: linux-media@...r.kernel.org; linux-kernel@...r.kernel.org; lafley.kim
> <lafley.kim@...psnmedia.com>; b-brnich@...com; hverkuil@...all.nl; Nas
> Chung <nas.chung@...psnmedia.com>
> Subject: Re: [RESEND PATCH v1 0/7] Performance improvement of decoder
>
> Jackson,
>
> Le lundi 14 avril 2025 à 02:04 +0000, jackson.lee a écrit :
> > > > Sequence Change test
> > > > =====================
> > > > gst-launch-1.0 filesrc location=./switch_1080p_720p_240frames.h264 !
> > > > h264parse ! v4l2h264dec ! filesink location=./h264_output_420.yuv
> > > > Setting pipeline to PAUSED ...
> > > > Pipeline is PREROLLING ...
> > > > Redistribute latency...
> > > > Redistribute latency...
> > > > Pipeline is PREROLLED ...
> > > > Setting pipeline to PLAYING ...
> > > > Redistribute latency...
> > > > New clock: GstSystemClock
> > > > Got EOS from element "pipeline0".
> > > > Execution ended after 0:00:05.772414400 Setting pipeline to NULL ...
> > > > Freeing pipeline ...
> > >
> > > I did a test of my own here, and did get kernel splat. The warning
> > > indicate that the state machine is no longer respected. This needs
> > > to be address in v2, we added these check, since the locking is
> > > bound to legal use of the state machine.
> >
> >
> > Since applying the performance patch, device_run and
> wave5_vpu_dec_finish_decode is not synchronized any more.
> > How about removing this warning message ?
>
> I would like to understand how it makes sense the we've reached STOP state
> while the HW is still actively decoding. It does not feel robust to me,
> perhaps you want to introduce a new state ? Also, I'm concern with overall
> thread-safety now.
The finish_decode and device_run was synchronized each other, but since applying the performance patch, as you know, they are not.
So as soon as setting the device statue to STOP in the finish_decode, the device_run could be called before preventing device_run being called by the job_ready.
I think there is no problem because EOS has already been sent in the finish_decode and statue has been changed.
I don't think it breaks overall thread-safety.
SO I can remove the warning message. How about?
>
> regards,
>
> --
> Nicolas Dufresne
> Principal Engineer at Collabora
Powered by blists - more mailing lists