aboutsummaryrefslogtreecommitdiffstats
path: root/4a-hal/4a-hal-controllers/4a-hal-controllers-api-loader.c
diff options
context:
space:
mode:
authorJonathan Aillet <jonathan.aillet@iot.bzh>2018-06-09 18:12:11 +0200
committerJonathan Aillet <jonathan.aillet@iot.bzh>2018-10-08 15:52:51 +0200
commitfc6a9c748dab532faa2fbc2d27eeca169dd7e1ef (patch)
treec2b6636f270847f58a9f8d05adac221ccadc79d9 /4a-hal/4a-hal-controllers/4a-hal-controllers-api-loader.c
parentcfd7792c40232af1cb14ea4d0efd93bc8ca0d983 (diff)
Return an error when hal attach to mixer fails.
Return an error when hal is not successfully attach to mixer. Change-Id: Ibfacf405153e87d8005feba17f963b2f49caad7a Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
Diffstat (limited to '4a-hal/4a-hal-controllers/4a-hal-controllers-api-loader.c')
-rw-r--r--4a-hal/4a-hal-controllers/4a-hal-controllers-api-loader.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/4a-hal/4a-hal-controllers/4a-hal-controllers-api-loader.c b/4a-hal/4a-hal-controllers/4a-hal-controllers-api-loader.c
index 61b0657..58dad10 100644
--- a/4a-hal/4a-hal-controllers/4a-hal-controllers-api-loader.c
+++ b/4a-hal/4a-hal-controllers/4a-hal-controllers-api-loader.c
@@ -113,8 +113,10 @@ static int HalCtlsInitOneApi(AFB_ApiT apiHandle)
currentCtlHalData->status = HAL_STATUS_UNAVAILABLE;
else {
currentCtlHalData->status = HAL_STATUS_AVAILABLE;
- if((err = HalCtlsAttachToMixer(apiHandle)))
+ if((err = HalCtlsAttachToMixer(apiHandle))) {
AFB_ApiError(apiHandle, "%s: Error %i while attaching to mixer", __func__, err);
+ return -4;
+ }
}
// TBD JAI: handle refresh of hal status for dynamic card (/dev/by-id)