[{"id":1849,"web_url":"https://patchwork.libcamera.org/comment/1849/","msgid":"<20190611133013.GJ5016@pendragon.ideasonboard.com>","date":"2019-06-11T13:30:13","subject":"Re: [libcamera-devel] [PATCH] test: camera: Increase runtime for\n\tcapture test","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Niklas,\n\nThank you for the patch.\n\nOn Tue, Jun 11, 2019 at 03:21:37PM +0200, Niklas Söderlund wrote:\n> Upstream commit 2978a505aaa981b2 (\"media: vimc: stream: fix thread state\n> before sleep\") changes the frame rate when capturing from the vimc raw\n> capture video nodes. The commit changes the frame rate from thousands of\n> frames per second to to roughly fifty.\n> \n> The libcamera capture test was written with the assumption that vimc\n> would keep providing this fast frame rate and ran for a very short time\n> to decrease the overall run time of tests. This is no longer possible\n> and the test fails as it can't capture enough frames in its runtime,\n> increase the runtime to match the new vimc frame rate.\n> \n> Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>\n\n:-( I suppose we have no choice.\n\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\nIs there any chance we could fix it in the kernel ?\n\n> ---\n>  test/camera/capture.cpp | 2 +-\n>  1 file changed, 1 insertion(+), 1 deletion(-)\n> \n> diff --git a/test/camera/capture.cpp b/test/camera/capture.cpp\n> index 98e71905531c76fe..7ce247cc482dfe4c 100644\n> --- a/test/camera/capture.cpp\n> +++ b/test/camera/capture.cpp\n> @@ -115,7 +115,7 @@ protected:\n>  \t\tEventDispatcher *dispatcher = CameraManager::instance()->eventDispatcher();\n>  \n>  \t\tTimer timer;\n> -\t\ttimer.start(100);\n> +\t\ttimer.start(1000);\n>  \t\twhile (timer.isRunning())\n>  \t\t\tdispatcher->processEvents();\n>","headers":{"Return-Path":"<laurent.pinchart@ideasonboard.com>","Received":["from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id CFF6362F9C\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 11 Jun 2019 15:30:28 +0200 (CEST)","from pendragon.ideasonboard.com\n\t(dfj612yhrgyx302h3jwwy-3.rev.dnainternet.fi\n\t[IPv6:2001:14ba:21f5:5b00:ce28:277f:58d7:3ca4])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 586C4FA0;\n\tTue, 11 Jun 2019 15:30:28 +0200 (CEST)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1560259828;\n\tbh=EqudAKvFY/62kw6J8MZgXpo1+KP8Qk+tyK1yx2mtl+o=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=HVc9rI8hFDRBUcUpxbyRyzJ8lAgK56VtncboJxUBP1ttduJAYifOlysz8punItsY5\n\tXaIbszIDyQBLAh8wmmIed4lSuGG03WjL4XBhqU6JVoaDYhhPGzidZajsfYYj9V75Gz\n\twWe1HcNaWsxfLcav4wRzdPDs9k7zNevdBNCdJiCw=","Date":"Tue, 11 Jun 2019 16:30:13 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Niklas =?utf-8?q?S=C3=B6derlund?= <niklas.soderlund@ragnatech.se>","Cc":"libcamera-devel@lists.libcamera.org","Message-ID":"<20190611133013.GJ5016@pendragon.ideasonboard.com>","References":"<20190611132137.7271-1-niklas.soderlund@ragnatech.se>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","Content-Transfer-Encoding":"8bit","In-Reply-To":"<20190611132137.7271-1-niklas.soderlund@ragnatech.se>","User-Agent":"Mutt/1.10.1 (2018-07-13)","Subject":"Re: [libcamera-devel] [PATCH] test: camera: Increase runtime for\n\tcapture test","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.23","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","X-List-Received-Date":"Tue, 11 Jun 2019 13:30:29 -0000"}},{"id":1852,"web_url":"https://patchwork.libcamera.org/comment/1852/","msgid":"<20190611140548.GC25229@bigcity.dyn.berto.se>","date":"2019-06-11T14:05:48","subject":"Re: [libcamera-devel] [PATCH] test: camera: Increase runtime for\n\tcapture test","submitter":{"id":5,"url":"https://patchwork.libcamera.org/api/people/5/","name":"Niklas Söderlund","email":"niklas.soderlund@ragnatech.se"},"content":"Hi Laurent,\n\nThanks for your feedback.\n\nOn 2019-06-11 16:30:13 +0300, Laurent Pinchart wrote:\n> Hi Niklas,\n> \n> Thank you for the patch.\n> \n> On Tue, Jun 11, 2019 at 03:21:37PM +0200, Niklas Söderlund wrote:\n> > Upstream commit 2978a505aaa981b2 (\"media: vimc: stream: fix thread state\n> > before sleep\") changes the frame rate when capturing from the vimc raw\n> > capture video nodes. The commit changes the frame rate from thousands of\n> > frames per second to to roughly fifty.\n> > \n> > The libcamera capture test was written with the assumption that vimc\n> > would keep providing this fast frame rate and ran for a very short time\n> > to decrease the overall run time of tests. This is no longer possible\n> > and the test fails as it can't capture enough frames in its runtime,\n> > increase the runtime to match the new vimc frame rate.\n> > \n> > Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>\n> \n> :-( I suppose we have no choice.\n> \n> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\nThanks, pushed to master with your tag.\n\n> \n> Is there any chance we could fix it in the kernel ?\n\nI'm sure we could do something in the kernel. But looking at the code it \nlooks like vimc is design to not deliver frames as fast as possible. The \nupstream commit which this patch address seems to be a bug fix. Maybe a \ndiscussion upstream to introduce a frame rate selection support on which \nsupports extremal fast frame rates could be a way forward ?\n\n> \n> > ---\n> >  test/camera/capture.cpp | 2 +-\n> >  1 file changed, 1 insertion(+), 1 deletion(-)\n> > \n> > diff --git a/test/camera/capture.cpp b/test/camera/capture.cpp\n> > index 98e71905531c76fe..7ce247cc482dfe4c 100644\n> > --- a/test/camera/capture.cpp\n> > +++ b/test/camera/capture.cpp\n> > @@ -115,7 +115,7 @@ protected:\n> >  \t\tEventDispatcher *dispatcher = CameraManager::instance()->eventDispatcher();\n> >  \n> >  \t\tTimer timer;\n> > -\t\ttimer.start(100);\n> > +\t\ttimer.start(1000);\n> >  \t\twhile (timer.isRunning())\n> >  \t\t\tdispatcher->processEvents();\n> >  \n> \n> -- \n> Regards,\n> \n> Laurent Pinchart","headers":{"Return-Path":"<niklas.soderlund@ragnatech.se>","Received":["from mail-lf1-x142.google.com (mail-lf1-x142.google.com\n\t[IPv6:2a00:1450:4864:20::142])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 6722962F77\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 11 Jun 2019 16:05:50 +0200 (CEST)","by mail-lf1-x142.google.com with SMTP id j29so9397079lfk.10\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 11 Jun 2019 07:05:50 -0700 (PDT)","from localhost (89-233-230-99.cust.bredband2.com. [89.233.230.99])\n\tby smtp.gmail.com with ESMTPSA id\n\tp15sm2659287lji.80.2019.06.11.07.05.49\n\t(version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256);\n\tTue, 11 Jun 2019 07:05:49 -0700 (PDT)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=ragnatech-se.20150623.gappssmtp.com; s=20150623;\n\th=date:from:to:cc:subject:message-id:references:mime-version\n\t:content-disposition:content-transfer-encoding:in-reply-to\n\t:user-agent; bh=G6VO1ZctL9BkCiIJ60Wfa2KZ5gRqCnbec0DPFLoz/88=;\n\tb=V3FPC98vkKJ4yIbOZ6ujr/+hleOfilFgeawyzRdsXuxhPiQE1DwI6y9leoiSGzTeVQ\n\t+506vrzRJcctdwxvqSwtrJiKFskO/lTVycGjDbnK65qzG/ktkibvB4aNY5ByABnziIyU\n\teSl2KwRszU2/1mwCB/spGFxWgo0c1aH+bOoy0ZFLw9ndiior4LX0+GDnBd7j98oPR0IN\n\tK5+UDlXYtDD/t6VhVdL+tLFnAwu80jam0OFqAv2f0kg0ueZcwq7w5zjhJM4RIDGjiROf\n\tXnQT3t85O9Zz07o14VWI/0Iby+vMMJXhOVPpvfjf13hQ4buiJSssyd/7Z+xp3hn9Fjtt\n\t06Tw==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:date:from:to:cc:subject:message-id:references\n\t:mime-version:content-disposition:content-transfer-encoding\n\t:in-reply-to:user-agent;\n\tbh=G6VO1ZctL9BkCiIJ60Wfa2KZ5gRqCnbec0DPFLoz/88=;\n\tb=pp1Phkrf8Pd1LtaFWNT+bKruZm7YqFJC0iyDH/VmB5DG49FXuC1Sw0SAgpa7HR6z/D\n\tzeK72FdpIRt2bxrp4uReqznKBC/sENhlgbiyrcN2AGE79/70QeBlIx2Mwp791rDXo8Zg\n\tlQGlfs8O18qzDl/ZeSOIFBC/h5xJ2GwqwbDBbpRrkJGKsRMgxSar0xOcTnwQAb/3d29m\n\tIZ9g+USYSa9fMyZdu8+YXTG9hzvJpjNt0Ud1OK+12SEtNUJ8ty4/vyXdwQ9avSo6S+mi\n\tjZo7rVlvDkiI7HCRDgJ8qNib/QPanBIxW2/Ot7wkxSL3VRQeKVs2H/lzbClbmJ2r4/rZ\n\tA9Lw==","X-Gm-Message-State":"APjAAAXwIcf9BahhbdWgMnyOovj+/Om6qHqoPi0ieN+TWbk6955Se9wN\n\tujTGWNlzgPUj4phaCk5BJPx2ygHdMvo=","X-Google-Smtp-Source":"APXvYqxdV+VxPchDwYQR9uJ4T05Ky7cXO0wv1RfIUcH4FPYVy7TZsG0WN79KgF8RCuVuVbi7f8xihQ==","X-Received":"by 2002:a19:ee16:: with SMTP id\n\tg22mr10879328lfb.71.1560261949850; \n\tTue, 11 Jun 2019 07:05:49 -0700 (PDT)","Date":"Tue, 11 Jun 2019 16:05:48 +0200","From":"Niklas =?iso-8859-1?q?S=F6derlund?= <niklas.soderlund@ragnatech.se>","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","Message-ID":"<20190611140548.GC25229@bigcity.dyn.berto.se>","References":"<20190611132137.7271-1-niklas.soderlund@ragnatech.se>\n\t<20190611133013.GJ5016@pendragon.ideasonboard.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=iso-8859-1","Content-Disposition":"inline","Content-Transfer-Encoding":"8bit","In-Reply-To":"<20190611133013.GJ5016@pendragon.ideasonboard.com>","User-Agent":"Mutt/1.12.0 (2019-05-25)","Subject":"Re: [libcamera-devel] [PATCH] test: camera: Increase runtime for\n\tcapture test","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.23","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","X-List-Received-Date":"Tue, 11 Jun 2019 14:05:50 -0000"}}]