Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[media] media: mtk-mdp: fix build warning in arch x86

This patch fix build warning in arch x86

Signed-off-by: Minghsiu Tsai <minghsiu.tsai@mediatek.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>

authored by

Minghsiu Tsai and committed by
Mauro Carvalho Chehab
37bf7e34 fc96ec0d

+7 -4
+1
drivers/media/platform/mtk-mdp/mtk_mdp_m2m.c
··· 17 17 #include <linux/errno.h> 18 18 #include <linux/kernel.h> 19 19 #include <linux/pm_runtime.h> 20 + #include <linux/slab.h> 20 21 #include <linux/workqueue.h> 21 22 #include <media/v4l2-event.h> 22 23 #include <media/v4l2-ioctl.h>
+6 -4
drivers/media/platform/mtk-mdp/mtk_mdp_vpu.c
··· 25 25 26 26 static void mtk_mdp_vpu_handle_init_ack(struct mdp_ipi_comm_ack *msg) 27 27 { 28 - struct mtk_mdp_vpu *vpu = (struct mtk_mdp_vpu *)msg->ap_inst; 28 + struct mtk_mdp_vpu *vpu = (struct mtk_mdp_vpu *) 29 + (unsigned long)msg->ap_inst; 29 30 30 31 /* mapping VPU address to kernel virtual address */ 31 32 vpu->vsi = (struct mdp_process_vsi *) ··· 38 37 { 39 38 unsigned int msg_id = *(unsigned int *)data; 40 39 struct mdp_ipi_comm_ack *msg = (struct mdp_ipi_comm_ack *)data; 41 - struct mtk_mdp_vpu *vpu = (struct mtk_mdp_vpu *)msg->ap_inst; 40 + struct mtk_mdp_vpu *vpu = (struct mtk_mdp_vpu *) 41 + (unsigned long)msg->ap_inst; 42 42 struct mtk_mdp_ctx *ctx; 43 43 44 44 vpu->failure = msg->status; ··· 110 108 msg.msg_id = msg_id; 111 109 msg.ipi_id = IPI_MDP; 112 110 msg.vpu_inst_addr = vpu->inst_addr; 113 - msg.ap_inst = (uint64_t)vpu; 111 + msg.ap_inst = (unsigned long)vpu; 114 112 err = mtk_mdp_vpu_send_msg((void *)&msg, sizeof(msg), vpu, IPI_MDP); 115 113 if (!err && vpu->failure) 116 114 err = -EINVAL; ··· 128 126 129 127 msg.msg_id = AP_MDP_INIT; 130 128 msg.ipi_id = IPI_MDP; 131 - msg.ap_inst = (uint64_t)vpu; 129 + msg.ap_inst = (unsigned long)vpu; 132 130 err = mtk_mdp_vpu_send_msg((void *)&msg, sizeof(msg), vpu, IPI_MDP); 133 131 if (!err && vpu->failure) 134 132 err = -EINVAL;