diff options
author | Xiang, Haihao <haihao.xiang@intel.com> | 2013-09-23 09:51:39 +0800 |
---|---|---|
committer | Xiang, Haihao <haihao.xiang@intel.com> | 2013-09-23 10:46:20 +0800 |
commit | b99d5891a50bc2059143af6db25b8bd05fd73c85 (patch) | |
tree | 7e6a968b3e274f29e665e574dd26ce8305111cbe | |
parent | 789046916bf50310e9dcb3882c53977eb2c0078e (diff) |
VPP: also remove an assert on forward temporal reference on HSW
Do the same thing of commit 8a0a61c
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=69669
Signed-off-by: Xiang, Haihao <haihao.xiang@intel.com>
(cherry picked from commit f6685c309d94fb7679c9772703c8790cb71cdd73)
-rw-r--r-- | src/gen75_vpp_vebox.c | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/src/gen75_vpp_vebox.c b/src/gen75_vpp_vebox.c index 50df627..a973ed4 100644 --- a/src/gen75_vpp_vebox.c +++ b/src/gen75_vpp_vebox.c @@ -844,8 +844,9 @@ void hsw_veb_resource_prepare(VADriverContextP ctx, } -void hsw_veb_surface_reference(VADriverContextP ctx, - struct intel_vebox_context *proc_ctx) +static VAStatus +hsw_veb_surface_reference(VADriverContextP ctx, + struct intel_vebox_context *proc_ctx) { struct object_surface * obj_surf; VEBFrameStore tmp_store; @@ -880,9 +881,14 @@ void hsw_veb_surface_reference(VADriverContextP ctx, VAProcPipelineParameterBuffer *pipe = proc_ctx->pipeline_param; struct object_surface *obj_surf = NULL; struct i965_driver_data * const i965 = i965_driver_data(ctx); - - assert(pipe->num_forward_references == 1); - assert(pipe->forward_references[0] != VA_INVALID_ID); + + if (!pipe || + !pipe->num_forward_references || + pipe->forward_references[0] == VA_INVALID_ID) { + WARN_ONCE("A forward temporal reference is needed for Motion adaptive deinterlacing !!!\n"); + + return VA_STATUS_ERROR_INVALID_PARAMETER; + } obj_surf = SURFACE(pipe->forward_references[0]); assert(obj_surf && obj_surf->bo); @@ -946,6 +952,8 @@ void hsw_veb_surface_reference(VADriverContextP ctx, proc_ctx->frame_store[FRAME_OUT_CURRENT].obj_surface = obj_surf; proc_ctx->current_output = FRAME_OUT_CURRENT; } + + return VA_STATUS_SUCCESS; } void hsw_veb_surface_unreference(VADriverContextP ctx, |