{"id":14637,"url":"https://patchwork.libcamera.org/api/patches/14637/?format=json","web_url":"https://patchwork.libcamera.org/patch/14637/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20211118164216.2669449-5-naush@raspberrypi.com>","date":"2021-11-18T16:42:16","name":"[libcamera-devel,v3,4/4] pipeline: raspberrypi: Avoid invalid PixelFormat warning message","commit_ref":"dbd2e30ee3bfd1dded8048693d577dded664d05b","pull_url":null,"state":"accepted","archived":false,"hash":"ff815193a3211cfeacd116a16e30a241f5697e80","submitter":{"id":34,"url":"https://patchwork.libcamera.org/api/people/34/?format=json","name":"Naushir Patuck","email":"naush@raspberrypi.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/14637/mbox/","series":[{"id":2727,"url":"https://patchwork.libcamera.org/api/series/2727/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=2727","date":"2021-11-18T16:42:12","name":"raspberrypi: Rework the internal buffer allocation scheme","version":3,"mbox":"https://patchwork.libcamera.org/series/2727/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/14637/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/14637/checks/","tags":{},"headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 9C434BDB1C\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 18 Nov 2021 16:43:24 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 5BBD060371;\n\tThu, 18 Nov 2021 17:43:24 +0100 (CET)","from mail-wr1-x436.google.com (mail-wr1-x436.google.com\n\t[IPv6:2a00:1450:4864:20::436])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 9F21660231\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 18 Nov 2021 17:43:23 +0100 (CET)","by mail-wr1-x436.google.com with SMTP id a9so12760225wrr.8\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 18 Nov 2021 08:43:23 -0800 (PST)","from naush-laptop.pitowers.org\n\t([2a00:1098:3142:14:328d:499d:f54a:e461])\n\tby smtp.gmail.com with ESMTPSA id\n\ta1sm496246wri.89.2021.11.18.08.43.19\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tThu, 18 Nov 2021 08:43:21 -0800 (PST)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=raspberrypi.com header.i=@raspberrypi.com\n\theader.b=\"g0aPQmn3\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references\n\t:mime-version:content-transfer-encoding;\n\tbh=WSxb4/4PrjoEknlE7tK2I4wOz4SjJt6N50Kw+mOFMJI=;\n\tb=g0aPQmn3N2l9BaF9+C0XmH/M1GfZjPt1aRTjLCjtbbkoSxOjCuTja/j5WboTXb2Vpb\n\tjZqU7vVwwn7Nr1PqcdqE6bcilDFleXkzk58gK6MjhfNo8fvqgS2vc3AC+7/mM6S7z+ew\n\tnaky2fzyW3gdSVfabzgPAYor8WCyYCpXYxMsLyAob3po/OWd7WYhlLKAQt7Y2Qxmit3m\n\t/vEqM+bsGV6WVkp1vdrnNLTwWdaUzSRzhSJOLyJdnxEraN/B7WAJ+gr1ZZC2T4b7YPAd\n\tJwkXoj8ZfkIX2RV9mVMWCMnce8Pk50Q6OGbpVHRRtiMVTMCI6ol7HB5Mu/dPcRuDcWE6\n\tPAKw==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20210112;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references:mime-version:content-transfer-encoding;\n\tbh=WSxb4/4PrjoEknlE7tK2I4wOz4SjJt6N50Kw+mOFMJI=;\n\tb=BYKTDp97iB2t+ucSDfgoHn/VBT36+aoI40Eek+gtpOKwFyQPewTDoZzN25fa/hsj2a\n\tpqumADApgPRTxIw1WSSZzHgg2nv13T77h8y2kL0CK2gJO8yfXeJBfTtnIWRusWOqumMx\n\t/HHz22UCQGpnoOnaRzcnvcg+kluh6nqsUUM+VRR6ScP8YsKKWxMI0N3hbgM4QzbZVgN1\n\tQKlIsJ0d/52+8I56rPzGOSKpIcxqPLHRcR0TfJGm6JtxuRVEkS3tIyNTGKXCl5wza5bD\n\tqOtEhCyI+kDnKTqHXCG5PPqtNJ8TX/bzy8YUx5wxUZKa+3wq6ygUAK0gpnHcNJTOKe9b\n\t7yKg==","X-Gm-Message-State":"AOAM531afLKMXmMtMLx0shlAvJZ0HWRIhclLSWd6VJpZ8HLnBqB2haCo\n\tffHJnE/x7lCVOEAjqCiUgpRrAn75oPnSG0nx","X-Google-Smtp-Source":"ABdhPJxpCtfT5R/EWqsENB3O6Njs/DOPhjkJqF1JE+bBu8DSADy58YNfPN6DMOlwBUHGjgGV10Macw==","X-Received":"by 2002:a5d:6d0b:: with SMTP id\n\te11mr33004751wrq.16.1637253803198; \n\tThu, 18 Nov 2021 08:43:23 -0800 (PST)","From":"Naushir Patuck <naush@raspberrypi.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Thu, 18 Nov 2021 16:42:16 +0000","Message-Id":"<20211118164216.2669449-5-naush@raspberrypi.com>","X-Mailer":"git-send-email 2.25.1","In-Reply-To":"<20211118164216.2669449-1-naush@raspberrypi.com>","References":"<20211118164216.2669449-1-naush@raspberrypi.com>","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH v3 4/4] pipeline: raspberrypi: Avoid\n\tinvalid PixelFormat warning message","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","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>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"PixelFormatInfo::info() would log a warning message if the PixelFormat was\ninvalid when called from the isRaw() function. Add a validity test in isRaw()\nto avoid this warning message.\n\nSigned-off-by: Naushir Patuck <naush@raspberrypi.com>\n---\n src/libcamera/pipeline/raspberrypi/raspberrypi.cpp | 3 +++\n 1 file changed, 3 insertions(+)","diff":"diff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\nindex 4f6c699a4379..ad526a8be6a2 100644\n--- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n+++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n@@ -102,6 +102,9 @@ bool isRaw(const PixelFormat &pixFmt)\n \t * The isRaw test might be redundant right now the pipeline handler only\n \t * supports RAW sensors. Leave it in for now, just as a sanity check.\n \t */\n+\tif (!pixFmt.isValid())\n+\t\treturn false;\n+\n \tconst PixelFormatInfo &info = PixelFormatInfo::info(pixFmt);\n \tif (!info.isValid())\n \t\treturn false;\n","prefixes":["libcamera-devel","v3","4/4"]}