mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-15 04:43:53 +00:00
powerpc/mpc85xx: Fix localbus child reg property decoding
r302340, as an attempt to fix the localbus child handling post-rman change, actually broke child resource allocation, due to typos in fdt_lbc_reg_decode(). This went unnoticed because there aren't any drivers currently in tree that use localbus.
This commit is contained in:
parent
629667a148
commit
7d7671db00
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=356640
|
@ -391,13 +391,13 @@ fdt_lbc_reg_decode(phandle_t node, struct lbc_softc *sc,
|
|||
|
||||
/* Get address/size. */
|
||||
start = count = 0;
|
||||
for (j = 0; j < addr_cells; j++) {
|
||||
for (j = 0; j < addr_cells - 1; j++) {
|
||||
start <<= 32;
|
||||
start |= reg[j];
|
||||
}
|
||||
for (j = 0; j < size_cells; j++) {
|
||||
count <<= 32;
|
||||
count |= reg[addr_cells + j - 1];
|
||||
count |= reg[addr_cells + j];
|
||||
}
|
||||
reg += addr_cells - 1 + size_cells;
|
||||
|
||||
|
|
Loading…
Reference in a new issue