Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1391661imm; Wed, 25 Jul 2018 17:41:57 -0700 (PDT) X-Google-Smtp-Source: AAOMgpfDkepQMcsSNi1RHeUp41awuyahISj5CQWmDf0HLjUDIm7HR57/4YLFes7CVtL5hD9lKEWz X-Received: by 2002:a63:4703:: with SMTP id u3-v6mr21706192pga.405.1532565717220; Wed, 25 Jul 2018 17:41:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532565717; cv=none; d=google.com; s=arc-20160816; b=kuNAsw4P+U13Filp3PnEtfYefsX4FnRTgcQejJbbszZY98JjSSdDSGbBW/BOh/Hfka Y6Xo6dHZfJ95irIYz4i+BywYeDgkG+5OaIsT2YFH+NLsSLGsHLym/EoMgqIpBL78Q8nE +JTM3ONKM+EbkL1KMuHE0Ip4I/hxo/tR5uJBMLfKRh3jo7n7TfTX/hroX5Qn58Bzb73w TGrueFoWVza8jpSlzizhoqN8be6JZSlaqVLLDkDgXBhOkUl6xc/GUDa1sqIkZCVnEZ5A aZE0R2IYdUuBlNl7IRxRBpoAss+qLQ8UYdOK7BhxLSTPBi+CrPbrkUZ6aJc15NrikNmR CUDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:message-id:references :in-reply-to:subject:cc:to:from:date:content-transfer-encoding :mime-version:dkim-signature:dkim-signature :arc-authentication-results; bh=mLJHOsjn7XgHuuOFu1O05kNXTOCBzEYAJKdCVLBqtcA=; b=WMM6cOkdEy1BjPi0Gq5sWwUyuYfKC9urFFW0MBnvRMRXVhImxJcxtwCoMh0vzesLKo vTGi6ui21Oz014cRLGQ0SmFTSnnvjv8uiN3129NCClK7FjhCrzePyLbxirFBh0oaXpBK h90mVmihUG5gD3iMgpnLo4o0NLWZfHbmLvGj3wMI1yVhDeOB0oRccKFMed4Vbz8l362h 7B6WrxgOEDDXrWQWfw1YdDBGhNkybPJaxa6Mt91FUVkYZX8ZvKzIb5cETTqAzKivA7d5 p6a6w6/iSkHm+RNkJfVqrZMK5UaoR8Bw7Tcf2nGTOulDTRlAQwW4k7cLbjn0XAcA0q/T aSMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=HnyssPl0; dkim=pass header.i=@codeaurora.org header.s=default header.b=gYJbWdzU; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j189-v6si14301125pgd.498.2018.07.25.17.41.40; Wed, 25 Jul 2018 17:41:57 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=HnyssPl0; dkim=pass header.i=@codeaurora.org header.s=default header.b=gYJbWdzU; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728547AbeGZBy7 (ORCPT + 99 others); Wed, 25 Jul 2018 21:54:59 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:34170 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728449AbeGZBy7 (ORCPT ); Wed, 25 Jul 2018 21:54:59 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 113CA60D50; Thu, 26 Jul 2018 00:40:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1532565647; bh=dRmfo4JXlTJZyHOPf7dZqprOBP37lKoV+qPGyAffKsg=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=HnyssPl0U7xOArPZE6i3ZvSdIxRUo/kW3Mv44c3AsBHU7IcsR/WbbLhGPs7I4XpL+ HiZEUd5rrnVlewQQ+LsDyf5X5YgXhD3YZRka68XUbKElrhfTjTYQpB+ynhPY5JTBcz ZRk2uSxSO8kjVHor5wszExffI3R2HjyAaLBnndNQ= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,T_DKIM_INVALID autolearn=no autolearn_force=no version=3.4.0 Received: from mail.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.codeaurora.org (Postfix) with ESMTP id F413960D37; Thu, 26 Jul 2018 00:40:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1532565646; bh=dRmfo4JXlTJZyHOPf7dZqprOBP37lKoV+qPGyAffKsg=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=gYJbWdzUogsGWvtFVnB2AwG9Q2vlDdsiUvKLzLdjQM0GmzqJ3cE5/XH//luu9jzVe jKFo8AVL/u+3iKMTWnGTTBbNgPOucdgQqojQvgPE08R2Gk744y6Hl2ESneLIIupECS HAGnjqMCNVnRh6IAbDTcpA4FGsYo9ljyrXiE8KlM= MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Wed, 25 Jul 2018 17:40:45 -0700 From: pheragu@codeaurora.org To: Joe Perches Cc: Apw , Linux Kernel , Bryanh , Ckadabi , Tsoni Subject: Re: Reminder to review a few patches sent two weeks ago In-Reply-To: <612de3c34f4986ac3ee6040af200a0e179acdcbd.camel@perches.com> References: <612de3c34f4986ac3ee6040af200a0e179acdcbd.camel@perches.com> Message-ID: <2263042da44fae7cae949ac383c41964@codeaurora.org> X-Sender: pheragu@codeaurora.org User-Agent: Roundcube Webmail/1.2.5 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2018-07-24 17:33, Joe Perches wrote: > On Tue, 2018-07-24 at 14:56 -0700, pheragu@codeaurora.org wrote: >> A reminder to review a few patches I had sent last week. Below are the >> links for the patches. >> >> https://lkml.org/lkml/2018/7/5/798 > > I have no fundamental object to this one, but > the 80 column use is unnecessary and should be > coalesced before it can be applied. > > Perhaps: > > # warn about #if 1 > if ($line =~ /^.\s*\#\s*if\s+1\b/) { > WARN("IF_1", > "Consider removing the #if 1 and its #endif\n" . $herecurr); > } > >> http://lists-archives.com/linux-kernel/29168320-checkpatch-check-for-invalid-return-codes.html > > This one has I think too many existing uses of > things like "return -1;" > > $ git grep -P "return\s*\-\d+\s*;" | wc -l > 9929 > > How many of these are actually appropriate? > I did go through a few of the files which return -1 in their functions, I observed that most of them were inappropriate and there was a case where actually the use of return -1 was incorrect(kernel/arch/ia64/mm/contig.c in the function find_bootmap_location()). We could actually catch such errors from now on if we use this patch. > Also, no space is required between return and -1 > by c90 and this should use $Int so it should be: > > if ($line =~ /\breturn\s*\-\$Int\s*;/) { > > etc...