Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 28c8b404 authored by Will Deacon's avatar Will Deacon
Browse files

iommu/arm-smmu: Limit 2-level strtab allocation for small SID sizes



If the StreamIDs in a system can all be resolved by a single level-2
stream table (i.e. SIDSIZE < SPLIT), then we currently get our maths
wrong and allocate the largest strtab we support, thanks to unsigned
overflow in our calculation.

This patch fixes the issue by checking the SIDSIZE explicitly when
calculating the size of our first-level stream table.

Reported-by: default avatarMatt Evans <matt.evans@arm.com>
Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
parent ec11d63c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment