From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752455AbbJYXxp (ORCPT ); Sun, 25 Oct 2015 19:53:45 -0400 Received: from mail-oi0-f43.google.com ([209.85.218.43]:34267 "EHLO mail-oi0-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752112AbbJYXxn (ORCPT ); Sun, 25 Oct 2015 19:53:43 -0400 Subject: Re: [PATCH 2/2] Fixed Trivial Warnings in file: Deleted Spaces prior to tabs, and added lines. modified: kernel/auditfilter.c To: Richard Guy Briggs References: <1444528675-13184-1-git-send-email-scott@matheina.com> <10476084.rIoW7K08e6@sifl> <5623DBF5.8020500@matheina.com> <20151019161035.GB11501@madcap2.tricolour.ca> <1445435918.9220.9.camel@perches.com> <20151021153339.GA5269@madcap2.tricolour.ca> <56282E2E.4010207@matheina.com> <20151022021500.GD5269@madcap2.tricolour.ca> Cc: Joe Perches , Paul Moore , linux-audit@redhat.com, trivial@kernel.org, linux-kernel@vger.kernel.org From: Scott Matheina Message-ID: <562D6B84.2090703@matheina.com> Date: Sun, 25 Oct 2015 18:53:40 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <20151022021500.GD5269@madcap2.tricolour.ca> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/21/2015 09:15 PM, Richard Guy Briggs wrote: > On 15/10/21, Scott Matheina wrote: >> On 10/21/2015 10:33 AM, Richard Guy Briggs wrote: >>> On 15/10/21, Joe Perches wrote: >>>> On Mon, 2015-10-19 at 12:10 -0400, Richard Guy Briggs wrote: >>>>> On 15/10/18, Scott Matheina wrote: >>>>>> On 10/14/2015 04:54 PM, Paul Moore wrote: >>>>>>> On Saturday, October 10, 2015 08:57:55 PM Scott Matheina wrote: >>>> [] >>>>>>>> diff --git a/kernel/auditfilter.c b/kernel/auditfilter.c >>>> [] >>>>>>>> @@ -109,6 +109,7 @@ void audit_free_rule_rcu(struct rcu_head *head) >>>>>>>> { >>>>>>>> struct audit_entry *e = container_of(head, struct audit_entry, rcu); >>>>>>>> audit_free_rule(e); >>>>>>>> + >>>>>>>> } >>>>>>> Why? >>>>>> I was following the error messages in checkpatch.pl, but the warning >>>>>> went away after adding this line. No problem with the code. >>>>> That sounds like a bug in checkpatch.pl, since that blank line should be >>>>> tween the declaration and the function call. >>>> checkpatch message asks for a blank line after the >>>> "struct audit_entry *e = ..." declaration. >>> Well then maybe it is a bug in his interpretation of the output of >>> checkpatch.pl? Scott, did you re-run checkpatch.pl after adding those >>> spaces? Did it pass? >> The error did go away. > Joe, I confirm the error went away. Looks like a bug in checkpatch.pl > to me. I tried a number of combinations of things and it didn't > complain about several things it should have. I did try a few other > things to make sure it was still finding problems like brace placement > and leading spaces, but it looks like the blank line checking code isn't > working. This is on 4.0, so maybe it has been fixed since then. Scott, > what kernel version are you using? I had just cloned Linus' repo, so v4.3rc6. > >>>>>>>> while (*list != ~0U) { >>>>>>>> + >>>>>>>> unsigned n = *list++; >>>>>>>> if (n >= AUDIT_BITMASK_SIZE * 32 - AUDIT_SYSCALL_CLASSES) { >>>>>>>> kfree(p); >>>>>>> Why? >>>>>> This is the same as above. Just going through the checkpatch.pl >>>>>> script, and looking for warnings to fix. >>>>> Again, another manifestation of that bug? That blank line should be >>>>> after the declaration and before the if statement. >>>> [] >>>>> Well, I agree, you have to start somewhere... Too bad you hit a bug in >>>>> checkpatch.pl! >>>> Here too, not a bug in checkpatch. >>>> >>>> checkpatch output asks for a blank line after the >>>> "unsigned n" declaration, not before. >>> - RGB > - RGB > > -- > Richard Guy Briggs > Senior Software Engineer, Kernel Security, AMER ENG Base Operating Systems, Red Hat > Remote, Ottawa, Canada > Voice: +1.647.777.2635, Internal: (81) 32635, Alt: +1.613.693.0684x3545