[WIP,RFC,07/26] libcamera: Drop MediaBusFormatInfo::Type::EmbeddedData
diff mbox series

Message ID 20261023-b4-raw-model-v1-7-eadb9948901b@ideasonboard.com
State New
Headers show
Series
  • Support the new common raw sensor model
Related show

Commit Message

Jai Luthra Oct. 23, 2026, 10:58 a.m. UTC
The layout used by the sensor for the sensor registers or other metadata
transmitted through the embedded line is advertised through the new
V4L2_CID_METADATA_LAYOUT control, as opposed to being tied the mbus code
advertised by the sensor on the sink pad.

So drop the Type:EmbeddedData from the enum. Also drop the check for it
in the CameraSensorRaw class.

Signed-off-by: Jai Luthra <jai.luthra@ideasonboard.com>
---
 include/libcamera/internal/v4l2_subdevice.h |  1 -
 src/libcamera/sensor/camera_sensor_raw.cpp  | 13 -------------
 src/libcamera/v4l2_subdevice.cpp            |  3 ---
 3 files changed, 17 deletions(-)

Patch
diff mbox series

diff --git a/include/libcamera/internal/v4l2_subdevice.h b/include/libcamera/internal/v4l2_subdevice.h
index 93003ccf3532..510963aea668 100644
--- a/include/libcamera/internal/v4l2_subdevice.h
+++ b/include/libcamera/internal/v4l2_subdevice.h
@@ -37,7 +37,6 @@  public:
 	enum class Type {
 		Image,
 		Metadata,
-		EmbeddedData,
 	};
 
 	bool isValid() const { return code != 0; }
diff --git a/src/libcamera/sensor/camera_sensor_raw.cpp b/src/libcamera/sensor/camera_sensor_raw.cpp
index 75479813c533..59799a1c150c 100644
--- a/src/libcamera/sensor/camera_sensor_raw.cpp
+++ b/src/libcamera/sensor/camera_sensor_raw.cpp
@@ -311,19 +311,6 @@  std::optional<int> CameraSensorRaw::init()
 			break;
 
 		case MediaBusFormatInfo::Type::Metadata:
-			/*
-			 * Skip metadata streams that are not sensor embedded
-			 * data. The source stream reports a generic metadata
-			 * format, check the sink stream for the exact format.
-			 */
-			formats = subdev_->formats(route.sink);
-			if (formats.size() != 1)
-				continue;
-
-			if (MediaBusFormatInfo::info(formats.cbegin()->first).type !=
-			    MediaBusFormatInfo::Type::EmbeddedData)
-				continue;
-
 			if (streams_.edata) {
 				LOG(CameraSensor, Error)
 					<< "Multiple internal embedded data streams ("
diff --git a/src/libcamera/v4l2_subdevice.cpp b/src/libcamera/v4l2_subdevice.cpp
index db5eab9a709d..36f17e23da8e 100644
--- a/src/libcamera/v4l2_subdevice.cpp
+++ b/src/libcamera/v4l2_subdevice.cpp
@@ -81,9 +81,6 @@  LOG_DECLARE_CATEGORY(V4L2)
  *
  * \var MediaBusFormatInfo::Type::Metadata
  * \brief The format describes generic metadata
- *
- * \var MediaBusFormatInfo::Type::EmbeddedData
- * \brief The format describes sensor embedded data
  */
 
 namespace {