OSDN Git Service

hw/arm/smmuv3: Fix up L1STD_SPAN decoding
authorKunkun Jiang <jiangkunkun@huawei.com>
Tue, 24 Nov 2020 02:37:11 +0000 (10:37 +0800)
committerPeter Maydell <peter.maydell@linaro.org>
Thu, 10 Dec 2020 11:30:44 +0000 (11:30 +0000)
Accroding to the SMMUv3 spec, the SPAN field of Level1 Stream Table
Descriptor is 5 bits([4:0]).

Fixes: 9bde7f0674f(hw/arm/smmuv3: Implement translate callback)
Signed-off-by: Kunkun Jiang <jiangkunkun@huawei.com>
Message-id: 20201124023711.1184-1-jiangkunkun@huawei.com
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Acked-by: Eric Auger <eric.auger@redhat.com>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
hw/arm/smmuv3-internal.h

index fa3c088..b6f7e53 100644 (file)
@@ -633,6 +633,6 @@ static inline uint64_t l1std_l2ptr(STEDesc *desc)
     return hi << 32 | lo;
 }
 
-#define L1STD_SPAN(stm) (extract32((stm)->word[0], 0, 4))
+#define L1STD_SPAN(stm) (extract32((stm)->word[0], 0, 5))
 
 #endif