From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.9 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3133DC47093 for ; Wed, 2 Jun 2021 11:10:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 11277613D0 for ; Wed, 2 Jun 2021 11:10:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229541AbhFBLMF (ORCPT ); Wed, 2 Jun 2021 07:12:05 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:52657 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229695AbhFBLMC (ORCPT ); Wed, 2 Jun 2021 07:12:02 -0400 Received: from mail-ed1-f72.google.com ([209.85.208.72]) by youngberry.canonical.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1loOlO-0004Tx-HB for linux-kernel@vger.kernel.org; Wed, 02 Jun 2021 11:10:18 +0000 Received: by mail-ed1-f72.google.com with SMTP id s20-20020a0564025214b029038752a2d8f3so1197881edd.2 for ; Wed, 02 Jun 2021 04:10:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=GM346qMDm5SkBVsnz+0MTRWteUg3MTSMm7l18tLMkIc=; b=noaUw1b1hPjGsC7TugzuQo0s4FerwznbCtZ0CbaN8hUEKXSEpMsHW5YPivHH0Rq/8S /vTyYVby+uAD+UTY3VOEJ4YSgk34rSD1oR9uRwxYrvrLEQS0T1i3knEEPl+z5u7a3Qus KOl963e67SmKheChWhN2hFHPMzHQHZMFXccnyAYR6GTJME6QYPGRHgV1oYN4AN3xj5Mm 3Lz0PaS5SxYC3KNn0DRx7lVS/pXY1pgCT96lIJHZjMQUQ9DWybxXNJfaV0boU7b641cv 0+rwgruvHkH74UNiRA36JVUlYpfk5N8Bh4jks1bf10PfZQo9N0gqsqSdWcfUBinewBWu EaSw== X-Gm-Message-State: AOAM530nXa2p18vdoSZdZUEeuQ8OH66g+EEw8WucH72ysI6hXsbT2xkH qjjL2IE9Znr0npCyHFpzoOjSEcIZu8+MGTG9Q5nYO83QniSqELdJs9LbAJuux2JWfyuJxbGtdW7 A9gW7YyKRQgwo49cNLb+BhqJqTVpSUSNlj63bGN1hGQ== X-Received: by 2002:a50:fd13:: with SMTP id i19mr13052916eds.280.1622632218082; Wed, 02 Jun 2021 04:10:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw06pkyMIjDmtQIx52ngcNxG9a4Pd49N7BCx77O2/Snm6f9UtSwWihRBF+HkFpauz9Ft3wqoQ== X-Received: by 2002:a50:fd13:: with SMTP id i19mr13052906eds.280.1622632217929; Wed, 02 Jun 2021 04:10:17 -0700 (PDT) Received: from [192.168.1.115] (xdsl-188-155-185-9.adslplus.ch. [188.155.185.9]) by smtp.gmail.com with ESMTPSA id d24sm1142127edp.7.2021.06.02.04.10.17 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 02 Jun 2021 04:10:17 -0700 (PDT) Subject: Re: [PATCH] nfc: mrvl: remove useless "continue" at end of loop To: Joe Perches , linux-nfc@lists.01.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20210601160713.312622-1-krzysztof.kozlowski@canonical.com> <5780056e09dbbd285d470a313939e5d3cc1a0c3e.camel@perches.com> From: Krzysztof Kozlowski Message-ID: Date: Wed, 2 Jun 2021 13:10:16 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: <5780056e09dbbd285d470a313939e5d3cc1a0c3e.camel@perches.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/06/2021 18:30, Joe Perches wrote: > On Tue, 2021-06-01 at 18:07 +0200, Krzysztof Kozlowski wrote: >> The "continue" statement at the end of a for loop does not have an >> effect. > [] >> diff --git a/drivers/nfc/nfcmrvl/usb.c b/drivers/nfc/nfcmrvl/usb.c > [] >> @@ -325,7 +325,6 @@ static int nfcmrvl_probe(struct usb_interface *intf, >>   if (!drv_data->bulk_rx_ep && >>   usb_endpoint_is_bulk_in(ep_desc)) { >>   drv_data->bulk_rx_ep = ep_desc; >> - continue; >>   } >>   } > > I think this code would be clearer with an if/else instead of > multiple continues. Makes sense. I'll send a v2. Best regards, Krzysztof From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.2 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9762CC47083 for ; Wed, 2 Jun 2021 11:10:23 +0000 (UTC) Received: from ml01.01.org (ml01.01.org [198.145.21.10]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 489FF613D0 for ; Wed, 2 Jun 2021 11:10:22 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 489FF613D0 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=canonical.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-nfc-bounces@lists.01.org Received: from ml01.vlan13.01.org (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id AE747100ED482; Wed, 2 Jun 2021 04:10:21 -0700 (PDT) Received-SPF: None (mailfrom) identity=mailfrom; client-ip=91.189.89.112; helo=youngberry.canonical.com; envelope-from=krzysztof.kozlowski@canonical.com; receiver= Received: from youngberry.canonical.com (youngberry.canonical.com [91.189.89.112]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 61C83100EF267 for ; Wed, 2 Jun 2021 04:10:20 -0700 (PDT) Received: from mail-ed1-f71.google.com ([209.85.208.71]) by youngberry.canonical.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1loOlO-0004Tv-B3 for linux-nfc@lists.01.org; Wed, 02 Jun 2021 11:10:18 +0000 Received: by mail-ed1-f71.google.com with SMTP id f12-20020a056402150cb029038fdcfb6ea2so1177282edw.14 for ; Wed, 02 Jun 2021 04:10:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=GM346qMDm5SkBVsnz+0MTRWteUg3MTSMm7l18tLMkIc=; b=jnH1T4AMUPT6dQiAkSfn+OMxQqR5FC80lAivVoWIEP0JcLgHjVExj7llknLX9GoKvJ tG//sLLcYNeDGiOYczXvA50s8eqLtk5rbuaJ7YOj87AYRXSilNqCaKc2FwpU4s7qAYaP vjoeZIc46fdEzj/HeoqKZ2P8Fne1zvJIFsiNnYbme55Rsi0LaXoKTkyHyysexhPfIOeY ytcunl1RjTbnBoq/qdCTS5ghoa28ASY1Z1ZbK5pgXcoDmFxAk/qeiqMHNnV+FJdM5FqQ OpEiVAiDKGyLa6VrQ1hvZRTDdLcZOi3BF1jtnp5V7vBoX7g+FOw59PbHmxADf6wmTldN ypVg== X-Gm-Message-State: AOAM530uKAqEHSPNaZ9uii+7nIg3/lli+lFygYhbXGPd0FqGb0IFDGIQ fTDuHDJYcR5eAZg6TJ3PlTmwqH4MCPSGS9hVZ/K5sa16aF0eTQ9E/gIsLC/2R3sKCV5FEn6yt7v t+DM1C09Z5YnD0seZtXVmIT7usslspMzDLQ== X-Received: by 2002:a50:fd13:: with SMTP id i19mr13052919eds.280.1622632218114; Wed, 02 Jun 2021 04:10:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw06pkyMIjDmtQIx52ngcNxG9a4Pd49N7BCx77O2/Snm6f9UtSwWihRBF+HkFpauz9Ft3wqoQ== X-Received: by 2002:a50:fd13:: with SMTP id i19mr13052906eds.280.1622632217929; Wed, 02 Jun 2021 04:10:17 -0700 (PDT) Received: from [192.168.1.115] (xdsl-188-155-185-9.adslplus.ch. [188.155.185.9]) by smtp.gmail.com with ESMTPSA id d24sm1142127edp.7.2021.06.02.04.10.17 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 02 Jun 2021 04:10:17 -0700 (PDT) To: Joe Perches , linux-nfc@lists.01.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20210601160713.312622-1-krzysztof.kozlowski@canonical.com> <5780056e09dbbd285d470a313939e5d3cc1a0c3e.camel@perches.com> From: Krzysztof Kozlowski Message-ID: Date: Wed, 2 Jun 2021 13:10:16 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: <5780056e09dbbd285d470a313939e5d3cc1a0c3e.camel@perches.com> Content-Language: en-US Message-ID-Hash: TW7DGCYT3Z3E66AS57222ZBXZBR72AJL X-Message-ID-Hash: TW7DGCYT3Z3E66AS57222ZBXZBR72AJL X-MailFrom: krzysztof.kozlowski@canonical.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header X-Mailman-Version: 3.1.1 Precedence: list Subject: [linux-nfc] Re: [PATCH] nfc: mrvl: remove useless "continue" at end of loop List-Id: NFC on Linux Archived-At: List-Archive: List-Help: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 T24gMDEvMDYvMjAyMSAxODozMCwgSm9lIFBlcmNoZXMgd3JvdGU6DQo+IE9uIFR1ZSwgMjAyMS0w Ni0wMSBhdCAxODowNyArMDIwMCwgS3J6eXN6dG9mIEtvemxvd3NraSB3cm90ZToNCj4+IFRoZSAi Y29udGludWUiIHN0YXRlbWVudCBhdCB0aGUgZW5kIG9mIGEgZm9yIGxvb3AgZG9lcyBub3QgaGF2 ZSBhbg0KPj4gZWZmZWN0Lg0KPiBbXQ0KPj4gZGlmZiAtLWdpdCBhL2RyaXZlcnMvbmZjL25mY21y dmwvdXNiLmMgYi9kcml2ZXJzL25mYy9uZmNtcnZsL3VzYi5jDQo+IFtdDQo+PiBAQCAtMzI1LDcg KzMyNSw2IEBAIHN0YXRpYyBpbnQgbmZjbXJ2bF9wcm9iZShzdHJ1Y3QgdXNiX2ludGVyZmFjZSAq aW50ZiwNCj4+IMKgCQlpZiAoIWRydl9kYXRhLT5idWxrX3J4X2VwICYmDQo+PiDCoAkJICAgIHVz Yl9lbmRwb2ludF9pc19idWxrX2luKGVwX2Rlc2MpKSB7DQo+PiDCoAkJCWRydl9kYXRhLT5idWxr X3J4X2VwID0gZXBfZGVzYzsNCj4+IC0JCQljb250aW51ZTsNCj4+IMKgCQl9DQo+PiDCoAl9DQo+ IA0KPiBJIHRoaW5rIHRoaXMgY29kZSB3b3VsZCBiZSBjbGVhcmVyIHdpdGggYW4gaWYvZWxzZSBp bnN0ZWFkIG9mDQo+IG11bHRpcGxlIGNvbnRpbnVlcy4NCg0KTWFrZXMgc2Vuc2UuIEknbGwgc2Vu ZCBhIHYyLg0KDQoNCkJlc3QgcmVnYXJkcywNCktyenlzenRvZgpfX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fXwpMaW51eC1uZmMgbWFpbGluZyBsaXN0IC0tIGxp bnV4LW5mY0BsaXN0cy4wMS5vcmcKVG8gdW5zdWJzY3JpYmUgc2VuZCBhbiBlbWFpbCB0byBsaW51 eC1uZmMtbGVhdmVAbGlzdHMuMDEub3JnCiUod2ViX3BhZ2VfdXJsKXNsaXN0aW5mbyUoY2dpZXh0 KXMvJShfaW50ZXJuYWxfbmFtZSlz From mboxrd@z Thu Jan 1 00:00:00 1970 Content-Type: multipart/mixed; boundary="===============7360870516417872868==" MIME-Version: 1.0 From: Krzysztof Kozlowski To: linux-nfc@lists.01.org Subject: Re: [PATCH] nfc: mrvl: remove useless "continue" at end of loop Date: Wed, 02 Jun 2021 13:10:16 +0200 Message-ID: In-Reply-To: <5780056e09dbbd285d470a313939e5d3cc1a0c3e.camel@perches.com> List-Id: --===============7360870516417872868== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable On 01/06/2021 18:30, Joe Perches wrote: > On Tue, 2021-06-01 at 18:07 +0200, Krzysztof Kozlowski wrote: >> The "continue" statement at the end of a for loop does not have an >> effect. > [] >> diff --git a/drivers/nfc/nfcmrvl/usb.c b/drivers/nfc/nfcmrvl/usb.c > [] >> @@ -325,7 +325,6 @@ static int nfcmrvl_probe(struct usb_interface *intf, >> =C2=A0 if (!drv_data->bulk_rx_ep && >> =C2=A0 usb_endpoint_is_bulk_in(ep_desc)) { >> =C2=A0 drv_data->bulk_rx_ep =3D ep_desc; >> - continue; >> =C2=A0 } >> =C2=A0 } > = > I think this code would be clearer with an if/else instead of > multiple continues. Makes sense. I'll send a v2. Best regards, Krzysztof --===============7360870516417872868==--