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

[xen master] xen/arm: smmuv3: fix violations of MISRA C:2012 Rule 3.1



commit c2ff2ca3a9dd60e1fb7d6c252be5cb1865952fda
Author:     Nicola Vetrini <nicola.vetrini@xxxxxxxxxxx>
AuthorDate: Thu Jun 29 12:06:16 2023 +0200
Commit:     Julien Grall <jgrall@xxxxxxxxxx>
CommitDate: Wed Jul 5 09:56:16 2023 +0100

    xen/arm: smmuv3: fix violations of MISRA C:2012 Rule 3.1
    
    In the file `xen/drivers/passthrough/arm/smmu-v3.c' there are a few 
occurrences
    of nested '//' character sequences inside C-style comment blocks, which 
violate
    Rule 3.1.
    
    The patch aims to resolve those by replacing the nested comments with
    equivalent constructs that do not violate the rule.
    
    Signed-off-by: Nicola Vetrini <nicola.vetrini@xxxxxxxxxxx>
    Acked-by: Rahul Singh <rahul.singh@xxxxxxx>
    Reviewed-by: Luca Fancellu <luca.fancellu@xxxxxxx>
    Reviewed-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>
---
 xen/drivers/passthrough/arm/smmu-v3.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/xen/drivers/passthrough/arm/smmu-v3.c 
b/xen/drivers/passthrough/arm/smmu-v3.c
index 720aa69ff2..cdbb505134 100644
--- a/xen/drivers/passthrough/arm/smmu-v3.c
+++ b/xen/drivers/passthrough/arm/smmu-v3.c
@@ -1047,10 +1047,10 @@ static int arm_smmu_atc_inv_domain(struct 
arm_smmu_domain *smmu_domain,
         * before we read 'nr_ats_masters' in case of a concurrent call to
         * arm_smmu_enable_ats():
         *
-        *      // unmap()                      // arm_smmu_enable_ats()
-        *      TLBI+SYNC                       atomic_inc(&nr_ats_masters);
-        *      smp_mb();                       [...]
-        *      atomic_read(&nr_ats_masters);   pci_enable_ats() // writel()
+        *      --- unmap() ---                 --- arm_smmu_enable_ats() ---
+        *      TLBI+SYNC                       atomic_inc(&nr_ats_masters);
+        *      smp_mb();                       [...]
+        *      atomic_read(&nr_ats_masters);   pci_enable_ats() (see writel())
         *
         * Ensures that we always see the incremented 'nr_ats_masters' count if
         * ATS was enabled at the PCI device before completion of the TLBI.
--
generated by git-patchbot for /home/xen/git/xen.git#master



 


Rackspace

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