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=-13.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 5A69BC433E0 for ; Sat, 30 Jan 2021 18:55:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 22B7964E13 for ; Sat, 30 Jan 2021 18:55:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231855AbhA3Sz1 (ORCPT ); Sat, 30 Jan 2021 13:55:27 -0500 Received: from smtprelay0024.hostedemail.com ([216.40.44.24]:51474 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S230045AbhA3Sz0 (ORCPT ); Sat, 30 Jan 2021 13:55:26 -0500 Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay06.hostedemail.com (Postfix) with ESMTP id D06351800AEC5; Sat, 30 Jan 2021 18:54:44 +0000 (UTC) X-Session-Marker: 6A6F6540706572636865732E636F6D X-HE-Tag: match33_441563d275b3 X-Filterd-Recvd-Size: 3597 Received: from [192.168.1.159] (unknown [47.151.137.21]) (Authenticated sender: joe@perches.com) by omf16.hostedemail.com (Postfix) with ESMTPA; Sat, 30 Jan 2021 18:54:43 +0000 (UTC) Message-ID: <52f038d9ff547deee4e5b5628507e61ec8d056b7.camel@perches.com> Subject: Re: [PATCH 02/29] alpha: Avoid comma separated statements From: Joe Perches To: Jiri Kosina , Robert Richter Cc: Richard Henderson , Ivan Kokshaysky , Matt Turner , linux-alpha@vger.kernel.org, linux-kernel@vger.kernel.org, oprofile-list@lists.sf.net Date: Sat, 30 Jan 2021 10:54:42 -0800 In-Reply-To: <4facd57f80c70437f085ba3a1bcf13ae0b63c3bc.1598331148.git.joe@perches.com> References: <4facd57f80c70437f085ba3a1bcf13ae0b63c3bc.1598331148.git.joe@perches.com> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.38.1-1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2020-08-24 at 21:55 -0700, Joe Perches wrote: > Use semicolons and braces. ping? > > Signed-off-by: Joe Perches > --- >  arch/alpha/kernel/pci_iommu.c | 8 +++++--- >  arch/alpha/oprofile/op_model_ev4.c | 22 ++++++++++++++-------- >  arch/alpha/oprofile/op_model_ev5.c | 8 +++++--- >  3 files changed, 24 insertions(+), 14 deletions(-) > > diff --git a/arch/alpha/kernel/pci_iommu.c b/arch/alpha/kernel/pci_iommu.c > index 81037907268d..b8af7ad6c607 100644 > --- a/arch/alpha/kernel/pci_iommu.c > +++ b/arch/alpha/kernel/pci_iommu.c > @@ -161,10 +161,12 @@ iommu_arena_find_pages(struct device *dev, struct pci_iommu_arena *arena, >   goto again; >   } >   > > - if (ptes[p+i]) > - p = ALIGN(p + i + 1, mask + 1), i = 0; > - else > + if (ptes[p+i]) { > + p = ALIGN(p + i + 1, mask + 1); > + i = 0; > + } else { >   i = i + 1; > + } >   } >   > >   if (i < n) { > diff --git a/arch/alpha/oprofile/op_model_ev4.c b/arch/alpha/oprofile/op_model_ev4.c > index 086a0d5445c5..004f80a4291f 100644 > --- a/arch/alpha/oprofile/op_model_ev4.c > +++ b/arch/alpha/oprofile/op_model_ev4.c > @@ -46,18 +46,24 @@ ev4_reg_setup(struct op_register_config *reg, >   map it onto one of the possible values, and write it back. */ >   > >   count = ctr[0].count; > - if (count <= 4096) > - count = 4096, hilo = 1; > - else > - count = 65536, hilo = 0; > + if (count <= 4096) { > + count = 4096; > + hilo = 1; > + } else { > + count = 65536; > + hilo = 0; > + } >   ctr[0].count = count; >   ctl |= (ctr[0].enabled && hilo) << 3; >   > >   count = ctr[1].count; > - if (count <= 256) > - count = 256, hilo = 1; > - else > - count = 4096, hilo = 0; > + if (count <= 256) { > + count = 256; > + hilo = 1; > + } else { > + count = 4096; > + hilo = 0; > + } >   ctr[1].count = count; >   ctl |= (ctr[1].enabled && hilo); >   > > diff --git a/arch/alpha/oprofile/op_model_ev5.c b/arch/alpha/oprofile/op_model_ev5.c > index c300f5ef3482..6f52244e1181 100644 > --- a/arch/alpha/oprofile/op_model_ev5.c > +++ b/arch/alpha/oprofile/op_model_ev5.c > @@ -92,9 +92,11 @@ common_reg_setup(struct op_register_config *reg, >   if (!ctr[i].enabled) >   continue; >   > > - if (count <= 256) > - count = 256, hilo = 3, max = 256; > - else { > + if (count <= 256) { > + max = 256; > + hilo = 3; > + count = 256; > + } else { >   max = (i == 2 ? 16384 : 65536); >   hilo = 2; >   if (count > max)