]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ARC: Fix ICCM & DCCM runtime size checks
authorEugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Thu, 2 Apr 2020 17:54:28 +0000 (20:54 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 7 Jun 2020 11:16:44 +0000 (13:16 +0200)
commit1b7e8a989cdc08b04ce5f435bdb93f58ca35edc2
tree448389b0fd79a707f32bebcd4e7b39830432f0b4
parent9cf5d5444c78c14bb9f90dd21cef361ee14ba64b
ARC: Fix ICCM & DCCM runtime size checks

[ Upstream commit 43900edf67d7ef3ac8909854d75b8a1fba2d570c ]

As of today the ICCM and DCCM size checks are incorrectly using
mismatched units (KiB checked against bytes). The CONFIG_ARC_DCCM_SZ
and CONFIG_ARC_ICCM_SZ are in KiB, but the size calculated in
runtime and stored in cpu->dccm.sz and cpu->iccm.sz is in bytes.

Fix that.

Reported-by: Paul Greco <pmgreco@us.ibm.com>
Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
arch/arc/kernel/setup.c