[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2] xen: Add MISRA support to cppcheck make rule


  • To: Jan Beulich <jbeulich@xxxxxxxx>
  • From: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>
  • Date: Thu, 9 Jun 2022 10:20:52 +0000
  • Accept-language: en-GB, en-US
  • Arc-authentication-results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 63.35.35.123) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dkim=[1,1,header.d=arm.com] dmarc=[1,1,header.from=arm.com])
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none
  • Arc-message-signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=MBJ7RpNMy22bNKVbTr9syrXjbU6dd7A4FGpRiwc/DHQ=; b=l/mvPPUbzEp70q4kXRVQhyXQqu+ad+LMEBe2wtbNqnC8urMsfxZDyLmJk6/W4+FAbbG+e2Ajm+5BlhwUl0rGiklxTOnPxdyHGMCPQKsPh8pXVmodAyBRKd5Xmr8ZBPq5frKTimve6Fy/5VkL7O6HXrZRb4wObg9IqKEe3PcQM8imzHS+ZJwBUZoDCqZ4+/o3S5xYY7kDKdO/VRHnswagR8yZF4vEzVbxMvoLm1yM0r+cRzYteRDAGbnmiRbPanFiu/9CfGCGUfUkyTU5kBi/+33Aw56UmwbzSedQHf8/56hWZ29LMvCS7SpXEuxGi+05wcR+PsImk9gwqj5OJtSzjg==
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=MBJ7RpNMy22bNKVbTr9syrXjbU6dd7A4FGpRiwc/DHQ=; b=J7csr6f3/cGl/vAsvm5V+nq1A8X18uReJypmz8fqp+UZJdItQcf1V3/QlvhdYTlTLC1k9NodT3XLyojh0vYZfhVGjUp4V99GzTvNoJWdluQ4gf+jrqoWEdRENenHy3ZSLNmi0OSP2cFXgEMhKtrrH2N/oPk41BHqcybmYe+GmJFLQiAluvrhxzepu0iLROKPXXlYUe7s705/R93JGUR0gntZpogCy9dE9dnrZPqk9Jb9XZ1TVoidki7h2w1xL0A71F6QdACwNV7ReH/CkbxVHAAIJymNVyNUqJzRMDktPXvKHtVfRFD5k5n3A1jKNlOF3dte86A97Bzlm4olRknvbQ==
  • Arc-seal: i=2; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=pass; b=EjJZNvjNU7FyUFMEOiUqy4NW+deF+6nw1yzBZeEC65gBxIImRNZ4Ync3mFfvyQ7d+lCoNsgZKvdqaNrtQnv8yb0zInHfgB0VOBHL/3PXMsdITdOXTH3+po2YT1KsVyJTQlDf1IWucnCgft1H1v8r1kRRbBV87JmmbMriAfPi8cWUyLqV1hFaY6mWLz+1m9jkV/PLDB9NYtFugHrtCtkCiKCLSIQSXo4brITGb3SFo35CwWH554yis8NNrPH4K0c7M3mJVdcm1/A20cBdLFVMkkcZSLk8rnm44jNY1eR6fgR/lukkxLjQoa0KCkHN234Pon9vrLWJxjKILA2mOljErw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JMP2YdQTe5PGJC9dMDyKc/DZpye0pCo4YijfAZY0oQKIr6XwbK+CwuKtE1ImQa0BxZ//su9Vnc4nbRLH0Os4Ru8x8Hs741dDQf/jzXjIda0AOXq2I00DpQUWGuKOZUTU2+mpaNpWlykliDkmfXZKkVJ5xYTYMb+c1o4L7U45JeMVd6Bo6mDZ0BoPLGKXk9riGvRclSdfxE+XKjKklVWqGMSeb+7GPZhB13vrvemMU/cVwksi7mvuj4M17L/QGnKdC4ZyfJSP4kvUQpkTFgg+8NXIkZFLpkwer3T8YtaUaKZ3NlMXYOqK/4T8SxdCBhvE4N0hAd6XEQZEsXhEj8v2Sw==
  • Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Thu, 09 Jun 2022 10:21:11 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Original-authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Thread-index: AQHYe+Q/CnV4rYCY7UiS7+9Bq/v4m61G2wEAgAACZwA=
  • Thread-topic: [PATCH v2] xen: Add MISRA support to cppcheck make rule

Hi Jan,

> On 9 Jun 2022, at 11:12, Jan Beulich <jbeulich@xxxxxxxx> wrote:
> 
> On 09.06.2022 11:34, Bertrand Marquis wrote:
>> cppcheck MISRA addon can be used to check for non compliance to some of
>> the MISRA standard rules.
>> 
>> Add a CPPCHECK_MISRA variable that can be set to "y" using make command
>> line to generate a cppcheck report including cppcheck misra checks.
>> 
>> When MISRA checking is enabled, a file with a text description suitable
>> for cppcheck misra addon is generated out of Xen documentation file
>> which lists the rules followed by Xen (docs/misra/rules.rst).
>> 
>> By default MISRA checking is turned off.
>> 
>> While adding cppcheck-misra files to gitignore, also fix the missing /
>> for htmlreport gitignore
>> 
>> Signed-off-by: Bertrand Marquis <bertrand.marquis@xxxxxxx>
>> ---
>> Changes in v2:
>> - fix missing / for htmlreport
>> - use wildcard for cppcheck-misra remove and gitignore
>> - fix comment in makefile
>> - fix dependencies for generation of json and txt file
>> ---
>> .gitignore | 3 +-
>> xen/Makefile | 29 ++++++-
>> xen/tools/convert_misra_doc.py | 139 +++++++++++++++++++++++++++++++++
>> 3 files changed, 168 insertions(+), 3 deletions(-)
>> create mode 100755 xen/tools/convert_misra_doc.py
>> 
>> diff --git a/.gitignore b/.gitignore
>> index 18ef56a780..b106caa7a9 100644
>> --- a/.gitignore
>> +++ b/.gitignore
>> @@ -297,6 +297,7 @@ xen/.banner
>> xen/.config
>> xen/.config.old
>> xen/.xen.elf32
>> +xen/cppcheck-misra.*
> 
> As said on v1, this wants to be added further down, while ...
> 
>> xen/xen-cppcheck.xml
> 
> ... this line wants moving down at this occasion or in a separate
> change.
> 
>> xen/System.map
>> xen/arch/x86/boot/mkelf32
>> @@ -318,7 +319,7 @@ xen/arch/*/efi/runtime.c
>> xen/arch/*/include/asm/asm-offsets.h
>> xen/common/config_data.S
>> xen/common/config.gz
>> -xen/cppcheck-htmlreport
>> +xen/cppcheck-htmlreport/
>> xen/include/headers*.chk
>> xen/include/compat/*
>> xen/include/config/
> 
> xen/cppcheck-misra.* wants to go alongside the line you adjust, while
> xen/xen-cppcheck.xml belongs yet further down.

Sorry I forgot that part in my v2.
I will do all fixes including xen-cppcheck.xml one in a v3 shortly.

Cheers
Bertrand




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.