From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754699Ab0EJQYq (ORCPT ); Mon, 10 May 2010 12:24:46 -0400 Received: from mgw2.diku.dk ([130.225.96.92]:43824 "EHLO mgw2.diku.dk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753102Ab0EJQYn (ORCPT ); Mon, 10 May 2010 12:24:43 -0400 From: Nicolas Palix To: Randy Dunlap , Roland Dreier , Joe Perches , Andrew Morton , "David S. Miller" , Michal Marek , Sam Ravnborg , Julia Lawall , Gilles Muller , linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org, cocci@diku.dk, Wolfram Sang Cc: Kernel Janitors , Nicolas Palix Subject: [PATCH 0/4] Add a Coccinelle front-end script Date: Mon, 10 May 2010 18:24:23 +0200 Message-Id: <1273508667-5152-1-git-send-email-npalix@diku.dk> X-Mailer: git-send-email 1.7.0.4 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org New targets are added (coccicheck-) to call the 'coccinelle.sh' front-end in the 'scripts' directory with the argument. Four modes are defined: report, patch, context, and org. 'report' mode generates a list in the following format: file:line:column-column: message 'patch' mode proposes a generic fix, when possible. 'context' mode highlights lines of interest and their context in a diff-like style. 'org' mode generates a report in the Org mode format of Emacs. Three semantic patches, with a low rate of false positives, are also included. Other semantic patches will be provided later. Note that a semantic patch does not need to define all four modes. As many semantic patches may be proposed later, they are organized under sub-directories of 'scripts/coccinelle/'. We add a reference to the tool in the proposed changelog because it will make the changelog easier to understand for someone who is not aware of the tool. To apply a single semantic patch, the user can define the COCCI environment variable which gives the path to the semantic patch. Nicolas Palix (4): Add targets to use the Coccinelle checker Add scripts/coccinelle/drop_kmalloc_cast.cocci Add scripts/coccinelle/kzalloc-simple.cocci Add scripts/coccinelle/resource_size.cocci MAINTAINERS | 10 +++ Makefile | 20 +++++- scripts/coccinelle.sh | 28 ++++++++ scripts/coccinelle/drop_kmalloc_cast.cocci | 68 ++++++++++++++++++++ scripts/coccinelle/kzalloc-simple.cocci | 83 ++++++++++++++++++++++++ scripts/coccinelle/resource_size.cocci | 94 ++++++++++++++++++++++++++++ 6 files changed, 301 insertions(+), 2 deletions(-) create mode 100755 scripts/coccinelle.sh create mode 100644 scripts/coccinelle/drop_kmalloc_cast.cocci create mode 100644 scripts/coccinelle/kzalloc-simple.cocci create mode 100644 scripts/coccinelle/resource_size.cocci