mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-27 00:51:35 +00:00
ASoC: core: add support to card re-bind using component framework
This patch aims at achieving dynamic behaviour of audio card when the dependent components disappear and reappear. With this patch the card is removed if any of the dependent component is removed and card is added back if the dependent component comes back. All this is done using component framework and matching based on component name. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Reviewed-by: Vinod Koul <vkoul@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
19e023e3be
commit
bb4b894add
2 changed files with 69 additions and 0 deletions
|
@ -17,6 +17,7 @@
|
|||
#include <linux/workqueue.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/component.h>
|
||||
#include <linux/regmap.h>
|
||||
#include <linux/log2.h>
|
||||
#include <sound/core.h>
|
||||
|
@ -1090,6 +1091,12 @@ struct snd_soc_card {
|
|||
|
||||
struct work_struct deferred_resume_work;
|
||||
|
||||
/* component framework related */
|
||||
bool components_added;
|
||||
/* set in machine driver to enable/disable auto re-binding */
|
||||
bool auto_bind;
|
||||
struct component_match *match;
|
||||
|
||||
/* lists of probed devices belonging to this card */
|
||||
struct list_head component_dev_list;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue