From patchwork Fri Dec 13 09:38:26 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Naushir Patuck X-Patchwork-Id: 22308 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 9D735C32EA for ; Fri, 13 Dec 2024 09:46:18 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id A6D6267EF4; Fri, 13 Dec 2024 10:46:14 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=raspberrypi.com header.i=@raspberrypi.com header.b="QWCCSakX"; dkim-atps=neutral Received: from mail-wm1-x32b.google.com (mail-wm1-x32b.google.com [IPv6:2a00:1450:4864:20::32b]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 92A2567EE0 for ; Fri, 13 Dec 2024 10:46:10 +0100 (CET) Received: by mail-wm1-x32b.google.com with SMTP id 5b1f17b1804b1-436246b1f9bso1996515e9.1 for ; Fri, 13 Dec 2024 01:46:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=raspberrypi.com; s=google; t=1734083170; x=1734687970; darn=lists.libcamera.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=NhZXilb32109MmYRaMgOMB8Dlf9MNDOUyVd5nWppRWI=; b=QWCCSakXTu6iAePo4+NS6nE+t2VN1F5jNcqdVJJ8Ys4d7GwmO4eHZNL+7CnmQ+3wbY wCVnZgG5W30Gautq2VrMMQC8ta6sM5K4Ub9gJyst1UMO0lN2OWDctmpSriPNcoegwgCj yKMEFsy+/P8NkafZumCaRMeQiPEWAA17oAmUqIN5BFdA0/wh8W56CMfUGslkRg3gJNZM 0p3JV8ZFR+bOku4/acVHzFzYfCjxDsM4EXzthDfQ3ZCxfQU48d5tSpXD6kNniy9QkGe2 RSV2n8UEXf3QJAt1Gpg8yC0bzhqzAeADwm06dxX4ACgoDd0aNxvM+GMa07hoV7Qa6ltI /tPA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734083170; x=1734687970; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=NhZXilb32109MmYRaMgOMB8Dlf9MNDOUyVd5nWppRWI=; b=iJ5qULVumKTl2iKliOJoknYdQTcMub50qnbDY2arzoAWFJ8Q/CbFSx39U3Z5Yxk4Lj taxHiYLGK8CGrz1EuFTJ5evd2bSHpH1pakYRFSXx7B3YhX3mNn/C2K7y26ttmDnP+GY1 dVySG3Ikbki1SzNSjsablfTU4K1MTiprP9myFoRz90PjT0mmwxFBHOeSCJZxwecMf+96 Mf7oBupSh7BNozOVBsXgDpv/DWtVUj9yE9Y2fqoZ1GmdW+c/dqirN0g50h7UCPJTy9uS vnLuOsPegqLU07dsk3cCArV4wCLyWBrSCL9l7UxRYqyuM49lywt1fj83EQ+phKI1IxXj j5Ww== X-Gm-Message-State: AOJu0YzEGz3S7ivcVB7XJc51cz2d1PxnxEbDdx91Gc6Ij0pxcdT/nGx/ /sQnAFR/F3CvPp1oJATwJXC7zRhr6+lYse3o2l7irkMdTXtlfEqgpTn6KEJwwbIOrfRE53EcwPt 9 X-Gm-Gg: ASbGncueQ0T/hMKr6Xoc0Hk4wHycj5idoainq4RavGjrhho/kUKAw9WYyLUN45k/M+A LvBcCijxpXbqR35ikIeNwF06fEdOS34D6tinD0uaj18A1DQmXJqYws5Iw/zEeAIFot19+OPaqwp pZX/FUOiLrlfZkV4Z2qgw7Q9f3Z0DY3Qo8fzoJCrERXHKUFvM4vkIqRpolxnmSQtQOmJz0CGrPG 2VLaZ7jKTrGxlzkz8nboTwT1Y7hOtmIy8kHjK8YB5I5+VFdKx4JkvXpcEt6rWpkiuPbcU7rBEyh X-Google-Smtp-Source: AGHT+IFjcK+/PGuXECU6MqsSj1gItW/RWzcnAZjiluQ5w4DEz0CpPvAGInDB1jdg8wHu3IWAdwrfyA== X-Received: by 2002:a05:600c:6d96:b0:431:4983:e8fe with SMTP id 5b1f17b1804b1-4362aab9cafmr5239755e9.9.1734083169813; Fri, 13 Dec 2024 01:46:09 -0800 (PST) Received: from NAUSH-P-DELL.pitowers.org ([93.93.133.154]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4362557c502sm43989105e9.11.2024.12.13.01.46.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Dec 2024 01:46:09 -0800 (PST) From: Naushir Patuck To: libcamera-devel@lists.libcamera.org Cc: Naushir Patuck Subject: [PATCH 3/6] ipa: rpi: Add a HW property to determine if the data buffer is strided Date: Fri, 13 Dec 2024 09:38:26 +0000 Message-ID: <20241213094602.2083174-4-naush@raspberrypi.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20241213094602.2083174-1-naush@raspberrypi.com> References: <20241213094602.2083174-1-naush@raspberrypi.com> MIME-Version: 1.0 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: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" This property (cfeDataBufferStrided) indicates if the CSI-2 hardware writes to the embedded/metadata buffer directly, or if it treats the buffer like an image buffer and strides the metadata lines. Unicam write this buffer strided, while the PiSP Frontend writes to it directly. This information will be relevant to data parsers in the helpers where the data is structured in lines. Signed-off-by: Naushir Patuck Reviewed-by: David Plowman Reviewed-by: Laurent Pinchart --- src/ipa/rpi/controller/controller.cpp | 2 ++ src/ipa/rpi/controller/controller.h | 1 + 2 files changed, 3 insertions(+) diff --git a/src/ipa/rpi/controller/controller.cpp b/src/ipa/rpi/controller/controller.cpp index e0131018e7b2..3bce88b9281e 100644 --- a/src/ipa/rpi/controller/controller.cpp +++ b/src/ipa/rpi/controller/controller.cpp @@ -39,6 +39,7 @@ static const std::map HardwareConfigMap .pipelineWidth = 13, .statsInline = false, .minPixelProcessingTime = 0s, + .cfeDataBufferStrided = true, } }, { @@ -71,6 +72,7 @@ static const std::map HardwareConfigMap * frames wider than ~16,000 pixels. */ .minPixelProcessingTime = 1.0us / 380, + .cfeDataBufferStrided = false, } }, }; diff --git a/src/ipa/rpi/controller/controller.h b/src/ipa/rpi/controller/controller.h index eff520bd61de..64f93f414524 100644 --- a/src/ipa/rpi/controller/controller.h +++ b/src/ipa/rpi/controller/controller.h @@ -49,6 +49,7 @@ public: unsigned int pipelineWidth; bool statsInline; libcamera::utils::Duration minPixelProcessingTime; + bool cfeDataBufferStrided; }; Controller();