{"id":14376,"url":"https://patchwork.libcamera.org/api/covers/14376/?format=json","web_url":"https://patchwork.libcamera.org/cover/14376/","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":"<20211028084646.453775-1-naush@raspberrypi.com>","date":"2021-10-28T08:46:36","name":"[libcamera-devel,v4,00/10] Raspberry Pi: Conversion to media controller","submitter":{"id":34,"url":"https://patchwork.libcamera.org/api/people/34/?format=json","name":"Naushir Patuck","email":"naush@raspberrypi.com"},"mbox":"https://patchwork.libcamera.org/cover/14376/mbox/","series":[{"id":2671,"url":"https://patchwork.libcamera.org/api/series/2671/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=2671","date":"2021-10-28T08:46:36","name":"Raspberry Pi: Conversion to media controller","version":4,"mbox":"https://patchwork.libcamera.org/series/2671/mbox/"}],"comments":"https://patchwork.libcamera.org/api/covers/14376/comments/","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 25133BF415\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 28 Oct 2021 08:46:56 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 4C603600C0;\n\tThu, 28 Oct 2021 10:46:55 +0200 (CEST)","from mail-wm1-x32b.google.com (mail-wm1-x32b.google.com\n\t[IPv6:2a00:1450:4864:20::32b])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 7316E600B5\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 28 Oct 2021 10:46:53 +0200 (CEST)","by mail-wm1-x32b.google.com with SMTP id\n\t67-20020a1c1946000000b0030d4c90fa87so4447051wmz.2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 28 Oct 2021 01:46:53 -0700 (PDT)","from naush-laptop.pitowers.org\n\t([2a00:1098:3142:14:b894:feb0:b828:13b])\n\tby smtp.gmail.com with ESMTPSA id\n\tz2sm1955281wmk.19.2021.10.28.01.46.51\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tThu, 28 Oct 2021 01:46:52 -0700 (PDT)"],"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=\"IiUrof3l\"; 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:mime-version\n\t:content-transfer-encoding;\n\tbh=DoKbgAcOJJxIWbOm/PaLjhPLWy9RpzmOGRb7vqnde/s=;\n\tb=IiUrof3lODZ97tMFnoz1Gy7WcLHfBCQ4MQwfQFRqI3RIcVgDEH01LooAoyhky6QrIq\n\tO9NpUTJA0bmxQdRRMjq9dFfko5WDlP6rKRVwpLYtJaHUTIa5dsHvu0aGLCtGl8uW545T\n\tgNBgvo3ukEhsc5jLWbNffXJ5jC6ELH03tHhFIBN38TREeMppwoDYn5gk9f3CExMQQSKZ\n\tj3kI0rI5ED5ZvbXGMUvBDD0BKMgRTsF/q1KJmGvEhASXglcT4lPuo7ayVCljjoY24Sxz\n\t8sLOIeIyTNvXIcr6jFDhUNXB5GCNzgLGHLkuz+R4a16t18HZ0sERWty5ex2YoVNJoiqx\n\taERQ==","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:mime-version\n\t:content-transfer-encoding;\n\tbh=DoKbgAcOJJxIWbOm/PaLjhPLWy9RpzmOGRb7vqnde/s=;\n\tb=dCFpGxR0MivZTwvsFfTjbm5faO8cfpWGv6bHusAhBy86bPsO3mxjDidULcyneW23wK\n\tEbNq5ZdQx9a3fsOuSVQVW/7Aanap9WhElLb6uPz6DChU71j3RuIrXtUgZ40euKKYWoxD\n\tgQi7wr9v8EdvdRILKFp5M28RlFKu9NK5fqOqlzFbXE2PZ6SqeYrTZIsUk2s1idGJnxEO\n\thkT+/Yfm4VVtQA7I6433bFOv2ixkXwjjaFvE/MWkmvRB+rznuk005Z+1MxmeDC3GI8vM\n\touFXH+LALF/sZTw1/6r4IPE7N/B/en2H8PENSuZNjkDWgH3NCaRQzFgodPzjZX4ACgQH\n\tjEPw==","X-Gm-Message-State":"AOAM533I51fLLzbjzmqijMHrDvx0/ZefOtaGgyE/AdJOkUoEs2ILRRIu\n\teM5Y8B+4i3zSaHlcktkX2jBkx4kxYCu8g7+i","X-Google-Smtp-Source":"ABdhPJxYp9SXfzob1mJd2XDwCuYGVPRpFf89oJnwj+pJ34pWxw9UK1VJa1tsdTDRDR2rnumUKJQ7WQ==","X-Received":"by 2002:a1c:8093:: with SMTP id\n\tb141mr1630282wmd.129.1635410812751; \n\tThu, 28 Oct 2021 01:46:52 -0700 (PDT)","From":"Naushir Patuck <naush@raspberrypi.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Thu, 28 Oct 2021 09:46:36 +0100","Message-Id":"<20211028084646.453775-1-naush@raspberrypi.com>","X-Mailer":"git-send-email 2.25.1","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH v4 00/10] Raspberry Pi: Conversion to\n\tmedia controller","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":"Hi,\n\nVersion 4 of this series picks up a few more commits and changes:\n\n- Patch 3/10 from Laurent added to use scoped enums for BayerFormat::Packing.\n- Patch 4/10 adds formats::R10_CSI2P (10-bit mono packed) format. This can be\nmerged with 2/10 if folks think that is more appropriate.\n- In 6/10 I've made the conversion table search success/failure return path\nconsistent with the rest of the file.\n- I've moved the patch to setup h/v flips ahead of the other changes in 7/10.\nThis reduces code churn and avoids making the MC changes in parts of the code\nthat will eventually be deleted.\n- In 8/10, reverted back to using the BayerFormat conversion table instead of\nusing a local one.\n- In 8/10  merged the packing considations that were previously in a spearate\ncommit to reduce code churn in this series.\n- In 8/10 added a new helper mbusCodeToPixelFormat() to replace the old mbusCodeToBayerFormat().\nThis reduces the number of overall lookups needed for our conversions, and also \naccounts for packing options.\n\nGiven the changes to 8/10, I've removed all existing tags for folk to have a re-review of\nthat change.\n\nThanks,\nNaush\n\nLaurent Pinchart (3):\n  include: drm_fourcc: Add R10 and R12 FourCC\n  libcamera: formats: Add R10 and R12 formats\n  libcamera: bayer_format: Turn BayerFormat::Packing into scoped enum\n\nNaushir Patuck (7):\n  libcamera: formats: Add R10_CSI2P format\n  libcamera: bayer_format: Rework BayerFormat conversion table\n  libcamera: bayer_format: Add PixelFormat conversion helpers to\n    BayerFormat class\n  pipeline: raspberrypi: Apply sensor flips at the start of configure()\n  pipeline: raspberrypi: Convert the pipeline handler to use media\n    controller\n  pipeline: raspberrypi: Remove \"unpacked\" format penalty in mode\n    selection\n  pipeline: raspberrypi: Account for a missing Unicam embedded data node\n\n include/libcamera/internal/bayer_format.h     |  10 +-\n include/linux/drm_fourcc.h                    |   6 +\n src/libcamera/bayer_format.cpp                | 219 ++++++++++------\n src/libcamera/formats.cpp                     |  39 +++\n src/libcamera/formats.yaml                    |   8 +\n .../pipeline/raspberrypi/raspberrypi.cpp      | 238 +++++++++++-------\n src/libcamera/v4l2_pixelformat.cpp            |   4 +\n test/bayer-format.cpp                         |  28 +--\n 8 files changed, 363 insertions(+), 189 deletions(-)"}