Commit 2095b0d8 authored by Colin Ian King's avatar Colin Ian King Committed by Todd Kjos
Browse files

UPSTREAM: iommu/mediatek: Fix unsigned domid comparison with less than zero



Currently the check for domid < 0 is always false because domid
is unsigned. Fix this by casting domid to an int before making
the comparison.

Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Acked-by: default avatarWill Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20210204150001.102672-1-colin.king@canonical.com


Addresses-Coverity: ("Unsigned comparison against 0")
Signed-off-by: default avatarJoerg Roedel <jroedel@suse.de>
(cherry picked from commit 7a566173)

BUG=b:174513569

Signed-off-by: default avatarYong Wu <yong.wu@mediatek.com>
Change-Id: Ic975f030d0ae1409c9ef79bc4d82099fa715e0fd
parent 9e092922
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment