[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [XEN PATCH v2] automation/eclair_analysis: deviate linker symbols for Rule 18.2
- To: Jan Beulich <jbeulich@xxxxxxxx>
- From: Stefano Stabellini <stefano.stabellini@xxxxxxx>
- Date: Mon, 9 Sep 2024 21:46:30 -0700
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=suse.com smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0)
- 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=MNjgoZPRMZJ4FSml+vHTtmNgj3wE+sKqc/D2WYME75U=; b=nlCAWK2xrWZB630X2GkC6vsPscyolUtttJlsEoi92e7SzTiitjWIl/pyNKFNpN22TDyPv7OJOJYXazWvD2WBv8G+7rAhSPXCPecZJJBsqaizlsFGaYmTQRu2880JkpTb/ew03k1XQbah5e5W4vvE1dQJ7d6buntJTAjliTNX75V9LY1oJElnY5gbCTrlxd6PzLwpmU4eIPHlYqDrmH9jouO6vCDdGVmNqoSO6Fb8Nbk2GqFeZqQ7h4d69n0QvhkEsfMD3x8ouyif4NzKJ7+lGcqDOUBs+RWrkoCU81WC11AGRP3hxXUWEMrhyRS1k4QGighj6WFiJmDHiAb43nz5lw==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=LozbYdh7r22sj+E4i3YFgc31uw5/vcmIu5nhr1Aw5rjExn1PvRHCCR27Z8Rc7m8gKwdBjdtWFdfei1bES7+FTEKeDr7JCA0IXIHoemnSfzAUOiUaidizhIB9BJb3OA5vRO03xCo8BSKVafexdJGGjTHUIhJ+YnvwuIdm5eifJBwaVqJxpaJDk82ybxTAYbMJElCe6eR0escqX2H0cnNSZ8CQiR69MSIpx/dTCifiANu9MIeFHdcgseD9VvjNRGRFo9j5ooEImN72jJvGeGOz1P0g68iqizj5EepzU7YUjDZrE7g7kEzpQWdNMG8dj6u97HW/01ky06438owI7EuD0A==
- Cc: Nicola Vetrini <nicola.vetrini@xxxxxxxxxxx>, <sstabellini@xxxxxxxxxx>, <michal.orzel@xxxxxxx>, <xenia.ragiadakou@xxxxxxx>, <ayan.kumar.halder@xxxxxxx>, <consulting@xxxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- Delivery-date: Tue, 10 Sep 2024 04:46:48 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On Mon, 9 Sep 2024, Jan Beulich wrote:
> On 07.09.2024 15:03, Nicola Vetrini wrote:
> > --- a/docs/misra/deviations.rst
> > +++ b/docs/misra/deviations.rst
> > @@ -501,6 +501,16 @@ Deviations related to MISRA C:2012 Rules:
> > - __builtin_memset()
> > - cpumask_check()
> >
> > + * - R18.2
> > + - Subtractions between pointers where at least one of the operand is a
> > + pointer to a symbol defined by the linker are safe.
>
> Imo there should be "deemed" in there, as such subtractions aren't
> necessarily safe. We've merely settled on considering the risk as
> acceptable, iirc.
I can add it on commit
> > + - Tagged as `safe` for ECLAIR.
> > +
> > + * - R18.2
> > + - Subtraction between pointers encapsulated by macro page_to_mfn
> > + are safe.
> > + - Tagged as `safe` for ECLAIR.
>
> This one is a result of using frame_table[], aiui. Alternative approaches
> were discussed before. Did that not lead anywhere, requiring a purely
> textual / configurational deviation?
During the last MISRA discussion we agree that this was an acceptable
approach. What else did you have in mind? In any case, keep in mind that
exploring options is a task in itself and we could use our efforts on
reducing the numbers of violations instead which I think is more useful.
|