[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3] docs/misra: add R13.2 and R18.2 to rules.rst
- To: Stefano Stabellini <sstabellini@xxxxxxxxxx>
- From: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>
- Date: Fri, 2 Aug 2024 06:47:29 +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=arm.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=arcselector10001; 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=uBjOL499370Q3laRLvdGLAYxWnUBhC68FAW97vUgoF0=; b=tLzmceOA5ewZi0mbcL3t2lWdliUFh4s7nvYKXpLLL0Ls+CErRqQMJb0BHewafWzgfH9LIF9zT8BVz2jrPQqHY++zXe2H9E1z9f6E1v93hKJmO4pxrvpEjAPC/izYupviKyka2tbxR5Ni23a//cRqWFX8bBRzuDBSrAb6V+8ZoN8FN5VJ9iCruVgL5q31RoTLM/PwUFMmDLPEuK7jHuLXWGEl0bFhWSK2vqT4EVkoquH4dU+7h8Lr77lv2faJPI27Dp+RX8f75OrWXxtYLaELQTI1m0k0/7nEyeU9wnoS+zViRRseWyMvhcZicBxoYqenX2/ZBcMWuO9ySm+DBHhGww==
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=uBjOL499370Q3laRLvdGLAYxWnUBhC68FAW97vUgoF0=; b=lROzZNcULHTqVVtcstW7V7N9aTuwFXHxqh07GlP0dtSuetWpOYtJjdhj4p8A/Lk4szDQ1w5zKPIf5bNS5gk5Q4IPmZVMwGFgD04tvKnjLCSA2Tczmnq0b8I6vIv0SWG7YKV9EabFxCD1hOOwJUm7juT2vuWbmPMXOdGOkheiddRsvml4/cA8Y5ehJESNZMFvejdvPfWON4atICW08NwqISOua7yKw/pomgFFxAvSIdmrWs4ZuNWVeL3zCpdixtGjJDZfIEr1zokQr88qF5X2y47wlW//m2eWllfq9eaiezlUmNTePfZ1KeFGtE8lfJXnIU/zQs+E8DmupifjhawVfQ==
- Arc-seal: i=2; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=pass; b=XZV904lRY2afThric93gF4TVRxD2/Vf2dJTdzACXZkXCsNmJYwDuVo+WpzeoncK9ubtxqKdaH6giTksPVE/1ZlFcsl7VRctgSWLRHPKrTw4fHBYzoJm4q5AD1VkQ+PSHVEsyb0aYgLPVrdoGy6XF4ZunG1JNCu1smqq9BvZkT55eodvZFwoKt3t0ufNAjukz5O+poKISVXXA1cctUgOSwycxCJuEtg+GrnX+xDJ8PdSqsR5pJatNTwie0cLNfui1U0hYClyqvXJWCHRbPagSKGlJx/DapJ0KT+OJZwgqSF6Qi4wrbndN0Mnjkhtvy8WyWs4jD1HgGuQmwnxrntTIoA==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=UsUpiziTFr8R+Jf1qwLs030ZK54Dys12Ax1AYiRhOdwM5q1MaSdzfbLtKMxM9pBcKf2F8+hNqED79tv4sob50JxbjF/0MYV9llLFWKtmU3TC9WnXhlzOaQXpHrdpWjhSVUnrW1AyrJxJjoNx7DYtPdE/nv62+uxNl5WoVTn0Q7Tc5ZeY8cq0JmhAfjimDNWqMZEWgaZLyxfSb1CECmxcrC9tRazwsJoRZhMjU6TvYCmWuMJNmcpB0bruFDXYI2hmNvq/nsrc3szWAO+RVWsZcJkM16pP4oP79QIAyZ9BfxZPt0sbGEMBaADNUxu/UaDKnmHU72UeYN1htB46uwHbSA==
- Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
- Cc: Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>
- Delivery-date: Fri, 02 Aug 2024 06:48:06 +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: AQHa5EfVsHAUXHnoukyrQTWk1ek7dbIThxOA
- Thread-topic: [PATCH v3] docs/misra: add R13.2 and R18.2 to rules.rst
Hi Stefano,
> On 1 Aug 2024, at 21:19, Stefano Stabellini <sstabellini@xxxxxxxxxx> wrote:
>
> Add MISRA C rules 13.2 and 18.2 to rules.rst. Both rules have zero
> violations reported by Eclair but they have some cautions. We accept
> both rules and for now we'll enable scanning for them in Eclair but only
> violations will cause the Gitlab CI job to fail (cautions will not.)
>
> Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxx>
Acked-by: Bertrand Marquis <bertrand.marquis@xxxxxxx>
Cheers
Bertrand
> ---
> Changes in v3:
> - improve notes
> Changes in v2:
> - clarify that new code is expected to follow the rule
> ---
> docs/misra/rules.rst | 20 ++++++++++++++++++++
> 1 file changed, 20 insertions(+)
>
> diff --git a/docs/misra/rules.rst b/docs/misra/rules.rst
> index 7b366edb07..e99cb81089 100644
> --- a/docs/misra/rules.rst
> +++ b/docs/misra/rules.rst
> @@ -462,6 +462,16 @@ maintainers if you want to suggest a change.
> - Initializer lists shall not contain persistent side effects
> -
>
> + * - `Rule 13.2
> <https://gitlab.com/MISRA/MISRA-C/MISRA-C-2012/Example-Suite/-/blob/master/R_13_02.c>`_
> + - Required
> + - The value of an expression and its persistent side-effects shall
> + be the same under all permitted evaluation orders
> + - Be aware that the static analysis tool Eclair might report
> + several findings for Rule 13.2 of type "caution". These are
> + instances where Eclair is unable to verify that the code is valid
> + in regard to Rule 13.2. Caution reports might not be violations.
> + The rule should be followed in any case in new code submitted.
> +
> * - `Rule 13.6
> <https://gitlab.com/MISRA/MISRA-C/MISRA-C-2012/Example-Suite/-/blob/master/R_13_06.c>`_
> - Required
> - The operand of the sizeof operator shall not contain any
> @@ -583,6 +593,16 @@ maintainers if you want to suggest a change.
> submitting new patches please try to decrease the number of
> violations when possible.
>
> + * - `Rule 18.2
> <https://gitlab.com/MISRA/MISRA-C/MISRA-C-2012/Example-Suite/-/blob/master/R_18_02.c>`_
> + - Required
> + - Subtraction between pointers shall only be applied to pointers
> + that address elements of the same array
> + - Be aware that the static analysis tool Eclair might report
> + several findings for Rule 18.2 of type "caution". These are
> + instances where Eclair is unable to verify that the code is valid
> + in regard to Rule 18.2. Caution reports might not be violations.
> + The rule should be followed in any case in new code submitted.
> +
> * - `Rule 18.3
> <https://gitlab.com/MISRA/MISRA-C/MISRA-C-2012/Example-Suite/-/blob/master/R_18_03.c>`_
> - Required
> - The relational operators > >= < and <= shall not be applied to objects
> of pointer type except where they point into the same object
> --
> 2.25.1
>
|