summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLi Xiaowei <xiaowei.a.li@intel.com>2014-01-09 13:33:44 +0800
committerLi Xiaowei <xiaowei.a.li@intel.com>2014-01-09 13:49:39 +0800
commiteffb8c5ace6c0e0f862d2c5b6ed6c7af7df78b27 (patch)
tree14a1a46ad4ed4d51588df8766fda5301a9f4a056
parent34b3953cc142d7cc4a1c81f09678f63a97643d60 (diff)
downloadlibva-intel-driver-effb8c5ace6c0e0f862d2c5b6ed6c7af7df78b27.tar.gz
libva-intel-driver-effb8c5ace6c0e0f862d2c5b6ed6c7af7df78b27.tar.bz2
libva-intel-driver-effb8c5ace6c0e0f862d2c5b6ed6c7af7df78b27.zip
VPP: Correct return value of vpp gpe functions
Signed-off-by: Li Xiaowei <xiaowei.a.li@intel.com>
-rw-r--r--src/gen75_vpp_gpe.c31
1 files changed, 23 insertions, 8 deletions
diff --git a/src/gen75_vpp_gpe.c b/src/gen75_vpp_gpe.c
index 08de61b..ac09100 100644
--- a/src/gen75_vpp_gpe.c
+++ b/src/gen75_vpp_gpe.c
@@ -359,12 +359,19 @@ gen75_gpe_process(VADriverContextP ctx,
VAStatus va_status = VA_STATUS_SUCCESS;
va_status = gen75_gpe_process_init(ctx, vpp_gpe_ctx);
- va_status |=gen75_gpe_process_prepare(ctx, vpp_gpe_ctx);
- va_status |=gen75_gpe_process_run(ctx, vpp_gpe_ctx);
-
- return va_status;
-}
+ if (va_status != VA_STATUS_SUCCESS)
+ return va_status;
+ va_status = gen75_gpe_process_prepare(ctx, vpp_gpe_ctx);
+ if (va_status != VA_STATUS_SUCCESS)
+ return va_status;
+
+ va_status = gen75_gpe_process_run(ctx, vpp_gpe_ctx);
+ if (va_status != VA_STATUS_SUCCESS)
+ return va_status;
+
+ return VA_STATUS_SUCCESS;
+}
static VAStatus
gen8_gpe_process_surfaces_setup(VADriverContextP ctx,
@@ -596,10 +603,18 @@ gen8_gpe_process(VADriverContextP ctx,
VAStatus va_status = VA_STATUS_SUCCESS;
va_status = gen8_gpe_process_init(ctx, vpp_gpe_ctx);
- va_status |=gen8_gpe_process_prepare(ctx, vpp_gpe_ctx);
- va_status |=gen8_gpe_process_run(ctx, vpp_gpe_ctx);
+ if (va_status != VA_STATUS_SUCCESS)
+ return va_status;
- return va_status;
+ va_status = gen8_gpe_process_prepare(ctx, vpp_gpe_ctx);
+ if (va_status != VA_STATUS_SUCCESS)
+ return va_status;
+
+ va_status = gen8_gpe_process_run(ctx, vpp_gpe_ctx);
+ if (va_status != VA_STATUS_SUCCESS)
+ return va_status;
+
+ return VA_STATUS_SUCCESS;
}
static VAStatus