{"id":9783,"url":"https://patchwork.libcamera.org/api/1.1/patches/9783/?format=json","web_url":"https://patchwork.libcamera.org/patch/9783/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/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":"<20200924091927.116385-4-naush@raspberrypi.com>","date":"2020-09-24T09:19:26","name":"[libcamera-devel,3/4] ipa: raspberrypi: Move IPA parameters to the RPi namespace","commit_ref":null,"pull_url":null,"state":"accepted","archived":false,"hash":"79200d2450932cae198c2cc6211d7d407102c56f","submitter":{"id":34,"url":"https://patchwork.libcamera.org/api/1.1/people/34/?format=json","name":"Naushir Patuck","email":"naush@raspberrypi.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/9783/mbox/","series":[{"id":1318,"url":"https://patchwork.libcamera.org/api/1.1/series/1318/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=1318","date":"2020-09-24T09:19:23","name":"Code tidy-ups","version":1,"mbox":"https://patchwork.libcamera.org/series/1318/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/9783/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/9783/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 BEA9DC3B5B\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 24 Sep 2020 09:19:37 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 3E60862FF1;\n\tThu, 24 Sep 2020 11:19:37 +0200 (CEST)","from mail-wr1-x42a.google.com (mail-wr1-x42a.google.com\n\t[IPv6:2a00:1450:4864:20::42a])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 351E562FD2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 24 Sep 2020 11:19:35 +0200 (CEST)","by mail-wr1-x42a.google.com with SMTP id x14so2925489wrl.12\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 24 Sep 2020 02:19:35 -0700 (PDT)","from naushir-VirtualBox.pitowers.org\n\t([2a00:1098:3142:14:a00:27ff:fe4d:f6a2])\n\tby smtp.gmail.com with ESMTPSA id\n\tw81sm2689324wmg.47.2020.09.24.02.19.33\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tThu, 24 Sep 2020 02:19:33 -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=\"jUOH85Ne\"; 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=bZdNnuuWShhFJ2cWo0wyBUFyD/FF+sve3VF3O2RU1AY=;\n\tb=jUOH85NeHl6EBanGKpPuC9YQ/a4dfkC6upGPOooJEhZaQXnL00pnybWWUMb3qnIw7K\n\tOY8wVDZHa1hwF4kq/ri7md3jvu/ZAMhsov2nbUWS3ZYVr/y/3SKrjIbhRCRjjIq9Y9It\n\tIiKr1np4sUCOOJTgg9hImnFvdpdeWFBf/tyApr5v1tB0hPBSy8mcK2liVURZBnGmkU3G\n\t0rAd51E4is3GBM0XurT7ysD8ktmbBmxOh7wUqbM9+Ps/GorJv0mdNciY8vKbIzpAIbs7\n\tGGr4eAX9YOD779EJYNHp44AVbzdEbWl5ZWT6zoofRzShbgs5djSQVc9Pf2w4ke6V0ppq\n\tvWEQ==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\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=bZdNnuuWShhFJ2cWo0wyBUFyD/FF+sve3VF3O2RU1AY=;\n\tb=WQpH9wdwOoni/+Ynv5fmurcvHa2oJ5WjHIpaSXO3LRgPdNgwUtdOkijXO7ue0UhK3v\n\tt7e6hv7GIBV7PxahG1jJzAkOoTgI0OTd+CIZW/3tsUBWVR4Grchzp4sEfRAhY09KTX34\n\t04S/qdGHQfeuu+9GUSJBMac9E1caep9zlpwvTkWlZMLXDHOOrprEeJuBqoXlGf9kW5F2\n\twzmgn52KNDkKxAxovwB9MnzMAH3gZ6mZV+DzubOK2AL82KkHJuxIr40wlib1j2/GSLCC\n\ttec9XzImrVjKWpUDjkQ6BCEGusjDj0rsrmIcBu9Qiu8whMvb6IKDDViJJH7h4AUoZBKr\n\t56xg==","X-Gm-Message-State":"AOAM532JsH21mZ9PsYHwYVb4TSXuqQK/ViFlyEaHsK0bImdbX1fuzAiG\n\t3PPP+25sYZHt9K3p3fk7FCA2slFc/yaPWw==","X-Google-Smtp-Source":"ABdhPJzGyD1FVE0F+ZPs+xK2GJ48KU9Cwomz3vMD9bPTMamp9weBuUsGHaNfmOjiq1KiNij++LLcjQ==","X-Received":"by 2002:a5d:56c1:: with SMTP id m1mr3856110wrw.87.1600939174282; \n\tThu, 24 Sep 2020 02:19:34 -0700 (PDT)","From":"Naushir Patuck <naush@raspberrypi.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Thu, 24 Sep 2020 10:19:26 +0100","Message-Id":"<20200924091927.116385-4-naush@raspberrypi.com>","X-Mailer":"git-send-email 2.25.1","In-Reply-To":"<20200924091927.116385-1-naush@raspberrypi.com>","References":"<20200924091927.116385-1-naush@raspberrypi.com>","MIME-Version":"1.0","Subject":"[libcamera-devel] [PATCH 3/4] ipa: raspberrypi: Move IPA parameters\n\tto the RPi namespace","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>","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"All IPA related types/params are now moved to the RPi namespace.\n\nThere are no functional changes in this commit.\n\nSigned-off-by: Naushir Patuck <naush@raspberrypi.com>\nReviewed-by: Jacopo Mondi <jacopo@jmondi.org>\nAcked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n include/libcamera/ipa/raspberrypi.h           | 40 ++++++++++---------\n src/ipa/raspberrypi/raspberrypi.cpp           | 30 +++++++-------\n .../pipeline/raspberrypi/raspberrypi.cpp      | 40 +++++++++----------\n .../pipeline/raspberrypi/rpi_stream.cpp       |  4 +-\n .../pipeline/raspberrypi/rpi_stream.h         |  4 +-\n 5 files changed, 61 insertions(+), 57 deletions(-)","diff":"diff --git a/include/libcamera/ipa/raspberrypi.h b/include/libcamera/ipa/raspberrypi.h\nindex dd6ebeac..c9d4aa81 100644\n--- a/include/libcamera/ipa/raspberrypi.h\n+++ b/include/libcamera/ipa/raspberrypi.h\n@@ -10,25 +10,29 @@\n #include <libcamera/control_ids.h>\n #include <libcamera/controls.h>\n \n-enum RPiConfigParameters {\n-\tRPI_IPA_CONFIG_LS_TABLE = (1 << 0),\n-\tRPI_IPA_CONFIG_STAGGERED_WRITE = (1 << 1),\n-\tRPI_IPA_CONFIG_SENSOR = (1 << 2),\n-\tRPI_IPA_CONFIG_DROP_FRAMES = (1 << 3),\n+namespace libcamera {\n+\n+namespace RPi {\n+\n+enum ConfigParameters {\n+\tIPA_CONFIG_LS_TABLE = (1 << 0),\n+\tIPA_CONFIG_STAGGERED_WRITE = (1 << 1),\n+\tIPA_CONFIG_SENSOR = (1 << 2),\n+\tIPA_CONFIG_DROP_FRAMES = (1 << 3),\n };\n \n-enum RPiOperations {\n-\tRPI_IPA_ACTION_V4L2_SET_STAGGERED = 1,\n-\tRPI_IPA_ACTION_V4L2_SET_ISP,\n-\tRPI_IPA_ACTION_STATS_METADATA_COMPLETE,\n-\tRPI_IPA_ACTION_RUN_ISP,\n-\tRPI_IPA_ACTION_EMBEDDED_COMPLETE,\n-\tRPI_IPA_EVENT_SIGNAL_STAT_READY,\n-\tRPI_IPA_EVENT_SIGNAL_ISP_PREPARE,\n-\tRPI_IPA_EVENT_QUEUE_REQUEST,\n+enum Operations {\n+\tIPA_ACTION_V4L2_SET_STAGGERED = 1,\n+\tIPA_ACTION_V4L2_SET_ISP,\n+\tIPA_ACTION_STATS_METADATA_COMPLETE,\n+\tIPA_ACTION_RUN_ISP,\n+\tIPA_ACTION_EMBEDDED_COMPLETE,\n+\tIPA_EVENT_SIGNAL_STAT_READY,\n+\tIPA_EVENT_SIGNAL_ISP_PREPARE,\n+\tIPA_EVENT_QUEUE_REQUEST,\n };\n \n-enum RPiBufferMask {\n+enum BufferMask {\n \tID\t\t= 0x00ffff,\n \tSTATS\t\t= 0x010000,\n \tEMBEDDED_DATA\t= 0x020000,\n@@ -39,10 +43,8 @@ enum RPiBufferMask {\n /* Size of the LS grid allocation. */\n #define MAX_LS_GRID_SIZE (32 << 10)\n \n-namespace libcamera {\n-\n /* List of controls handled by the Raspberry Pi IPA */\n-static const ControlInfoMap RPiControls = {\n+static const ControlInfoMap Controls = {\n \t{ &controls::AeEnable, ControlInfo(false, true) },\n \t{ &controls::ExposureTime, ControlInfo(0, 999999) },\n \t{ &controls::AnalogueGain, ControlInfo(1.0f, 32.0f) },\n@@ -60,6 +62,8 @@ static const ControlInfoMap RPiControls = {\n \t{ &controls::ColourCorrectionMatrix, ControlInfo(-16.0f, 16.0f) },\n };\n \n+} /* namespace RPi */\n+\n } /* namespace libcamera */\n \n #endif /* __LIBCAMERA_IPA_INTERFACE_RASPBERRYPI_H__ */\ndiff --git a/src/ipa/raspberrypi/raspberrypi.cpp b/src/ipa/raspberrypi/raspberrypi.cpp\nindex 1d3136be..0c0dc743 100644\n--- a/src/ipa/raspberrypi/raspberrypi.cpp\n+++ b/src/ipa/raspberrypi/raspberrypi.cpp\n@@ -224,7 +224,7 @@ void IPARPi::configure(const CameraSensorInfo &sensorInfo,\n \t\tresult->data.push_back(exposureDelay);\n \t\tresult->data.push_back(sensorMetadata);\n \n-\t\tresult->operation |= RPI_IPA_CONFIG_STAGGERED_WRITE;\n+\t\tresult->operation |= RPi::IPA_CONFIG_STAGGERED_WRITE;\n \t}\n \n \t/* Re-assemble camera mode using the sensor info. */\n@@ -250,7 +250,7 @@ void IPARPi::configure(const CameraSensorInfo &sensorInfo,\n \t}\n \n \tresult->data.push_back(drop_frame);\n-\tresult->operation |= RPI_IPA_CONFIG_DROP_FRAMES;\n+\tresult->operation |= RPi::IPA_CONFIG_DROP_FRAMES;\n \n \tstruct AgcStatus agcStatus;\n \t/* These zero values mean not program anything (unless overwritten). */\n@@ -278,13 +278,13 @@ void IPARPi::configure(const CameraSensorInfo &sensorInfo,\n \t\tapplyAGC(&agcStatus, ctrls);\n \t\tresult->controls.push_back(ctrls);\n \n-\t\tresult->operation |= RPI_IPA_CONFIG_SENSOR;\n+\t\tresult->operation |= RPi::IPA_CONFIG_SENSOR;\n \t}\n \n \tlastMode_ = mode_;\n \n \t/* Store the lens shading table pointer and handle if available. */\n-\tif (ipaConfig.operation & RPI_IPA_CONFIG_LS_TABLE) {\n+\tif (ipaConfig.operation & RPi::IPA_CONFIG_LS_TABLE) {\n \t\t/* Remove any previous table, if there was one. */\n \t\tif (lsTable_) {\n \t\t\tmunmap(lsTable_, MAX_LS_GRID_SIZE);\n@@ -340,7 +340,7 @@ void IPARPi::unmapBuffers(const std::vector<unsigned int> &ids)\n void IPARPi::processEvent(const IPAOperationData &event)\n {\n \tswitch (event.operation) {\n-\tcase RPI_IPA_EVENT_SIGNAL_STAT_READY: {\n+\tcase RPi::IPA_EVENT_SIGNAL_STAT_READY: {\n \t\tunsigned int bufferId = event.data[0];\n \n \t\tif (++check_count_ != frame_count_) /* assert here? */\n@@ -351,14 +351,14 @@ void IPARPi::processEvent(const IPAOperationData &event)\n \t\treportMetadata();\n \n \t\tIPAOperationData op;\n-\t\top.operation = RPI_IPA_ACTION_STATS_METADATA_COMPLETE;\n-\t\top.data = { bufferId & RPiBufferMask::ID };\n+\t\top.operation = RPi::IPA_ACTION_STATS_METADATA_COMPLETE;\n+\t\top.data = { bufferId & RPi::BufferMask::ID };\n \t\top.controls = { libcameraMetadata_ };\n \t\tqueueFrameAction.emit(0, op);\n \t\tbreak;\n \t}\n \n-\tcase RPI_IPA_EVENT_SIGNAL_ISP_PREPARE: {\n+\tcase RPi::IPA_EVENT_SIGNAL_ISP_PREPARE: {\n \t\tunsigned int embeddedbufferId = event.data[0];\n \t\tunsigned int bayerbufferId = event.data[1];\n \n@@ -372,13 +372,13 @@ void IPARPi::processEvent(const IPAOperationData &event)\n \n \t\t/* Ready to push the input buffer into the ISP. */\n \t\tIPAOperationData op;\n-\t\top.operation = RPI_IPA_ACTION_RUN_ISP;\n-\t\top.data = { bayerbufferId & RPiBufferMask::ID };\n+\t\top.operation = RPi::IPA_ACTION_RUN_ISP;\n+\t\top.data = { bayerbufferId & RPi::BufferMask::ID };\n \t\tqueueFrameAction.emit(0, op);\n \t\tbreak;\n \t}\n \n-\tcase RPI_IPA_EVENT_QUEUE_REQUEST: {\n+\tcase RPi::IPA_EVENT_QUEUE_REQUEST: {\n \t\tqueueRequest(event.controls[0]);\n \t\tbreak;\n \t}\n@@ -699,8 +699,8 @@ void IPARPi::queueRequest(const ControlList &controls)\n void IPARPi::returnEmbeddedBuffer(unsigned int bufferId)\n {\n \tIPAOperationData op;\n-\top.operation = RPI_IPA_ACTION_EMBEDDED_COMPLETE;\n-\top.data = { bufferId & RPiBufferMask::ID };\n+\top.operation = RPi::IPA_ACTION_EMBEDDED_COMPLETE;\n+\top.data = { bufferId & RPi::BufferMask::ID };\n \tqueueFrameAction.emit(0, op);\n }\n \n@@ -764,7 +764,7 @@ void IPARPi::prepareISP(unsigned int bufferId)\n \n \t\tif (!ctrls.empty()) {\n \t\t\tIPAOperationData op;\n-\t\t\top.operation = RPI_IPA_ACTION_V4L2_SET_ISP;\n+\t\t\top.operation = RPi::IPA_ACTION_V4L2_SET_ISP;\n \t\t\top.controls.push_back(ctrls);\n \t\t\tqueueFrameAction.emit(0, op);\n \t\t}\n@@ -824,7 +824,7 @@ void IPARPi::processStats(unsigned int bufferId)\n \t\tapplyAGC(&agcStatus, ctrls);\n \n \t\tIPAOperationData op;\n-\t\top.operation = RPI_IPA_ACTION_V4L2_SET_STAGGERED;\n+\t\top.operation = RPi::IPA_ACTION_V4L2_SET_STAGGERED;\n \t\top.controls.push_back(ctrls);\n \t\tqueueFrameAction.emit(0, op);\n \t}\ndiff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\nindex 5ed74d51..35dbe0fb 100644\n--- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n+++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n@@ -837,7 +837,7 @@ bool PipelineHandlerRPi::match(DeviceEnumerator *enumerator)\n \t}\n \n \t/* Register the controls that the Raspberry Pi IPA can handle. */\n-\tdata->controlInfo_ = RPiControls;\n+\tdata->controlInfo_ = RPi::Controls;\n \t/* Initialize the camera properties. */\n \tdata->properties_ = data->sensor_->properties();\n \n@@ -925,8 +925,8 @@ int PipelineHandlerRPi::prepareBuffers(Camera *camera)\n \t * Pass the stats and embedded data buffers to the IPA. No other\n \t * buffers need to be passed.\n \t */\n-\tmapBuffers(camera, data->isp_[Isp::Stats].getBuffers(), RPiBufferMask::STATS);\n-\tmapBuffers(camera, data->unicam_[Unicam::Embedded].getBuffers(), RPiBufferMask::EMBEDDED_DATA);\n+\tmapBuffers(camera, data->isp_[Isp::Stats].getBuffers(), RPi::BufferMask::STATS);\n+\tmapBuffers(camera, data->unicam_[Unicam::Embedded].getBuffers(), RPi::BufferMask::EMBEDDED_DATA);\n \n \treturn 0;\n }\n@@ -1017,7 +1017,7 @@ int RPiCameraData::configureIPA()\n \t\t\treturn -ENOMEM;\n \n \t\t/* Allow the IPA to mmap the LS table via the file descriptor. */\n-\t\tipaConfig.operation = RPI_IPA_CONFIG_LS_TABLE;\n+\t\tipaConfig.operation = RPi::IPA_CONFIG_LS_TABLE;\n \t\tipaConfig.data = { static_cast<unsigned int>(lsTable_.fd()) };\n \t}\n \n@@ -1035,7 +1035,7 @@ int RPiCameraData::configureIPA()\n \t\t\t&result);\n \n \tunsigned int resultIdx = 0;\n-\tif (result.operation & RPI_IPA_CONFIG_STAGGERED_WRITE) {\n+\tif (result.operation & RPi::IPA_CONFIG_STAGGERED_WRITE) {\n \t\t/*\n \t\t * Setup our staggered control writer with the sensor default\n \t\t * gain and exposure delays.\n@@ -1048,13 +1048,13 @@ int RPiCameraData::configureIPA()\n \t\t}\n \t}\n \n-\tif (result.operation & RPI_IPA_CONFIG_SENSOR) {\n+\tif (result.operation & RPi::IPA_CONFIG_SENSOR) {\n \t\tconst ControlList &ctrls = result.controls[0];\n \t\tif (!staggeredCtrl_.set(ctrls))\n \t\t\tLOG(RPI, Error) << \"V4L2 staggered set failed\";\n \t}\n \n-\tif (result.operation & RPI_IPA_CONFIG_DROP_FRAMES) {\n+\tif (result.operation & RPi::IPA_CONFIG_DROP_FRAMES) {\n \t\t/* Configure the number of dropped frames required on startup. */\n \t\tdropFrameCount_ = result.data[resultIdx++];\n \t}\n@@ -1070,14 +1070,14 @@ void RPiCameraData::queueFrameAction([[maybe_unused]] unsigned int frame,\n \t * a stopped state.\n \t */\n \tswitch (action.operation) {\n-\tcase RPI_IPA_ACTION_V4L2_SET_STAGGERED: {\n+\tcase RPi::IPA_ACTION_V4L2_SET_STAGGERED: {\n \t\tconst ControlList &controls = action.controls[0];\n \t\tif (!staggeredCtrl_.set(controls))\n \t\t\tLOG(RPI, Error) << \"V4L2 staggered set failed\";\n \t\tgoto done;\n \t}\n \n-\tcase RPI_IPA_ACTION_V4L2_SET_ISP: {\n+\tcase RPi::IPA_ACTION_V4L2_SET_ISP: {\n \t\tControlList controls = action.controls[0];\n \t\tisp_[Isp::Input].dev()->setControls(&controls);\n \t\tgoto done;\n@@ -1092,7 +1092,7 @@ void RPiCameraData::queueFrameAction([[maybe_unused]] unsigned int frame,\n \t * is in a stopped state.\n \t */\n \tswitch (action.operation) {\n-\tcase RPI_IPA_ACTION_STATS_METADATA_COMPLETE: {\n+\tcase RPi::IPA_ACTION_STATS_METADATA_COMPLETE: {\n \t\tunsigned int bufferId = action.data[0];\n \t\tFrameBuffer *buffer = isp_[Isp::Stats].getBuffers().at(bufferId);\n \n@@ -1103,14 +1103,14 @@ void RPiCameraData::queueFrameAction([[maybe_unused]] unsigned int frame,\n \t\tbreak;\n \t}\n \n-\tcase RPI_IPA_ACTION_EMBEDDED_COMPLETE: {\n+\tcase RPi::IPA_ACTION_EMBEDDED_COMPLETE: {\n \t\tunsigned int bufferId = action.data[0];\n \t\tFrameBuffer *buffer = unicam_[Unicam::Embedded].getBuffers().at(bufferId);\n \t\thandleStreamBuffer(buffer, &unicam_[Unicam::Embedded]);\n \t\tbreak;\n \t}\n \n-\tcase RPI_IPA_ACTION_RUN_ISP: {\n+\tcase RPi::IPA_ACTION_RUN_ISP: {\n \t\tunsigned int bufferId = action.data[0];\n \t\tFrameBuffer *buffer = unicam_[Unicam::Image].getBuffers().at(bufferId);\n \n@@ -1228,8 +1228,8 @@ void RPiCameraData::ispOutputDequeue(FrameBuffer *buffer)\n \t */\n \tif (stream == &isp_[Isp::Stats]) {\n \t\tIPAOperationData op;\n-\t\top.operation = RPI_IPA_EVENT_SIGNAL_STAT_READY;\n-\t\top.data = { RPiBufferMask::STATS | static_cast<unsigned int>(index) };\n+\t\top.operation = RPi::IPA_EVENT_SIGNAL_STAT_READY;\n+\t\top.data = { RPi::BufferMask::STATS | static_cast<unsigned int>(index) };\n \t\tipa_->processEvent(op);\n \t} else {\n \t\t/* Any other ISP output can be handed back to the application now. */\n@@ -1334,7 +1334,7 @@ void RPiCameraData::handleExternalBuffer(FrameBuffer *buffer, RPi::Stream *strea\n {\n \tunsigned int id = stream->getBufferId(buffer);\n \n-\tif (!(id & RPiBufferMask::EXTERNAL_BUFFER))\n+\tif (!(id & RPi::BufferMask::EXTERNAL_BUFFER))\n \t\treturn;\n \n \t/* Stop the Stream object from tracking the buffer. */\n@@ -1454,7 +1454,7 @@ void RPiCameraData::tryRunPipeline()\n \t * queue the ISP output buffer listed in the request to start the HW\n \t * pipeline.\n \t */\n-\top.operation = RPI_IPA_EVENT_QUEUE_REQUEST;\n+\top.operation = RPi::IPA_EVENT_QUEUE_REQUEST;\n \top.controls = { request->controls() };\n \tipa_->processEvent(op);\n \n@@ -1468,13 +1468,13 @@ void RPiCameraData::tryRunPipeline()\n \tunsigned int bayerId = unicam_[Unicam::Image].getBufferId(bayerBuffer);\n \tunsigned int embeddedId = unicam_[Unicam::Embedded].getBufferId(embeddedBuffer);\n \n-\tLOG(RPI, Debug) << \"Signalling RPI_IPA_EVENT_SIGNAL_ISP_PREPARE:\"\n+\tLOG(RPI, Debug) << \"Signalling RPi::IPA_EVENT_SIGNAL_ISP_PREPARE:\"\n \t\t\t<< \" Bayer buffer id: \" << bayerId\n \t\t\t<< \" Embedded buffer id: \" << embeddedId;\n \n-\top.operation = RPI_IPA_EVENT_SIGNAL_ISP_PREPARE;\n-\top.data = { RPiBufferMask::EMBEDDED_DATA | embeddedId,\n-\t\t    RPiBufferMask::BAYER_DATA | bayerId };\n+\top.operation = RPi::IPA_EVENT_SIGNAL_ISP_PREPARE;\n+\top.data = { RPi::BufferMask::EMBEDDED_DATA | embeddedId,\n+\t\t    RPi::BufferMask::BAYER_DATA | bayerId };\n \tipa_->processEvent(op);\n }\n \ndiff --git a/src/libcamera/pipeline/raspberrypi/rpi_stream.cpp b/src/libcamera/pipeline/raspberrypi/rpi_stream.cpp\nindex 3ee859e9..1a42cc17 100644\n--- a/src/libcamera/pipeline/raspberrypi/rpi_stream.cpp\n+++ b/src/libcamera/pipeline/raspberrypi/rpi_stream.cpp\n@@ -70,7 +70,7 @@ int Stream::getBufferId(FrameBuffer *buffer) const\n \n void Stream::setExternalBuffer(FrameBuffer *buffer)\n {\n-\tbufferMap_.emplace(RPiBufferMask::EXTERNAL_BUFFER | id_.get(), buffer);\n+\tbufferMap_.emplace(RPi::BufferMask::EXTERNAL_BUFFER | id_.get(), buffer);\n }\n \n void Stream::removeExternalBuffer(FrameBuffer *buffer)\n@@ -78,7 +78,7 @@ void Stream::removeExternalBuffer(FrameBuffer *buffer)\n \tint id = getBufferId(buffer);\n \n \t/* Ensure we have this buffer in the stream, and it is marked external. */\n-\tASSERT(id != -1 && (id & RPiBufferMask::EXTERNAL_BUFFER));\n+\tASSERT(id != -1 && (id & RPi::BufferMask::EXTERNAL_BUFFER));\n \tbufferMap_.erase(id);\n }\n \ndiff --git a/src/libcamera/pipeline/raspberrypi/rpi_stream.h b/src/libcamera/pipeline/raspberrypi/rpi_stream.h\nindex cb097e1c..0b502f64 100644\n--- a/src/libcamera/pipeline/raspberrypi/rpi_stream.h\n+++ b/src/libcamera/pipeline/raspberrypi/rpi_stream.h\n@@ -31,13 +31,13 @@ class Stream : public libcamera::Stream\n {\n public:\n \tStream()\n-\t\t: id_(RPiBufferMask::ID)\n+\t\t: id_(RPi::BufferMask::ID)\n \t{\n \t}\n \n \tStream(const char *name, MediaEntity *dev, bool importOnly = false)\n \t\t: external_(false), importOnly_(importOnly), name_(name),\n-\t\t  dev_(std::make_unique<V4L2VideoDevice>(dev)), id_(RPiBufferMask::ID)\n+\t\t  dev_(std::make_unique<V4L2VideoDevice>(dev)), id_(RPi::BufferMask::ID)\n \t{\n \t}\n \n","prefixes":["libcamera-devel","3/4"]}