mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2026-06-13 15:03:58 +03:00
pci: brcmstb: Fix iBAR size calculation
Fix inbound window size calculation, like Linux commit 25a98c7270156. Signed-off-by: Torsten Duwe <duwe@suse.de> Tested-by: Pedro Falcato <pfalcato@suse.de> Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
This commit is contained in:
committed by
Peter Robinson
parent
b6f853f1cc
commit
df883ec51b
@@ -101,8 +101,8 @@ static int brcm_pcie_encode_ibar_size(u64 size)
|
||||
if (log2_in >= 12 && log2_in <= 15)
|
||||
/* Covers 4KB to 32KB (inclusive) */
|
||||
return (log2_in - 12) + 0x1c;
|
||||
else if (log2_in >= 16 && log2_in <= 37)
|
||||
/* Covers 64KB to 32GB, (inclusive) */
|
||||
else if (log2_in >= 16 && log2_in <= 36)
|
||||
/* Covers 64KB to 64GB, (inclusive) */
|
||||
return log2_in - 15;
|
||||
|
||||
/* Something is awry so disable */
|
||||
|
||||
Reference in New Issue
Block a user