From patchwork Mon Sep 19 06:34:42 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Minghsiu Tsai X-Patchwork-Id: 9338607 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 18FE86022E for ; Mon, 19 Sep 2016 06:35:30 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0870A2870F for ; Mon, 19 Sep 2016 06:35:30 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id F0B7F28B21; Mon, 19 Sep 2016 06:35:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A16722870F for ; Mon, 19 Sep 2016 06:35:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758947AbcISGe4 (ORCPT ); Mon, 19 Sep 2016 02:34:56 -0400 Received: from mailgw01.mediatek.com ([210.61.82.183]:14558 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1753067AbcISGev (ORCPT ); Mon, 19 Sep 2016 02:34:51 -0400 Received: from mtkhts07.mediatek.inc [(172.21.101.69)] by mailgw01.mediatek.com (envelope-from ) (mhqrelay.mediatek.com ESMTP with TLS) with ESMTP id 769314327; Mon, 19 Sep 2016 14:34:46 +0800 Received: from localhost.localdomain (10.21.14.115) by mtkhts07.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 14.3.266.1; Mon, 19 Sep 2016 14:34:44 +0800 From: Minghsiu Tsai To: Hans Verkuil , , Rob Herring , Mauro Carvalho Chehab , Matthias Brugger , Daniel Kurtz , Pawel Osciak CC: , Eddie Huang , Yingjoe Chen , , , , , , Minghsiu Tsai Subject: [PATCH 1/2] media: mtk-mdp: fix build warning in arch x86 Date: Mon, 19 Sep 2016 14:34:42 +0800 Message-ID: <1474266883-51155-2-git-send-email-minghsiu.tsai@mediatek.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1474266883-51155-1-git-send-email-minghsiu.tsai@mediatek.com> References: <1474266883-51155-1-git-send-email-minghsiu.tsai@mediatek.com> MIME-Version: 1.0 X-MTK: N Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch fix build warning in arch x86 Signed-off-by: Minghsiu Tsai --- drivers/media/platform/mtk-mdp/mtk_mdp_m2m.c | 1 + drivers/media/platform/mtk-mdp/mtk_mdp_vpu.c | 10 ++++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/drivers/media/platform/mtk-mdp/mtk_mdp_m2m.c b/drivers/media/platform/mtk-mdp/mtk_mdp_m2m.c index a90972e..9a747e7 100644 --- a/drivers/media/platform/mtk-mdp/mtk_mdp_m2m.c +++ b/drivers/media/platform/mtk-mdp/mtk_mdp_m2m.c @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include diff --git a/drivers/media/platform/mtk-mdp/mtk_mdp_vpu.c b/drivers/media/platform/mtk-mdp/mtk_mdp_vpu.c index fb07bf3..39188e5 100644 --- a/drivers/media/platform/mtk-mdp/mtk_mdp_vpu.c +++ b/drivers/media/platform/mtk-mdp/mtk_mdp_vpu.c @@ -25,7 +25,8 @@ static inline struct mtk_mdp_ctx *vpu_to_ctx(struct mtk_mdp_vpu *vpu) static void mtk_mdp_vpu_handle_init_ack(struct mdp_ipi_comm_ack *msg) { - struct mtk_mdp_vpu *vpu = (struct mtk_mdp_vpu *)msg->ap_inst; + struct mtk_mdp_vpu *vpu = (struct mtk_mdp_vpu *) + (unsigned long)msg->ap_inst; /* mapping VPU address to kernel virtual address */ vpu->vsi = (struct mdp_process_vsi *) @@ -37,7 +38,8 @@ static void mtk_mdp_vpu_ipi_handler(void *data, unsigned int len, void *priv) { unsigned int msg_id = *(unsigned int *)data; struct mdp_ipi_comm_ack *msg = (struct mdp_ipi_comm_ack *)data; - struct mtk_mdp_vpu *vpu = (struct mtk_mdp_vpu *)msg->ap_inst; + struct mtk_mdp_vpu *vpu = (struct mtk_mdp_vpu *) + (unsigned long)msg->ap_inst; struct mtk_mdp_ctx *ctx; vpu->failure = msg->status; @@ -108,7 +110,7 @@ static int mtk_mdp_vpu_send_ap_ipi(struct mtk_mdp_vpu *vpu, uint32_t msg_id) msg.msg_id = msg_id; msg.ipi_id = IPI_MDP; msg.vpu_inst_addr = vpu->inst_addr; - msg.ap_inst = (uint64_t)vpu; + msg.ap_inst = (unsigned long)vpu; err = mtk_mdp_vpu_send_msg((void *)&msg, sizeof(msg), vpu, IPI_MDP); if (!err && vpu->failure) err = -EINVAL; @@ -126,7 +128,7 @@ int mtk_mdp_vpu_init(struct mtk_mdp_vpu *vpu) msg.msg_id = AP_MDP_INIT; msg.ipi_id = IPI_MDP; - msg.ap_inst = (uint64_t)vpu; + msg.ap_inst = (unsigned long)vpu; err = mtk_mdp_vpu_send_msg((void *)&msg, sizeof(msg), vpu, IPI_MDP); if (!err && vpu->failure) err = -EINVAL;