mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-16 07:35:14 +00:00
media: amphion: fix UNINIT issues reported by coverity
[ Upstream commitc224d0497a
] using uninitialized value may introduce risk Fixes:9f599f351e
("media: amphion: add vpu core driver") Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com> Signed-off-by: Ming Qian <ming.qian@nxp.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
bddd678fd2
commit
60f6392bde
1 changed files with 6 additions and 6 deletions
|
@ -32,7 +32,7 @@ static void vpu_session_handle_start_done(struct vpu_inst *inst, struct vpu_rpc_
|
|||
|
||||
static void vpu_session_handle_mem_request(struct vpu_inst *inst, struct vpu_rpc_event *pkt)
|
||||
{
|
||||
struct vpu_pkt_mem_req_data req_data;
|
||||
struct vpu_pkt_mem_req_data req_data = { 0 };
|
||||
|
||||
vpu_iface_unpack_msg_data(inst->core, pkt, (void *)&req_data);
|
||||
vpu_trace(inst->dev, "[%d] %d:%d %d:%d %d:%d\n",
|
||||
|
@ -80,7 +80,7 @@ static void vpu_session_handle_resolution_change(struct vpu_inst *inst, struct v
|
|||
|
||||
static void vpu_session_handle_enc_frame_done(struct vpu_inst *inst, struct vpu_rpc_event *pkt)
|
||||
{
|
||||
struct vpu_enc_pic_info info;
|
||||
struct vpu_enc_pic_info info = { 0 };
|
||||
|
||||
vpu_iface_unpack_msg_data(inst->core, pkt, (void *)&info);
|
||||
dev_dbg(inst->dev, "[%d] frame id = %d, wptr = 0x%x, size = %d\n",
|
||||
|
@ -90,7 +90,7 @@ static void vpu_session_handle_enc_frame_done(struct vpu_inst *inst, struct vpu_
|
|||
|
||||
static void vpu_session_handle_frame_request(struct vpu_inst *inst, struct vpu_rpc_event *pkt)
|
||||
{
|
||||
struct vpu_fs_info fs;
|
||||
struct vpu_fs_info fs = { 0 };
|
||||
|
||||
vpu_iface_unpack_msg_data(inst->core, pkt, &fs);
|
||||
call_void_vop(inst, event_notify, VPU_MSG_ID_FRAME_REQ, &fs);
|
||||
|
@ -107,7 +107,7 @@ static void vpu_session_handle_frame_release(struct vpu_inst *inst, struct vpu_r
|
|||
info.type = inst->out_format.type;
|
||||
call_void_vop(inst, buf_done, &info);
|
||||
} else if (inst->core->type == VPU_CORE_TYPE_DEC) {
|
||||
struct vpu_fs_info fs;
|
||||
struct vpu_fs_info fs = { 0 };
|
||||
|
||||
vpu_iface_unpack_msg_data(inst->core, pkt, &fs);
|
||||
call_void_vop(inst, event_notify, VPU_MSG_ID_FRAME_RELEASE, &fs);
|
||||
|
@ -122,7 +122,7 @@ static void vpu_session_handle_input_done(struct vpu_inst *inst, struct vpu_rpc_
|
|||
|
||||
static void vpu_session_handle_pic_decoded(struct vpu_inst *inst, struct vpu_rpc_event *pkt)
|
||||
{
|
||||
struct vpu_dec_pic_info info;
|
||||
struct vpu_dec_pic_info info = { 0 };
|
||||
|
||||
vpu_iface_unpack_msg_data(inst->core, pkt, (void *)&info);
|
||||
call_void_vop(inst, get_one_frame, &info);
|
||||
|
@ -130,7 +130,7 @@ static void vpu_session_handle_pic_decoded(struct vpu_inst *inst, struct vpu_rpc
|
|||
|
||||
static void vpu_session_handle_pic_done(struct vpu_inst *inst, struct vpu_rpc_event *pkt)
|
||||
{
|
||||
struct vpu_dec_pic_info info;
|
||||
struct vpu_dec_pic_info info = { 0 };
|
||||
struct vpu_frame_info frame;
|
||||
|
||||
memset(&frame, 0, sizeof(frame));
|
||||
|
|
Loading…
Reference in a new issue