From patchwork Wed Aug 23 08:28:41 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: SF Markus Elfring X-Patchwork-Id: 9916829 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 66230600C5 for ; Wed, 23 Aug 2017 08:28:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 57E632896C for ; Wed, 23 Aug 2017 08:28:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4C7042896E; Wed, 23 Aug 2017 08:28:57 +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=-1.9 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 91CF42896C for ; Wed, 23 Aug 2017 08:28:56 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id B0C4B26711B; Wed, 23 Aug 2017 10:28:50 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id B47E0267121; Wed, 23 Aug 2017 10:28:49 +0200 (CEST) Received: from mout.web.de (mout.web.de [212.227.15.3]) by alsa0.perex.cz (Postfix) with ESMTP id 281462665D5 for ; Wed, 23 Aug 2017 10:28:48 +0200 (CEST) Received: from [192.168.1.2] ([77.182.78.200]) by smtp.web.de (mrweb004 [213.165.67.108]) with ESMTPSA (Nemesis) id 0Lsvn8-1da9Oj0X9u-012XnE; Wed, 23 Aug 2017 10:28:43 +0200 From: SF Markus Elfring To: alsa-devel@alsa-project.org, Arnd Bergmann , Arvind Yadav , Dan Carpenter , Ingo Molnar , Jaroslav Kysela , Takashi Iwai , Takashi Sakamoto , Vegard Nossum References: <800d7aa6-d8f2-cbf5-caaa-7e4006976e68@users.sourceforge.net> Message-ID: <4d1a6d05-6574-b1f4-80ee-59cb5238a74e@users.sourceforge.net> Date: Wed, 23 Aug 2017 10:28:41 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <800d7aa6-d8f2-cbf5-caaa-7e4006976e68@users.sourceforge.net> Content-Language: en-GB X-Provags-ID: V03:K0:yygy6VogSP7WH0Yu4tuExAPywcvP9iopfAem1t3ZrKgY0bWeymT I+v7maNVhWO5Ne5T0s21H+RDdWS1u//SdHIf98Pyp+pT+Tyu2LFiwH2Vrl/5fPpkbeiRFBj aVI6ZVTna0opDlj6fs5zCxtOLKBD5LBiOMNFHvmHJjGBiKADZ5995LRM5Ru4/5Mi/M8GcM7 PL3r5QZMl2yukkxAW7Dpw== X-UI-Out-Filterresults: notjunk:1; V01:K0:5qFQH1PzmvA=:i7y37iBttfXj9rlj4TGiII awwMoypWjP/xPvDZ748/p20Hlm7bUN+/OzcZg7DYgQNbRKpxauLMRUoBC3oCdaA7Ma7RVlh9Y eFZpF0AdwEsmdnz5OPouPJujvTLmoeMmv6A7WUA7CW+6ZxORA7sV0YC8yhfqa3JaMfl3/d4gf X7RE2Sw2qh1Y6ecRjjlbzM+z7qVEPA6RJmx1eV2bjdDa7PuX7tpVizIdNqPQ5RnG8LoSdcl2I YXZBiEI8J++McPj/Gt54HWZZgXDkAnJkaY4JokOqdcyiVPc1EnfblW5NAijKogcaE205+rJIV hAU5ilxH33NxWNYTg69VHTcwhCBPsIKTiKCUjASihrFIaRVCjAQxPIAxZlphBckF6mz7L2gQ/ /p0NxhGv74pyJrb6RIWjgd30T3e7pD3w0IX82LAjUqg5ij78PAmfbu01MFWCGN2VTccurVnNY 8lR2stJKAQ3BO6xwMPt2z9JYQRK/rauus8CpIAOlRyPs1iP8FnPi4Ag5kzrZTpScdk56fxCBr DHkNNKYYk1Vlir9hZOhI9poyGdYRwZ8ag30HKe0dOgHFfOdpdB/D+j3q4IXUvdpvdaq87TUVM fJvtbfYKd5puygjk0jXexE8myesSqJ10WeKssGAcyAZeXYtEpIdF6+NxIlRWtYmtR80OVRZB/ A7gHFaNhukWIIRCVFoZm2RqbwDsiw82FhGtuzhj6jvcH6sgXnqbjKkDSDi72Q1JW7kIwW3LkK awXYZ1S9AyEesVGxeUzS+i3CfOSf5dD8AnV+wt6aUJCGUWexNovwsxX/Iq+5kMafHrEhMCQhF M8dNegJ7FLS5qoua6iPx9XmeBQRg5VEqh6goNwP5Z9FbBwHpjg= Cc: kernel-janitors@vger.kernel.org, LKML Subject: [alsa-devel] [PATCH 5/6] ALSA: timer: Adjust a condition check in snd_timer_resolution() X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP From: Markus Elfring Date: Wed, 23 Aug 2017 09:45:06 +0200 The script "checkpatch.pl" pointed information out like the following. ERROR: do not use assignment in if condition Thus fix the affected source code place. Signed-off-by: Markus Elfring --- sound/core/timer.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sound/core/timer.c b/sound/core/timer.c index 6d73a63f6e2b..6cdd04a45962 100644 --- a/sound/core/timer.c +++ b/sound/core/timer.c @@ -395,5 +395,6 @@ unsigned long snd_timer_resolution(struct snd_timer_instance *timeri) return 0; - if ((timer = timeri->timer) != NULL) { + timer = timeri->timer; + if (timer) { if (timer->hw.c_resolution) return timer->hw.c_resolution(timer); return timer->hw.resolution;