From patchwork Sun Dec 25 18:51:55 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: SF Markus Elfring X-Patchwork-Id: 9488335 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 306B0601D7 for ; Sun, 25 Dec 2016 18:52:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2C7F2205AD for ; Sun, 25 Dec 2016 18:52:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 20DF025250; Sun, 25 Dec 2016 18:52:25 +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 autolearn=ham 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 AA367205AD for ; Sun, 25 Dec 2016 18:52:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754311AbcLYSwE (ORCPT ); Sun, 25 Dec 2016 13:52:04 -0500 Received: from mout.web.de ([212.227.17.12]:60478 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754302AbcLYSwD (ORCPT ); Sun, 25 Dec 2016 13:52:03 -0500 Received: from [192.168.1.2] ([77.182.80.223]) by smtp.web.de (mrweb102 [213.165.67.124]) with ESMTPSA (Nemesis) id 0LrJwm-1cXZFw45fA-0136ti; Sun, 25 Dec 2016 19:51:57 +0100 Subject: [PATCH 18/19] [media] uvc_video: Enclose an expression for the sizeof operator by parentheses To: linux-media@vger.kernel.org, Laurent Pinchart , Mauro Carvalho Chehab References: <47aa4314-74ec-b2bf-ee3b-aad4d6e9f0a2@users.sourceforge.net> Cc: LKML , kernel-janitors@vger.kernel.org, trivial@kernel.org From: SF Markus Elfring Message-ID: <73208c2d-38b6-425c-88e6-7cb9706d4881@users.sourceforge.net> Date: Sun, 25 Dec 2016 19:51:55 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: <47aa4314-74ec-b2bf-ee3b-aad4d6e9f0a2@users.sourceforge.net> X-Provags-ID: V03:K0:IvIM1+pxZCDdYEbrPAQYPGhpfZhpqKiLEnFQASeDg7SLRGpHFwe JUGSuSqHT2AEu5e89xJylcwRutVaG1K40VJotfxGQhOGLym/tgXgX65eD5Ciw/0GpdjcBaG 0N2Qz2imT3AB6sepVhQAXpa0pSSQZ/JPKtP7wGwX7DRxHmAMbZmLzbTpObEnH7sdJP5Gyuw fDIp+bTIRnfzGiybD3hhQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:5m400QMTw/A=:9hYDilocL0n+5/snY6ztIw wZ24Li2bFEFxqYOIb4Edpe/h5z30V/InpbHTE8UAeKAuyXT3mUBlCebpuNgEOkydzcVf/7vOG izmUGnPvOR9ufpCxb5SprMSZ0PvDaTGxkvrWF6nx5FJdelm5w/68j/ArcuRCw7fZNCi7Xt2Xn 4K5KpdK3+ApcH2FpazKLrd36kUKCScVkBc7IXGI2A7FYhdpbvKxzIgDL8P+uhPoxVNZZNcFCN DmhvVGQBLnwY+VZlpmNT016k591U+3h7gixLzSKe+Ot2KKp4tVQ4h0U+RKpMIsw27/MPZg5Ov F6rVM40q+OlOa1zrCy1dZ2F4eu6mQ8QzbujQRA0kVtFGcisVtPvQHatLVx/KO7AdTbQJf6oGt N0kL1FSw3XtE7xkptu9zKN75NMwq884fbjDAwPUBAw02G97qgW3Co+ScfgQf2aGIkhc5eyuy5 UBCNSKqDs5iJXOA0tUnV+mmcO3Bl6IWfIRpUPUjjZR8I69wsZ7fOt6HMyaRWrRQk9WZ1vUL/q m3Ioi3cQcPyXIfIXax1HjeMWNzAJL+K2Jlve72ewbVUlaO6EyJjHeS89Z/sPZLcGaNyHvY586 YzL5NSQstth/Ku/GQSBAZXs6HDi6ApKVkigXld2Y04BaZNiQMbfWPwXYEUpE7EXasP5qB6y7d gS6NLZjp/tN5voNmcmJd3AlFPNclk30mL2hjTT7BMoEIhrZfZOz4meJZVxGdAQ4xaacjdnobl bio8i0dI4971AKldFFUZFCGbl3b1NRmBI6m5X65GRV8mIVjRIPnR+1U4KkSZYI9XP4BxBd33V maxJc30 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 From: Markus Elfring Date: Sun, 25 Dec 2016 18:50:35 +0100 The script "checkpatch.pl" pointed information out like the following. WARNING: sizeof *ctrl should be sizeof(*ctrl) Thus fix the affected source code place. Signed-off-by: Markus Elfring --- drivers/media/usb/uvc/uvc_video.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/usb/uvc/uvc_video.c b/drivers/media/usb/uvc/uvc_video.c index 61320ef82553..aba21e0abf02 100644 --- a/drivers/media/usb/uvc/uvc_video.c +++ b/drivers/media/usb/uvc/uvc_video.c @@ -191,7 +191,7 @@ static int uvc_get_video_ctrl(struct uvc_streaming *stream, uvc_warn_once(stream->dev, UVC_WARN_MINMAX, "UVC non compliance - GET_MIN/MAX(PROBE) incorrectly supported. Enabling workaround.\n"); - memset(ctrl, 0, sizeof *ctrl); + memset(ctrl, 0, sizeof(*ctrl)); ctrl->wCompQuality = le16_to_cpup((__le16 *)data); ret = 0; goto out;