aspeed/smc: use a modulo to check segment limits
commitb4cc583f0285a2e1e78621dfba142f00ca47414a
authorCédric Le Goater <clg@kaod.org>
Fri, 10 Feb 2017 17:40:30 +0000 (10 17:40 +0000)
committerPeter Maydell <peter.maydell@linaro.org>
Fri, 10 Feb 2017 17:40:30 +0000 (10 17:40 +0000)
tree298e783ef635a9514a758659586c3dbd773c792b
parent1a6d4fc27d75839b6a0325ef258560fded6ec7d9
aspeed/smc: use a modulo to check segment limits

The size of a segment is not necessarily a power of 2.

Signed-off-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-id: 1486648058-520-5-git-send-email-clg@kaod.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
hw/ssi/aspeed_smc.c