From patchwork Thu Jul 3 13:10:29 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrzej Hajda X-Patchwork-Id: 4473011 Return-Path: X-Original-To: patchwork-linux-samsung-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id B8F159F387 for ; Thu, 3 Jul 2014 13:13:39 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id ECCA4202E5 for ; Thu, 3 Jul 2014 13:13:38 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1BDD32028D for ; Thu, 3 Jul 2014 13:13:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757950AbaGCNNW (ORCPT ); Thu, 3 Jul 2014 09:13:22 -0400 Received: from mailout3.w1.samsung.com ([210.118.77.13]:40887 "EHLO mailout3.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752809AbaGCNK7 (ORCPT ); Thu, 3 Jul 2014 09:10:59 -0400 Received: from eucpsbgm1.samsung.com (unknown [203.254.199.244]) by mailout3.w1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0N85009PP0M9E6A0@mailout3.w1.samsung.com>; Thu, 03 Jul 2014 14:10:57 +0100 (BST) X-AuditID: cbfec7f4-b7fac6d000006cfe-6c-53b55661fa12 Received: from eusync2.samsung.com ( [203.254.199.212]) by eucpsbgm1.samsung.com (EUCPMTA) with SMTP id BB.AE.27902.16655B35; Thu, 03 Jul 2014 14:10:57 +0100 (BST) Received: from AMDC1061.digital.local ([106.116.147.88]) by eusync2.samsung.com (Oracle Communications Messaging Server 7u4-23.01 (7.0.4.23.0) 64bit (built Aug 10 2011)) with ESMTPA id <0N8500IAQ0LSH950@eusync2.samsung.com>; Thu, 03 Jul 2014 14:10:57 +0100 (BST) From: Andrzej Hajda To: Inki Dae Cc: Andrzej Hajda , Marek Szyprowski , Joonyoung Shim , Seung-Woo Kim , Kyungmin Park , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org (open list), linux-samsung-soc@vger.kernel.org (moderated list:ARM/S5P EXYNOS AR...) Subject: [PATCH 04/12] drm/exynos/ipp: correct address type Date: Thu, 03 Jul 2014 15:10:29 +0200 Message-id: <1404393037-17299-5-git-send-email-a.hajda@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1404393037-17299-1-git-send-email-a.hajda@samsung.com> References: <1404393037-17299-1-git-send-email-a.hajda@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrOJMWRmVeSWpSXmKPExsVy+t/xK7qJYVuDDabtU7a4te4cq8WVr+/Z LCbdn8Bi8eLeRRaLs01v2C0u75rDZjHj/D4mi7VH7rJbzJj8ks2B0+N+93Emj74tqxg9Pm+S C2CO4rJJSc3JLEst0rdL4Mr4MLeNqeA/Z8WDWx3MDYxzOLoYOTkkBEwkLmz6xgZhi0lcuLce yObiEBJYyigx9+AFRginj0liz/NnzCBVbAKaEn833wTrEBFQlli1r50dpIhZ4COTxJWlb8CK hAWsJfauf8MOYrMIqEpc+fySBcTmFXCWOPznBTPEOjmJk8cms4LYnAIuEodmLmUEsYWAatYu mcs2gZF3ASPDKkbR1NLkguKk9FxDveLE3OLSvHS95PzcTYyQwPqyg3HxMatDjAIcjEo8vI0r NgQLsSaWFVfmHmKU4GBWEuGtCN4aLMSbklhZlVqUH19UmpNafIiRiYNTqoFxcfkHtWn3l0/I +Fi6p37Vm3cmS5o3+i0o42OV7F7GypOo9PKcBsPfyxvvB9YsPpQvvSLMRjeCX1bn0625z76+ fni1n3neRs4sg0pbHRvz8xPO6V5I5J7pfasos0Xj9qeej+I1SkvXLolsf/fqsofxpVuqwRzL 8wIjdee/ciiwyGX/Xq8eOdFeiaU4I9FQi7moOBEAZvxuLwoCAAA= Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP exynos_drm_gem_get_dma_addr returns dma_addr_t, type casting to void* and back is not necessary. Signed-off-by: Andrzej Hajda --- drivers/gpu/drm/exynos/exynos_drm_ipp.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_ipp.c b/drivers/gpu/drm/exynos/exynos_drm_ipp.c index 34d185c..f3d8b5c 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_ipp.c +++ b/drivers/gpu/drm/exynos/exynos_drm_ipp.c @@ -681,7 +681,6 @@ static struct drm_exynos_ipp_mem_node { struct drm_exynos_ipp_mem_node *m_node; struct drm_exynos_ipp_buf_info buf_info; - void *addr; int i; m_node = kzalloc(sizeof(*m_node), GFP_KERNEL); @@ -704,6 +703,8 @@ static struct drm_exynos_ipp_mem_node /* get dma address by handle */ if (qbuf->handle[i]) { + dma_addr_t *addr; + addr = exynos_drm_gem_get_dma_addr(drm_dev, qbuf->handle[i], file); if (IS_ERR(addr)) { @@ -712,7 +713,7 @@ static struct drm_exynos_ipp_mem_node } buf_info.handles[i] = qbuf->handle[i]; - buf_info.base[i] = *(dma_addr_t *) addr; + buf_info.base[i] = *addr; DRM_DEBUG_KMS("i[%d]base[0x%x]hd[0x%x]\n", i, buf_info.base[i], (int)buf_info.handles[i]); }