Patchwork [07/12] checkpatch: Add QEMU specific rule

login
register
mail settings
Submitter Stefan Hajnoczi
Date June 22, 2012, 9:40 a.m.
Message ID <1340358009-16033-8-git-send-email-stefanha@linux.vnet.ibm.com>
Download mbox | patch
Permalink /patch/166561/
State New
Headers show

Comments

Stefan Hajnoczi - June 22, 2012, 9:40 a.m.
From: Stefan Weil <sw@weilnetz.de>

The new rule detects two wrong variants of QEMU.
It was tested with commit b5a8fe5e.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
---
 scripts/checkpatch.pl |    5 +++++
 1 file changed, 5 insertions(+)

Patch

diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 8850a5f..b98dc6c 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -2849,6 +2849,11 @@  sub process {
 				ERROR("lockdep_no_validate class is reserved for device->mutex.\n" . $herecurr);
 			}
 		}
+
+# QEMU specific tests
+		if ($rawline =~ /\b(?:Qemu|QEmu)\b/) {
+			WARN("use QEMU instead of Qemu or QEmu\n" . $herecurr);
+		}
 	}
 
 	# If we have no input at all, then there is nothing to report on