All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] soundwire: bus: update Slave status in sdw_clear_slave_status
@ 2021-07-14  3:36 ` Bard Liao
  0 siblings, 0 replies; 4+ messages in thread
From: Bard Liao @ 2021-07-14  3:36 UTC (permalink / raw)
  To: alsa-devel, vkoul
  Cc: vinod.koul, linux-kernel, gregkh, srinivas.kandagatla,
	rander.wang, pierre-louis.bossart, sanyog.r.kale, bard.liao

Call to sdw_update_slave_status() needs to be added to sdw_clear_slave_
status() to ensure Slaves are informed of the new status via update_
status() callback.

This will enable codec drivers to reset their internal states and make
sure the register settings are properly restored on pm_runtime or
system resume

BugLink: https://github.com/thesofproject/linux/issues/2908
BugLink: https://github.com/thesofproject/linux/issues/2637
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
---
 drivers/soundwire/bus.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/soundwire/bus.c b/drivers/soundwire/bus.c
index baa236cb5484..1b115734a8f6 100644
--- a/drivers/soundwire/bus.c
+++ b/drivers/soundwire/bus.c
@@ -1860,6 +1860,7 @@ void sdw_clear_slave_status(struct sdw_bus *bus, u32 request)
 		if (slave->status != SDW_SLAVE_UNATTACHED) {
 			sdw_modify_slave_status(slave, SDW_SLAVE_UNATTACHED);
 			slave->first_interrupt_done = false;
+			sdw_update_slave_status(slave, SDW_SLAVE_UNATTACHED);
 		}
 
 		/* keep track of request, used in pm_runtime resume */
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] soundwire: bus: update Slave status in sdw_clear_slave_status
@ 2021-07-14  3:36 ` Bard Liao
  0 siblings, 0 replies; 4+ messages in thread
From: Bard Liao @ 2021-07-14  3:36 UTC (permalink / raw)
  To: alsa-devel, vkoul
  Cc: vinod.koul, gregkh, pierre-louis.bossart, linux-kernel,
	sanyog.r.kale, rander.wang, bard.liao

Call to sdw_update_slave_status() needs to be added to sdw_clear_slave_
status() to ensure Slaves are informed of the new status via update_
status() callback.

This will enable codec drivers to reset their internal states and make
sure the register settings are properly restored on pm_runtime or
system resume

BugLink: https://github.com/thesofproject/linux/issues/2908
BugLink: https://github.com/thesofproject/linux/issues/2637
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
---
 drivers/soundwire/bus.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/soundwire/bus.c b/drivers/soundwire/bus.c
index baa236cb5484..1b115734a8f6 100644
--- a/drivers/soundwire/bus.c
+++ b/drivers/soundwire/bus.c
@@ -1860,6 +1860,7 @@ void sdw_clear_slave_status(struct sdw_bus *bus, u32 request)
 		if (slave->status != SDW_SLAVE_UNATTACHED) {
 			sdw_modify_slave_status(slave, SDW_SLAVE_UNATTACHED);
 			slave->first_interrupt_done = false;
+			sdw_update_slave_status(slave, SDW_SLAVE_UNATTACHED);
 		}
 
 		/* keep track of request, used in pm_runtime resume */
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] soundwire: bus: update Slave status in sdw_clear_slave_status
  2021-07-14  3:36 ` Bard Liao
@ 2021-07-22 14:25   ` Vinod Koul
  -1 siblings, 0 replies; 4+ messages in thread
From: Vinod Koul @ 2021-07-22 14:25 UTC (permalink / raw)
  To: Bard Liao
  Cc: alsa-devel, linux-kernel, gregkh, srinivas.kandagatla,
	rander.wang, pierre-louis.bossart, sanyog.r.kale, bard.liao

On 14-07-21, 11:36, Bard Liao wrote:
> Call to sdw_update_slave_status() needs to be added to sdw_clear_slave_
> status() to ensure Slaves are informed of the new status via update_
> status() callback.
> 
> This will enable codec drivers to reset their internal states and make
> sure the register settings are properly restored on pm_runtime or
> system resume

Applied, thanks

-- 
~Vinod

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] soundwire: bus: update Slave status in sdw_clear_slave_status
@ 2021-07-22 14:25   ` Vinod Koul
  0 siblings, 0 replies; 4+ messages in thread
From: Vinod Koul @ 2021-07-22 14:25 UTC (permalink / raw)
  To: Bard Liao
  Cc: alsa-devel, gregkh, pierre-louis.bossart, linux-kernel,
	sanyog.r.kale, rander.wang, bard.liao

On 14-07-21, 11:36, Bard Liao wrote:
> Call to sdw_update_slave_status() needs to be added to sdw_clear_slave_
> status() to ensure Slaves are informed of the new status via update_
> status() callback.
> 
> This will enable codec drivers to reset their internal states and make
> sure the register settings are properly restored on pm_runtime or
> system resume

Applied, thanks

-- 
~Vinod

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-07-22 14:26 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-14  3:36 [PATCH] soundwire: bus: update Slave status in sdw_clear_slave_status Bard Liao
2021-07-14  3:36 ` Bard Liao
2021-07-22 14:25 ` Vinod Koul
2021-07-22 14:25   ` Vinod Koul

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.