From patchwork Fri Apr 1 15:20:55 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Roth X-Patchwork-Id: 89319 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 2F82BB6EEE for ; Sat, 2 Apr 2011 05:25:04 +1100 (EST) Received: from localhost ([127.0.0.1]:37981 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q5gSr-0003oC-5n for incoming@patchwork.ozlabs.org; Fri, 01 Apr 2011 11:40:45 -0400 Received: from [140.186.70.92] (port=56700 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q5gAE-0008R2-PJ for qemu-devel@nongnu.org; Fri, 01 Apr 2011 11:21:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q5gA6-0001s1-7H for qemu-devel@nongnu.org; Fri, 01 Apr 2011 11:21:23 -0400 Received: from e32.co.us.ibm.com ([32.97.110.150]:39411) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q5gA6-0001rO-0s for qemu-devel@nongnu.org; Fri, 01 Apr 2011 11:21:22 -0400 Received: from d03relay05.boulder.ibm.com (d03relay05.boulder.ibm.com [9.17.195.107]) by e32.co.us.ibm.com (8.14.4/8.13.1) with ESMTP id p31FANlo007326 for ; Fri, 1 Apr 2011 09:10:23 -0600 Received: from d03av01.boulder.ibm.com (d03av01.boulder.ibm.com [9.17.195.167]) by d03relay05.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id p31FL9oZ034932 for ; Fri, 1 Apr 2011 09:21:11 -0600 Received: from d03av01.boulder.ibm.com (loopback [127.0.0.1]) by d03av01.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id p31FL7G0022747 for ; Fri, 1 Apr 2011 09:21:09 -0600 Received: from localhost.localdomain (sig-9-76-192-60.mts.ibm.com [9.76.192.60]) by d03av01.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id p31FL5Go022479; Fri, 1 Apr 2011 09:21:07 -0600 From: Michael Roth To: qemu-devel@nongnu.org Date: Fri, 1 Apr 2011 10:20:55 -0500 Message-Id: <1301671255-27717-3-git-send-email-mdroth@linux.vnet.ibm.com> X-Mailer: git-send-email 1.7.0.4 In-Reply-To: <1301671255-27717-1-git-send-email-mdroth@linux.vnet.ibm.com> References: <1301671255-27717-1-git-send-email-mdroth@linux.vnet.ibm.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Received-From: 32.97.110.150 Cc: mdroth@linux.vnet.ibm.com, stefanha@linux.vnet.ibm.com Subject: [Qemu-devel] [PATCH 2/2] checkpatch.pl: make C99 comments a warning, not error X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org C99 comments are pretty heavilly used in QEMU, and don't violate anything mentioned in HACKING/CODING_STYLE. Make them warnings instead. Signed-off-by: Michael Roth --- scripts/checkpatch.pl | 2 +- test.c | 5 +++++ 2 files changed, 6 insertions(+), 1 deletions(-) create mode 100644 test.c diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 770d534..2aab4e9 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -1799,7 +1799,7 @@ sub process { # no C99 // comments if ($line =~ m{//}) { - ERROR("do not use C99 // comments\n" . $herecurr); + WARN("do not use C99 // comments\n" . $herecurr); } # Remove C99 comments. $line =~ s@//.*@@; diff --git a/test.c b/test.c new file mode 100644 index 0000000..fe3b163 --- /dev/null +++ b/test.c @@ -0,0 +1,5 @@ +//stuff +static int blah(void) +{ + return 1; +}