From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751510AbdKZSRj (ORCPT ); Sun, 26 Nov 2017 13:17:39 -0500 Received: from mail3-relais-sop.national.inria.fr ([192.134.164.104]:8221 "EHLO mail3-relais-sop.national.inria.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751318AbdKZSRi (ORCPT ); Sun, 26 Nov 2017 13:17:38 -0500 X-IronPort-AV: E=Sophos;i="5.44,460,1505772000"; d="scan'208";a="246039391" Date: Sun, 26 Nov 2017 19:17:36 +0100 (CET) From: Julia Lawall X-X-Sender: jll@hadrien To: Logan Gunthorpe cc: linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, Andy Whitcroft , Joe Perches Subject: Re: [PATCH v2] checkpatch: Add a warning for log messages that don't end in a new line In-Reply-To: <3fc88c02-b9b6-80a3-0c41-63e0806d34aa@deltatee.com> Message-ID: References: <20171126054037.9743-1-logang@deltatee.com> <85bdbab8-8b7e-91a9-7199-a0e39041aef1@deltatee.com> <3fc88c02-b9b6-80a3-0c41-63e0806d34aa@deltatee.com> User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, 26 Nov 2017, Logan Gunthorpe wrote: > > > On 26/11/17 10:09 AM, Julia Lawall wrote: > > I don't know. In any case, a Coccinelle script would get run by the 0-day > > build testing service, which checks lots of trees. Perhaps both are > > useful, since Joe had some conerns about the amount of relevant context > > available in a patch. > > Yup, both could certainly be useful. A coccinelle script would likely be > able to catch a few false negatives that might pass through the > checkpatch script. It'll likely have similar difficulties with > KERN_CONTs though. Not sure why. I just assume that a printk that has no KERN_ is adding a newline, which is my understanding of Joe's comment. The main limitation that is likely to remain in my script is that Coccinelle doesn't always understand ifdefs properly. So #ifdef printk("xxx"); #else printk("yyy"); #endif pr_cont("zzz"); may give a warning about the first printk. > Also, I don't really know, but it might be tough enabling a script to > run on 0-day with the ~6000 potential errors already existing. 0-day only runs on changed files and only reports on changed code, to the best of my understanding, so I don't think it is a problem. julia > > Logan > -- > To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html >