diff options
| author | Rasmus Villemoes <[email protected]> | 2019-10-04 15:32:06 +0200 |
|---|---|---|
| committer | Thierry Reding <[email protected]> | 2020-01-08 13:35:12 +0100 |
| commit | 3c64ed74d619c25c65abb1fcafcb1aff835867d5 (patch) | |
| tree | ae8772eeac8e186dbc916dcfef04a2fae3fc77b1 /scripts/gdb/linux/rbtree.py | |
| parent | 366486e0afaa115ec456db124fc07d824a1c1fb1 (diff) | |
pwm: mxs: Avoid a division in mxs_pwm_apply()
Since the divisor is not a compile-time constant (unless gcc somehow
decided to unroll the loop PERIOD_CDIV_MAX times), this does a
somewhat expensive 32/32 division. Replace that with a right shift.
We still have a 64/32 division just below, but at least in that
case the divisor is compile-time constant.
Signed-off-by: Rasmus Villemoes <[email protected]>
Reviewed-by: Uwe Kleine-König <[email protected]>
Signed-off-by: Thierry Reding <[email protected]>
Diffstat (limited to 'scripts/gdb/linux/rbtree.py')
0 files changed, 0 insertions, 0 deletions