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

[xen master] xen/arm: smmuv3: Fix l1 stream table size in the error message



commit b0cec9d37f264017e83c11177abf2aa96a5260a1
Author:     Zenghui Yu <yuzenghui@xxxxxxxxxx>
AuthorDate: Mon Aug 22 16:19:01 2022 +0100
Commit:     Julien Grall <jgrall@xxxxxxxxxx>
CommitDate: Tue Sep 6 17:42:59 2022 +0100

    xen/arm: smmuv3: Fix l1 stream table size in the error message
    
    Backport Linux commit dc898eb84b25. This is the clean backport without
    any changes.
    
    The actual size of level-1 stream table is l1size. This looks like an
    oversight on commit d2e88e7c081ef ("iommu/arm-smmu: Fix LOG2SIZE setting
    for 2-level stream tables") which forgot to update the @size in error
    message as well.
    
    As memory allocation failure is already bad enough, nothing worse would
    happen. But let's be careful.
    
    Signed-off-by: Zenghui Yu <yuzenghui@xxxxxxxxxx>
    Link: https://lore.kernel.org/r/20200826141758.341-1-yuzenghui@xxxxxxxxxx
    Signed-off-by: Will Deacon <will@xxxxxxxxxx>
    Origin: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 
dc898eb84b25
    Signed-off-by: Rahul Singh <rahul.singh@xxxxxxx>
    Acked-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>
---
 xen/drivers/passthrough/arm/smmu-v3.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/drivers/passthrough/arm/smmu-v3.c 
b/xen/drivers/passthrough/arm/smmu-v3.c
index f2562acc38..340609264d 100644
--- a/xen/drivers/passthrough/arm/smmu-v3.c
+++ b/xen/drivers/passthrough/arm/smmu-v3.c
@@ -2348,7 +2348,7 @@ static int arm_smmu_init_strtab_2lvl(struct 
arm_smmu_device *smmu)
        if (!strtab) {
                dev_err(smmu->dev,
                        "failed to allocate l1 stream table (%u bytes)\n",
-                       size);
+                       l1size);
                return -ENOMEM;
        }
        cfg->strtab = strtab;
--
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®.