From 51e5d67f8e70a316f08c928bc1000a76c163e06c Mon Sep 17 00:00:00 2001 From: Paul Elder Date: Mon, 8 Mar 2021 16:48:26 +0900 Subject: utils: ipc: Support custom parameters to init() Add support to the mojom-based code generator for custom parameters to init(). Remove the parameter type and count validation as well. Signed-off-by: Paul Elder Reviewed-by: Laurent Pinchart --- utils/ipc/generators/mojom_libcamera_generator.py | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) (limited to 'utils/ipc/generators/mojom_libcamera_generator.py') diff --git a/utils/ipc/generators/mojom_libcamera_generator.py b/utils/ipc/generators/mojom_libcamera_generator.py index 438e41c6..fa0c21a2 100644 --- a/utils/ipc/generators/mojom_libcamera_generator.py +++ b/utils/ipc/generators/mojom_libcamera_generator.py @@ -341,19 +341,9 @@ def ValidateInterfaces(interfaces): ValidateSingleLength(f_start, 'start()', False) ValidateSingleLength(f_stop, 'stop()', False) - f_init = f_init[0] - f_start = f_start[0] f_stop = f_stop[0] - # Validate parameters to init() - ValidateSingleLength(f_init.parameters, 'input parameter to init()') - ValidateSingleLength(f_init.response_parameters, 'output parameter from init()') - if f_init.parameters[0].kind.mojom_name != 'IPASettings': - raise Exception('init() must have single IPASettings input parameter') - if f_init.response_parameters[0].kind.spec != 'i32': - raise Exception('init() must have single int32 output parameter') - - # No need to validate start() as it is customizable + # No need to validate init() and start() as they are customizable # Validate parameters to stop() ValidateZeroLength(f_stop.parameters, 'input parameter to stop()') -- cgit v1.2.1