lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 8 May 2019 00:04:54 +0300
From:   Sakari Ailus <sakari.ailus@....fi>
To:     Nicholas Mc Guire <der.herr@...r.at>
Cc:     Nicholas Mc Guire <hofrat@...ntech.at>,
        Mauro Carvalho Chehab <mchehab@...nel.org>,
        linux-media@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/3] media: smiapp: core: add range to usleep_range

On Sat, May 04, 2019 at 11:46:35AM +0200, Nicholas Mc Guire wrote:
> On Tue, Apr 30, 2019 at 04:49:44PM +0300, Sakari Ailus wrote:
> > Hi Nicholas,
> > 
> > On Sun, Apr 07, 2019 at 04:16:02AM +0200, Nicholas Mc Guire wrote:
> > > Allow the hrtimer subsystem to coalesce delay timers of lower accuracy
> > > by providing a suitable range
> > > 
> > > Signed-off-by: Nicholas Mc Guire <hofrat@...ntech.at>
> > > ---
> > > 
> > > Problem located by an experimental coccinelle script
> > > 
> > > hrtimers in atomic context have limited accuracy due to possible
> > > context-switching and interruption so the accuracy is limited 
> > > anyway. Giving the hrtimer subsystem a reasonable range for merging
> > > hrtimers helps to reduce the load on the hrtimer subsystem. As this
> > > delays do not seem to mandate high accuracy the range of a factor
> > > two seems acceptable.
> > > 
> > > Patch was compile tested with: x86_64_defconfig + MEDIA_SUPPORT=m,
> > > MEDIA_CAMERA_SUPPORT=y, MEDIA_CONTROLLER=y, VIDEO_V4L2_SUBDEV_API=y,
> > > VIDEO_SMIAPP=m                                                                                               
> > > (with a number of sparse warnings on sizeof() usage)
> > > 
> > > Patch is against 5.1-rc3 (localversion-next is next-20190405)
> > 
> > The delays are exact for the reason that they are user-visible delays in
> > image capturing related use cases. Sometimes milliseconds matter, or at
> > least adding more does not help.
> >
> 
> Actually it can be better iwith respect to jitter to let the hrtimer 
> subsystem use an existing timer event than to have a close by second event 
> and the accuracy is determined by the non-atomic context anyway - 
> so while the proposed delay extension might be excessive in your case
> I would still suggest to try to get away from a range of 0 - even if
> you only end up with (1000,1050) that would be an advantage for the
> timer subsystem.

Sounds reasonable to me. Would you like to send v2?

Thanks.

-- 
Sakari Ailus

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ