Camera: require torch API support for Android Q
Torch API was mandated on legacy libhardware camera module 2.4.
We kept the option of not supporting this API because the first
HIDL legacy wrapper needs to also support libhardware camera
module 1.0 + HAL1.0. Now that HAL 1.0 is no longer supported,
we can reenforce the torch API being supported by camera HAL as
this is critical to power usage of flashlight usecase.
Test: adb shell VtsHalCameraProviderV2_4TargetTest
--hal_service_instance=android.hardware.camera.provider@2.4::ICameraProvider/legacy/0
Bug: 113336515
Change-Id: I0dcf2e7a5cddadcd097caf6913625d8a607065f8
diff --git a/camera/provider/2.4/ICameraProvider.hal b/camera/provider/2.4/ICameraProvider.hal
index 8773bc0..74c3ff1 100644
--- a/camera/provider/2.4/ICameraProvider.hal
+++ b/camera/provider/2.4/ICameraProvider.hal
@@ -140,7 +140,8 @@
* Torch API support cannot be queried. This may be due to
* a failure to initialize the camera subsystem, for example.
* @return support Whether the camera devices known to this provider
- * supports setTorchMode API or not.
+ * supports setTorchMode API or not. Devices launched with SDK
+ * level 29 or higher must return true.
*
*/
isSetTorchModeSupported() generates (Status status, bool support);