mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2026-06-02 09:46:37 +03:00
ddr: altera: n5x: size_t cannot be less than 0
The function socfpga_get_handoff_size returns an int so make the struct fields used to accept the return value also an int so that testing for less than 0 is then valid. This issue was found by Smatch. Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org>
This commit is contained in:
committed by
Tien Fong Chee
parent
dff25bb4ab
commit
5a13fa7c66
@@ -346,25 +346,25 @@ struct ddr_handoff {
|
||||
phys_addr_t cntlr_base;
|
||||
size_t cntlr_total_length;
|
||||
enum ddr_type cntlr_t;
|
||||
size_t cntlr_handoff_length;
|
||||
int cntlr_handoff_length;
|
||||
|
||||
/* Second controller attributes*/
|
||||
phys_addr_t cntlr2_handoff_base;
|
||||
phys_addr_t cntlr2_base;
|
||||
size_t cntlr2_total_length;
|
||||
enum ddr_type cntlr2_t;
|
||||
size_t cntlr2_handoff_length;
|
||||
int cntlr2_handoff_length;
|
||||
|
||||
/* PHY attributes */
|
||||
phys_addr_t phy_handoff_base;
|
||||
phys_addr_t phy_base;
|
||||
size_t phy_total_length;
|
||||
size_t phy_handoff_length;
|
||||
int phy_handoff_length;
|
||||
|
||||
/* PHY engine attributes */
|
||||
phys_addr_t phy_engine_handoff_base;
|
||||
size_t phy_engine_total_length;
|
||||
size_t phy_engine_handoff_length;
|
||||
int phy_engine_handoff_length;
|
||||
|
||||
/* Calibration attributes */
|
||||
phys_addr_t train_imem_base;
|
||||
|
||||
Reference in New Issue
Block a user