diff options
author | Sanyog Kale <sanyog.r.kale@intel.com> | 2018-04-26 18:38:28 +0530 |
---|---|---|
committer | Vinod Koul <vkoul@kernel.org> | 2018-05-11 21:47:05 +0530 |
commit | 99b8a5d608a64254f22483f6b67a98f26d3eac8c (patch) | |
tree | 6624e9ebe342abdf42cac6ecca040b4ccf2c15ba /drivers/soundwire/bus.c | |
parent | 79df15b7d37c80aee5dff361841500c79e62b1e0 (diff) | |
download | linux-99b8a5d608a64254f22483f6b67a98f26d3eac8c.tar.bz2 |
soundwire: Add bank switch routine
SoundWire supports two registers banks. So, program the alternate bank
with new configuration and then performs bank switch.
Signed-off-by: Sanyog Kale <sanyog.r.kale@intel.com>
Signed-off-by: Shreyas NC <shreyas.nc@intel.com>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/soundwire/bus.c')
-rw-r--r-- | drivers/soundwire/bus.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/soundwire/bus.c b/drivers/soundwire/bus.c index b8c93f0ac0a0..084bf71b2b87 100644 --- a/drivers/soundwire/bus.c +++ b/drivers/soundwire/bus.c @@ -78,6 +78,13 @@ int sdw_add_bus_master(struct sdw_bus *bus) return ret; } + /* + * Default active bank will be 0 as out of reset the Slaves have + * to start with bank 0 (Table 40 of Spec) + */ + bus->params.curr_bank = SDW_BANK0; + bus->params.next_bank = SDW_BANK1; + return 0; } EXPORT_SYMBOL(sdw_add_bus_master); |