mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-10 23:24:38 +00:00
fsl: add register read-back to set_law()
After programming a new LAW, we should read-back the LAWAR register so that we sync the writes. Otherwise, code that attempts to use the new LAW-mapped memory might fail right away. Signed-off-by: Timur Tabi <timur@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
This commit is contained in:
parent
c725908681
commit
74c5dfd81f
1 changed files with 2 additions and 1 deletions
|
@ -58,7 +58,8 @@ void set_law(u8 idx, phys_addr_t addr, enum law_size sz, enum law_trgt_if id)
|
|||
out_be32(lawbar, addr >> 12);
|
||||
out_be32(lawar, LAWAR_EN | ((u32)id << 20) | (u32)sz);
|
||||
|
||||
return ;
|
||||
/* Read back so that we sync the writes */
|
||||
in_be32(lawar);
|
||||
}
|
||||
|
||||
int set_next_law(phys_addr_t addr, enum law_size sz, enum law_trgt_if id)
|
||||
|
|
Loading…
Reference in a new issue