From patchwork Fri Mar 25 09:08:55 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Naushir Patuck X-Patchwork-Id: 15541 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 80946C0F1B for ; Fri, 25 Mar 2022 09:09:08 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 4B065604DB; Fri, 25 Mar 2022 10:09:08 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1648199348; bh=2KpHAcuZcelKuPKtSk4W6xtCVQF10NEleoa85f4R3bM=; h=To:Date:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=OVW188p7JJRtnGg+aSNYDAwOUerTZTBkwM1A4pkjtXa+UMNhdjwfZdYUHAfwYaIeO u0lAf+GKKD/v59GkJnIZRvOs6xHtp9MXFska54RjS+2RUVqE2f11rH3bNJSpym8xeV ja5nSWUx+EDXH+hAyuXp+0C0AsPV9Ic6RFHJx2GEaZQrm5J5bNqB7fxgoH1p/6ouIi mntAIUjHU/4wATbxb0aMNrR3MVlg+dnSJXOSF+9ZJYF6xzcY1AuG9ounFIqbo1HMxT j60bVtqRor7I4qNJQOLDmLflyJCojBz6Hlv2QguIn/Iyzp7mQ8wf9+UvxNPaW4AWKq 6KaYmpW+AJc5w== Received: from mail-wr1-x429.google.com (mail-wr1-x429.google.com [IPv6:2a00:1450:4864:20::429]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id A272C60136 for ; Fri, 25 Mar 2022 10:09:06 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=raspberrypi.com header.i=@raspberrypi.com header.b="Xqd67YFG"; dkim-atps=neutral Received: by mail-wr1-x429.google.com with SMTP id w4so9926821wrg.12 for ; Fri, 25 Mar 2022 02:09:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=raspberrypi.com; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=jfENG018HePX2dXtXcDWNATA1SiEQ471Tf4uZsMY+7A=; b=Xqd67YFG6NuJynbyOeRVSMsgbmecjl3ReWHEKIkM8RRV6g0Ywj1uHk0kA5HW9vVdOZ q7dwzxaOGl9EWCr7RFeg/ggywh0Y6czCKIQ4fxmr6JJ8cm3H6ILF/5QNxZ/av2w8nLx/ y3+huNaaUXTLorVn2lzulWqjN9h0VQ40cCc1gNGfuMZ/l0PCq/8Dp6I/nCrO1ZFf7sl5 HdAC0fK8p7YfPQoh+8OYnrqCJsY8EslvYJQ2H7Ye3EVkL8nVhy1+Su/i7xZuQFJZZeGd HdlCKxN1JWVN2OMOQxe7iWitDSbbCUlgcxnL/pB7yG1GWw1TYLOyOCps0ecjBTMn/tmG LWew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=jfENG018HePX2dXtXcDWNATA1SiEQ471Tf4uZsMY+7A=; b=OjAa1VktUumzl7ne7XcjzUP4z3OhaE9zl7R3M0RSQJKTdK//vWnY6RBlaI4bMh/XYq CejezA6x+F55yDURUCxrZHzCsszi/ePa433l3hVSBcWf7FSmseafxXTireW3XkzceV/y CY5Dhs3eWbf0TLXEI0uQBb42NK85pi89Tw/fKXdfVHce0rTU1td4DyLPtYUKQ+S0nd0x BV7CblblikN04nhBAw9KsSM/buqsQFtF7RAxqjLUVtY2U8lTb/uZeCfQYxOOVEnFce/i 19DPSmr/1T7PiTzw/JdEp+vYUi9RHZaWopADFo3iQKlbIdOq0qrAFzmBm6wX9mCGAwNE +M5g== X-Gm-Message-State: AOAM531vC3Lw5PterwrbBdZFSLDVmi2StN/9aijW3XtHbJZDeQtLF1Mp JqkE2NtyQwKzm+it/9++NVbCimxshe2qsg== X-Google-Smtp-Source: ABdhPJydmI/5xMDFysf6dBs/WUuA64dQHJuQVOEOJ+RFPAHabLHiyQfo8SztYotQUig7zbdPd1CeSQ== X-Received: by 2002:adf:d1eb:0:b0:205:a502:d2ff with SMTP id g11-20020adfd1eb000000b00205a502d2ffmr1912254wrd.125.1648199346098; Fri, 25 Mar 2022 02:09:06 -0700 (PDT) Received: from naush-laptop.pitowers.org ([2a00:1098:3142:14:478c:773f:4734:d0bc]) by smtp.gmail.com with ESMTPSA id c4-20020a056000184400b0020584c40778sm4915297wri.103.2022.03.25.02.09.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Mar 2022 02:09:05 -0700 (PDT) To: libcamera-devel@lists.libcamera.org Date: Fri, 25 Mar 2022 09:08:55 +0000 Message-Id: <20220325090903.880311-1-naush@raspberrypi.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v5 0/8] Raspberry Pi: Efficient start/stop/start sequences X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Naushir Patuck via libcamera-devel From: Naushir Patuck Reply-To: Naushir Patuck Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Hi, Version 5 of this series changes the following: - In patch 6/8 use -ESHUTDOWN instead of -EPERM. - In patch 6/8 reference the function directly in the doxygen comments. Patch 6/8 needs one more R-B tag, then this series should be ready for merging. Regards, Naush Naushir Patuck (8): pipeline: raspberrypi: Avoid over-allocation for ISP Output 1 pipeline: raspberrypi: Move freeBuffers() to the RPiCameraData class pipeline: raspberrypi: Free buffers in the RPiCamera destructor and re-configure pipeline: raspberrypi: Repurpose RPi::Stream::reset() libcamera: v4l2_videodevice: Better tracking of the device state libcamera: v4l2_videodevice: Do not allow buffer queueing in stopping state libcamera: v4l2_videodevice: Empty the V4L2 buffer cache on streamOff() test: Test V4L2BufferCache::isEmpty() member function include/libcamera/internal/v4l2_videodevice.h | 4 +- .../pipeline/raspberrypi/raspberrypi.cpp | 56 ++++++++++++------- .../pipeline/raspberrypi/rpi_stream.cpp | 13 ++--- .../pipeline/raspberrypi/rpi_stream.h | 2 +- src/libcamera/v4l2_videodevice.cpp | 34 +++++++++-- test/v4l2_videodevice/buffer_cache.cpp | 36 ++++++++++++ 6 files changed, 112 insertions(+), 33 deletions(-)