Skip to content
Snippets Groups Projects
Commit 7a0a550c authored by Christophe Leroy's avatar Christophe Leroy Committed by Tom Rini
Browse files

powerpc, 8xx: Simplify brgclk calculation and remove get_brgclk()


divider is calculated based on SCCR_DFBRG, with:
SCCR_DFBRG 00 => divider 1  = 1 << 0
SCCR_DFBRG 01 => divider 4  = 1 << 2
SCCR_DFBRG 10 => divider 16 = 1 << 4
SCCR_DFBRG 11 => divider 64 = 1 << 6

This can be easily converted to a single shift operation:
divider = 1 << (SCCR_DFBRG * 2)

Signed-off-by: default avatarChristophe Leroy <christophe.leroy@c-s.fr>
parent b2f2c7be
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment