Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp4173980pxb; Mon, 27 Sep 2021 10:54:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyu4JQZ3ujHy45ksc5TzbtoynVqf2m8/bPRq+YcfgIi7NdhSQNN9EK0dcMJNuw3S2+ZyGSu X-Received: by 2002:a17:902:ce83:b0:13b:67d5:2c4e with SMTP id f3-20020a170902ce8300b0013b67d52c4emr996863plg.45.1632765284425; Mon, 27 Sep 2021 10:54:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632765284; cv=none; d=google.com; s=arc-20160816; b=as3iQYdfjGs4RzT+wSFTLHurOekn7xVvkhnrzJemJNhzPLwcQgAUl5SKOu2s/ZnQki wFCKI8VkSD2dBoyjn4dayroLm/KPlGGRZNjc1x5dsIrZy5L5G4TuNfgU9pgdATwesa+R NTqeO9G5MPLAxi+30VRlhrUziByhidX1EVxNG3qQgJjZU4Tk3zWNlkcWBagXe2LIKfGJ rdBp+s2Y420TyDyqjJj6XsgeXgss987CGnoe/YlRbq9hsQoA7txuJz2mBkAC69oVEZIr 53PSP0aX5JHt7n8Q7918HrtVbCf2onYw+a4WHsqANTeDzeMenWxgjPlI9kEPAl+I5Ugl TbdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id; bh=223MtschhaOtg+N0qSGvLAz3GOkt/EbGnyMGGzctdKA=; b=pcby9BXbKQ5namCYxAmde/jVuc5uE6YwhDRAEkQ+6Ai282v0A8OhHzrhbLf0r8HnW6 MPKE9zZjj83rSwfpEAh1bm5+tV6OGmAxrRUk+ObGVZNwkoCWvzZdrUQS6ucpbCpoR0BJ CekeNozoXewU54mB3bnQpnAucu5buahMpWOwqX11HC5EktwDjtIHvQRcQXMMnTWC1h3F Ljop6DBmMN1exI08xcZdR1vdaK4SSzTbiht6p8niZLalzZOe06ELrRMlB+weJ5wbj/7l R5ziNRV9Yh15ANhbcucjCiPFBH6VgdBHHNuDAtZaku5I6nGaFOmXSJiv5O7dmmWgxEr0 dGgA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z25si6178956pfg.336.2021.09.27.10.54.31; Mon, 27 Sep 2021 10:54:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235781AbhI0Ryw (ORCPT + 99 others); Mon, 27 Sep 2021 13:54:52 -0400 Received: from smtprelay0154.hostedemail.com ([216.40.44.154]:37166 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S235693AbhI0Ryr (ORCPT ); Mon, 27 Sep 2021 13:54:47 -0400 Received: from omf10.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay08.hostedemail.com (Postfix) with ESMTP id 06005182CF66A; Mon, 27 Sep 2021 17:53:08 +0000 (UTC) Received: from [HIDDEN] (Authenticated sender: joe@perches.com) by omf10.hostedemail.com (Postfix) with ESMTPA id EEE282351FD; Mon, 27 Sep 2021 17:53:06 +0000 (UTC) Message-ID: <06f4c72fefeedb5145a940e5a78d50e610acdcc4.camel@perches.com> Subject: Re: [PATCH] Documentation: checkpatch: Document some more message types From: Joe Perches To: Jonathan Corbet , Utkarsh Verma , Dwaipayan Ray Cc: Lukas Bulwahn , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org Date: Mon, 27 Sep 2021 10:53:05 -0700 In-Reply-To: <875yulj4m8.fsf@meer.lwn.net> References: <20210925201746.15917-1-utkarshverma294@gmail.com> <875yulj4m8.fsf@meer.lwn.net> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.40.0-1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.24 X-Stat-Signature: jdo8rn3iu85ra5dgdfz9s646q3uffz3s X-Rspamd-Server: rspamout02 X-Rspamd-Queue-Id: EEE282351FD X-Session-Marker: 6A6F6540706572636865732E636F6D X-Session-ID: U2FsdGVkX1/rK5szfXkBwjy2oIFBr8NmlE5PEiJTWk8= X-HE-Tag: 1632765186-292574 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2021-09-27 at 11:43 -0600, Jonathan Corbet wrote: > Utkarsh Verma writes: > > > Added and documented 3 new message types: > > - UNNECESSARY_INT > > - UNSPECIFIED_INT > > - UNNECESSARY_ELSE > > > > Signed-off-by: Utkarsh Verma > > --- > > ?Documentation/dev-tools/checkpatch.rst | 47 ++++++++++++++++++++++++++ > > ?1 file changed, 47 insertions(+) > > So...when you send multiple patches with the same subject line that's > always a bad sign. We really want a "git --oneline" listing to give a > good idea of what the patch does, and that depends on more descriptive > subject lines. > > In this case, something like: > > ??docs: checkpatch: add UNNECESSARY/UNSPECIFIED_INT and UNNECESSARY_ELSE > > I can fix up these two patches, but please try to keep this in mind for > future work. > > (applying the patches now). The unnecessary_else description isn't particularly good as the checkpatch output doesn't describe multiple if/else if/else if type returns where the message should not apply. For this type of use, the checkpatch message is not necessarily correct and because it could be a patch context, there's no way for checkpatch to know if it's correct or not. if (foo) { ... } else if (bar) { ... return [val]; } else { ... }