From owner-dev-commits-src-main@freebsd.org Tue Apr 27 07:47:43 2021 Return-Path: Delivered-To: dev-commits-src-main@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 19BCF623C79 for ; Tue, 27 Apr 2021 07:47:43 +0000 (UTC) (envelope-from kevin.bowling@kev009.com) Received: from mail-yb1-xb29.google.com (mail-yb1-xb29.google.com [IPv6:2607:f8b0:4864:20::b29]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FTv4b03Cwz3NWS for ; Tue, 27 Apr 2021 07:47:42 +0000 (UTC) (envelope-from kevin.bowling@kev009.com) Received: by mail-yb1-xb29.google.com with SMTP id z1so68188971ybf.6 for ; Tue, 27 Apr 2021 00:47:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kev009.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=LREb4jvybnvurd6igzOKu1Qar+KycOTbFuLgUq+Mikw=; b=Pqnfj/3xj1zdISPEginSPYnxM2jlVvxiNWZHWOjptsKtH8d+62mHYhIUcD4SaOtqEH wmJ/lqqgMKOSHrHYSGMGV+KJsjGYgXo2JSSD02RN0CDrS+KtFI3Yy10A5z82ORrZhTdy eDaLqYd+8XwpSokjVPsR2jLx6ng7vRffvQ+AY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=LREb4jvybnvurd6igzOKu1Qar+KycOTbFuLgUq+Mikw=; b=i14I3NWmduNxm1mEKwOuCwUHrSwrs6pBvmNP36ih57Mp1PIrNWy8LNkWRalSKEtUeq vBtBu+IZRfTgjB3RtkA8kKkbneEDeKeyNXOCxl2JIU86R9ev4/FcceggTYqiueeKBwdI /X5cyrF6jPvSQA2JFMk4yrILdCZLtEyLcNVls/0vOoAGnsZhEeVPmbWNGvVbP5mMDHlH 476T+rAwSTPm2YeNhJDxf8d32Kdq1CzOd07lpMcM9hFZIf6rRzCf/MhXYtqjUbHyfigb CsDaoeBjBFx3Sb15AyX/MQUcNAq9ymiOFTwbufpDEiEqF0PlB98XxbblBEF8RNLXnide fdag== X-Gm-Message-State: AOAM531ypKJWL2Qojx7RyVWBsiJNTVAoFBu8WveUZChVnQGwvZAS+N49 mF011Vh9+v874N8AAzg2o9RTPCdUbrVKtmzHDHwqxg== X-Google-Smtp-Source: ABdhPJwZhXTHnM1p03xJ0DgX0usykGQYRv2AItER7SDQqQQU1Em2TO7nJxZ3OCH72Q0xviIOe+JpJbWnMgqDWQWP2M8= X-Received: by 2002:a25:680c:: with SMTP id d12mr29165075ybc.87.1619509661971; Tue, 27 Apr 2021 00:47:41 -0700 (PDT) MIME-Version: 1.0 References: <202104261525.13QFPrbg086311@gitrepo.freebsd.org> <9b006e97a64d01d128d81bc09f0891ea@freebsd.org> <20210427070122.302abed2@ernst.home> In-Reply-To: <20210427070122.302abed2@ernst.home> From: Kevin Bowling Date: Tue, 27 Apr 2021 00:47:31 -0700 Message-ID: Subject: Re: git: e657f3de6dc2 - main - linuxkpi: Remove unneeded {} in atomic_dec_and_lock_irqsave() To: gljennjohn@gmail.com Cc: Neel Chauhan , Rick Macklem , "dev-commits-src-all@FreeBSD.org" , "dev-commits-src-main@FreeBSD.org" , src-committers X-Rspamd-Queue-Id: 4FTv4b03Cwz3NWS X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.34 X-BeenThere: dev-commits-src-main@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for the main branch of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Apr 2021 07:47:43 -0000 On Tue, Apr 27, 2021 at 12:01 AM Gary Jennejohn wrote: > On Mon, 26 Apr 2021 17:16:01 -0700 > Kevin Bowling wrote: > > > Yup, I don't want to fatigue Neel or the tree with unnecessary churn, > > he had the parens, someone said something about brackets {} and he > > removed the parens. Since the function needs a rework per mjg's > > review, it could be done when that occurs. > > > > I'd say that the misunderstanding was caused by the use of the word > brackets in the comment. > > Looking up bracket on wiktionary gives this definitiotn: > > 5. Any of the characters "(", ")", "[", "]", "{", "}", "<" and ">", > used in pairs to enclose parenthetic remarks, sections of mathematical > expressions, etc. > > (Britain) "(" and ")" specifically, the other forms above > requiring adjectives for disambiguation. > > (US) "[" and "]" specifically - as opposed to the other forms, > which have their own technical names. > > So, if Neel is used to BE he would remove the parens, which he did. I, > as an American, would have been looking for [] and been confused by not > finding any. > Thanks for the explanation. > So, in future it might be best to explicitly use e.g. {}, [], () in such > comments. > Seems reasonable and effective. The man page uses precise language and has the symbols. > > On Mon, Apr 26, 2021 at 3:29 PM Rick Macklem > wrote: > > > > > > Neel wrote: > > > >On 2021-04-26 09:47, Kevin Bowling wrote: > > > >> I'm not sure all the context or conversation here but the convention > > > >> is to not use bare return values, i.e in style(9) "Values in return > > > >> statements should be enclosed in parentheses." and that's what was > > > >> asked to be changed on this mailing list. > > > Just fyi to everyone, there is this in style(9): > > > In general code can be considered ___new code___ when it makes up > about 50% > > > or more of the file(s) involved. This is enough to break > precedents in > > > the existing code and use the current style guidelines. > > > > > > As such, if the "return 0;" predates this patch series, Neel is correct > > > to use "return 1;", since that precedent has already been established. > > > I'll admit I see the above ignored a lot and personally don't care if > > > the above generality is followed, but it is in style(9) and I do > > > think a consistent style is preferred over a jumble within a source > file. > > > > > > rick > > > > > > The review: https://reviews.freebsd.org/D29988 > > > > > > I believe I was asked to do this in the review. > > > > > > -Neel > > > > > > > > Can you use and link to Phabricator for your src commits? As much as > > > > possible it is preferable to get it right in one go, for MFCs, > > > > bisection, etc and this kind of churn should be preventable with > quick > > > > reviews. Feel free to tag me as a reviewer. > > > > > > Sure, will do next time. > > > > > > > > > > Regards, > > > > Kevin > > > > > > -Neel > > > > > _______________________________________________ > > dev-commits-src-all@freebsd.org mailing list > > https://lists.freebsd.org/mailman/listinfo/dev-commits-src-all > > To unsubscribe, send any mail to " > dev-commits-src-all-unsubscribe@freebsd.org" > > > -- > Gary Jennejohn >