mirror of
https://git.proxmox.com/git/mirror_ubuntu-kernels.git
synced 2025-12-08 07:15:55 +00:00
serial: sh-sci: Simplify multiplication/shift logic
"a * (1 << b)" == "a << b". No change in generated code. Reviewed-by: Ulrich Hecht <uli+renesas@fpond.eu> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Link: https://lore.kernel.org/r/118d62e167f6cf5e98bdf9a738634b4590ea8d09.1645460901.git.geert+renesas@glider.be Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
aab68e959b
commit
81ddb200f6
@ -2293,7 +2293,7 @@ static int sci_scbrr_calc(struct sci_port *s, unsigned int bps,
|
||||
for_each_sr(sr, s) {
|
||||
for (c = 0; c <= 3; c++) {
|
||||
/* integerized formulas from HSCIF documentation */
|
||||
prediv = sr * (1 << (2 * c + 1));
|
||||
prediv = sr << (2 * c + 1);
|
||||
|
||||
/*
|
||||
* We need to calculate:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user