From patchwork Fri Mar 31 03:30:55 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Seung-Woo Kim X-Patchwork-Id: 9655445 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 3CE7B602BD for ; Fri, 31 Mar 2017 03:30:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2F90628669 for ; Fri, 31 Mar 2017 03:30:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 22B0928641; Fri, 31 Mar 2017 03:30:51 +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=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id AFE2228641 for ; Fri, 31 Mar 2017 03:30:50 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2A0E06E9E3; Fri, 31 Mar 2017 03:30:50 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mailout3.samsung.com (mailout3.samsung.com [203.254.224.33]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3A4406E9DB for ; Fri, 31 Mar 2017 03:30:43 +0000 (UTC) Received: from epcas1p4.samsung.com (unknown [182.195.41.48]) by mailout3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0ONN02Z1VTR1MM60@mailout3.samsung.com> for dri-devel@lists.freedesktop.org; Fri, 31 Mar 2017 12:30:37 +0900 (KST) Received: from epsmges5p3.samsung.com (unknown [182.195.40.66]) by epcas1p4.samsung.com (KnoxPortal) with ESMTP id 20170331033037epcas1p4f155683aa5c307d2c3b12d6079316db2~w2eEDUgdz1551515515epcas1p4G; Fri, 31 Mar 2017 03:30:37 +0000 (GMT) Received: from epcas5p4.samsung.com ( [182.195.41.42]) by epsmges5p3.samsung.com (EPCPMTA) with SMTP id 19.6B.18112.D5DCDD85; Fri, 31 Mar 2017 12:30:37 +0900 (KST) Received: from epcpsbgm2new.samsung.com (u27.gpu120.samsung.co.kr [203.254.230.27]) by epcas5p4.samsung.com (KnoxPortal) with ESMTP id 20170331033036epcas5p43ab05758c1a16c8b754d65b5d8578c43~w2eDy6Jlw2317423174epcas5p42; Fri, 31 Mar 2017 03:30:36 +0000 (GMT) X-AuditID: b6c32a2e-f79506d0000046c0-c0-58ddcd5d0db0 Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm2new.samsung.com (EPCPMTA) with SMTP id F2.23.05013.C5DCDD85; Fri, 31 Mar 2017 12:30:36 +0900 (KST) Received: from localhost.localdomain ([10.113.62.209]) by mmp2.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0ONN00AXLTQXW150@mmp2.samsung.com>; Fri, 31 Mar 2017 12:30:36 +0900 (KST) From: Seung-Woo Kim To: dri-devel@lists.freedesktop.org, inki.dae@samsung.com, emil.l.velikov@gmail.com Subject: [PATCH libdrm 1/3] exynos: fix type-punned pointer build warning Date: Fri, 31 Mar 2017 12:30:55 +0900 Message-id: <1490931057-30853-2-git-send-email-sw0312.kim@samsung.com> X-Mailer: git-send-email 1.7.4.1 In-reply-to: <1490931057-30853-1-git-send-email-sw0312.kim@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrPKsWRmVeSWpSXmKPExsWy7bCmlm7s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CxeHHvIovFlOZcixmTX7JZtK3+wOrA7rFqzgZWj52z7rJ73O8+zuTx7xi7R9+WVYwB rFFuNhmpiSmpRQqpecn5KZl56bZKoSFuuhZKCnmJuam2ShG6viFBSgpliTmlQJ6RARpwcA5w D1bSt0twy7i5PbDgOHvFrdOXWBoYm9m6GDk5JARMJI6ens0EYYtJXLi3HijOxSEkMItRouXd cUYI5wejxIbGP6wgVWwCOhL7l/wGs0UEQiWm/bjPDGIzC+RJrN39A8wWFvCUuP7nDtgGFgFV ic5dr8BsXgE3iUnrO6C2KUgsuPcWLM4p4C7x/NVPoJkcQMvcJJ4dL5nAyLuAkWEVo0RqQXJB cVJ6rlFearlecWJucWleul5yfu4mRnA4P5PewXh4l/shRgEORiUe3h2CdyOEWBPLiitzDzFK cDArifDK7QMK8aYkVlalFuXHF5XmpBYfYjQFumsis5Rocj4w1vJK4g1NzE3MjQ0szC0tTYyU xHkbZz8LFxJITyxJzU5NLUgtgulj4uCUamAU8BaXeh4qrHy17Z6e4qFfUzKOniwOvmMrw1ur Nyk18IXil4PXrB8yTry8q+xRhVGUmJl9TNq05pQJKTxlE6dOc2IM6ZmqNjnvboWSmXXaedfJ HP+msrxM0u/ZfedYC+uT/uKjG5+1bpNfG/xx5SrXlqVhT0KvP0gRcTP9Ubm0K+x32CP98/OV WIozEg21mIuKEwFlpDDifQIAAA== X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170331033036epcas5p43ab05758c1a16c8b754d65b5d8578c43 X-Msg-Generator: CA X-Sender-IP: 203.254.230.27 X-Local-Sender: =?UTF-8?B?6rmA7Iq57JqwG1RpemVuIFBsYXRmb3JtIExhYihTL1fshLw=?= =?UTF-8?B?7YSwKRvsgrzshLHsoITsnpAbU2VuaW9yIEVuZ2luZWVy?= X-Global-Sender: =?UTF-8?B?U2V1bmctV29vIEtpbRtUaXplbiBQbGF0Zm9ybSBMYWIuG1Nh?= =?UTF-8?B?bXN1bmcgRWxlY3Ryb25pY3MbU2VuaW9yIEVuZ2luZWVy?= X-Sender-Code: =?UTF-8?B?QzEwG1NUQUYbQzEwVjgxMTE=?= CMS-TYPE: 105P DLP-Filter: Pass X-CFilter-Loop: Reflected X-HopCount: 7 X-CMS-RootMailID: 20170331033036epcas5p43ab05758c1a16c8b754d65b5d8578c43 X-RootMTR: 20170331033036epcas5p43ab05758c1a16c8b754d65b5d8578c43 References: <1490931057-30853-1-git-send-email-sw0312.kim@samsung.com> Cc: tjakobi@math.uni-bielefeld.de, sw0312.kim@samsung.com, robclark@freedesktop.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP As like the commit ecc2a097294d ("xf86drm: Fix type-punned pointer build warning"), this fixes following build warning. exynos_drm.c: In function 'exynos_handle_event': exynos_drm.c:420:15: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing] e = (struct drm_event *) &buffer[i]; ^ Signed-off-by: Seung-Woo Kim Reviewed-by: Tobias Jakobi --- exynos/exynos_drm.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/exynos/exynos_drm.c b/exynos/exynos_drm.c index b961e52..f6204f1 100644 --- a/exynos/exynos_drm.c +++ b/exynos/exynos_drm.c @@ -417,7 +417,7 @@ exynos_handle_event(struct exynos_device *dev, struct exynos_event_context *ctx) i = 0; while (i < len) { - e = (struct drm_event *) &buffer[i]; + e = (struct drm_event *)(buffer + i); switch (e->type) { case DRM_EVENT_VBLANK: if (evctx->version < 1 ||