<div dir="ltr">Thanks for working on this!<div><br></div><div>+       uint8_t maxPipelineDepth = 1;<br></div><div>Should this keep the original value, i.e. = 5?</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Aug 28, 2019 at 10:12 PM Jacopo Mondi <<a href="mailto:jacopo@jmondi.org">jacopo@jmondi.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">The ANDROID_REQUEST_PIPELINE_MAX_DEPTH metadata tag was wrongly<br>
reported in the capture settings template, while it is actually a static<br>
camera metadata.<br>
<br>
As of Chromium R78 the absence of this specific metadata tag causes a<br>
system crash. Fix this by reporting the maximum pipeline depth in the<br>
static metadata pack and set its value to 1 as currently no control is<br>
applied to the image capture pipeline.<br>
<br>
Reported-by: Laurent Pinchart <<a href="mailto:laurent.pinchart@ideasonboard.com" target="_blank">laurent.pinchart@ideasonboard.com</a>><br>
Suggested-by: Ren-Pei Zeng <<a href="mailto:kamesan@google.com" target="_blank">kamesan@google.com</a>><br>
Signed-off-by: Jacopo Mondi <<a href="mailto:jacopo@jmondi.org" target="_blank">jacopo@jmondi.org</a>><br>
<br>
---<br>
Laurent, as you're running R78 and first reported the crash, could you please<br>
give this a spin and report if the issue is still present?<br>
<br>
---<br>
 src/android/camera_device.cpp | 13 +++++++------<br>
 1 file changed, 7 insertions(+), 6 deletions(-)<br>
<br>
diff --git a/src/android/camera_device.cpp b/src/android/camera_device.cpp<br>
index c27175ac090d..7c69d0810eee 100644<br>
--- a/src/android/camera_device.cpp<br>
+++ b/src/android/camera_device.cpp<br>
@@ -281,6 +281,13 @@ camera_metadata_t *CameraDevice::getStaticMetadata()<br>
                        ANDROID_INFO_SUPPORTED_HARDWARE_LEVEL,<br>
                        &supportedHWLevel, 1);<br>
<br>
+       /* Request static metadata. */<br>
+       uint8_t maxPipelineDepth = 1;<br>
+       ret = add_camera_metadata_entry(staticMetadata_,<br>
+                       ANDROID_REQUEST_PIPELINE_MAX_DEPTH,<br>
+                       &maxPipelineDepth, 1);<br>
+       METADATA_ASSERT(ret);<br>
+<br>
        return staticMetadata_;<br>
 }<br>
<br>
@@ -340,12 +347,6 @@ const camera_metadata_t *CameraDevice::constructDefaultRequestSettings(int type)<br>
                        maxOutStream, 3);<br>
        METADATA_ASSERT(ret);<br>
<br>
-       uint8_t maxPipelineDepth = 5;<br>
-       ret = add_camera_metadata_entry(requestTemplate_,<br>
-                       ANDROID_REQUEST_PIPELINE_MAX_DEPTH,<br>
-                       &maxPipelineDepth, 1);<br>
-       METADATA_ASSERT(ret);<br>
-<br>
        int32_t inputStreams = 0;<br>
        ret = add_camera_metadata_entry(requestTemplate_,<br>
                        ANDROID_REQUEST_MAX_NUM_INPUT_STREAMS,<br>
--<br>
2.23.0<br>
<br>
</blockquote></div>