diff mbox series

v4l2-compliance: Do not run test requiring pthread_cancel in Android

Message ID 20241120-sigkill-v1-1-50c667e08cce@chromium.org
State New
Headers show
Series v4l2-compliance: Do not run test requiring pthread_cancel in Android | expand

Commit Message

Ricardo Ribalda Nov. 20, 2024, 9:11 p.m. UTC
pthread_cancel() is not available in the Android NDK. Disable the test
that depends on it.

Signed-off-by: Ricardo Ribalda <ribalda@chromium.org>
---
 utils/v4l2-compliance/v4l2-test-buffers.cpp | 6 ++++++
 1 file changed, 6 insertions(+)


---
base-commit: 625e604c48fa3c4e9737fa1ec8e1d473a378ca9c
change-id: 20241120-sigkill-af4b23ddccc8

Best regards,
diff mbox series

Patch

diff --git a/utils/v4l2-compliance/v4l2-test-buffers.cpp b/utils/v4l2-compliance/v4l2-test-buffers.cpp
index e9171648..71390ba6 100644
--- a/utils/v4l2-compliance/v4l2-test-buffers.cpp
+++ b/utils/v4l2-compliance/v4l2-test-buffers.cpp
@@ -2950,6 +2950,8 @@  int testRequests(struct node *node, bool test_streaming)
 	return 0;
 }
 
+/* Android does not have support for pthread_cancel */
+#ifndef ANDROID
 
 /*
  * This class wraps a pthread in such a way that it simplifies passing
@@ -3110,6 +3112,8 @@  static int testBlockingDQBuf(struct node *node, cv4l_queue &q)
 	return 0;
 }
 
+#endif //ANDROID
+
 int testBlockingWait(struct node *node)
 {
 	bool can_stream = node->g_caps() & V4L2_CAP_STREAMING;
@@ -3131,9 +3135,11 @@  int testBlockingWait(struct node *node)
 		if (testSetupVbi(node, type))
 			continue;
 
+#ifndef ANDROID
 		fail_on_test(testBlockingDQBuf(node, q));
 		if (node->is_m2m)
 			fail_on_test(testBlockingDQBuf(node, m2m_q));
+#endif
 	}
 	return 0;
 }