Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 0f4c46d2 authored by Axel Lin's avatar Axel Lin Committed by Mark Brown
Browse files

regulator: Use BUCK_FPWM_[MASK|SHIFT] macros to replace buck_pmap table



Below is the buck_pmap mapping table:

BUCK1:  mask = 1 << 0,  shift = 0
BUCK2:  mask = 1 << 1,  shift = 1
BUCK3:  mask = 1 << 2,  shift = 2
BUCK4:  mask = 1 << 3,  shift = 3

The mask and shift can be easily calculated by:
        mask = 1 << BUCK_ID
        shift = BUCK_ID

This patch defines BUCK_FPWM_MASK and BUCK_FPWM_SHIFT macros to replace
buck_pmap mapping table.

Signed-off-by: default avatarAxel Lin <axel.lin@gmail.com>
Acked-by: default avatarMilo(Woogyom) Kim <milo.kim@ti.com>
Tested-by: default avatarMilo(Woogyom) Kim <milo.kim@ti.com>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent c42ea5cd
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment