From f1b57164305d6342b9f77a4f4482cde492b56983 Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Thu, 3 Feb 2022 12:11:15 +0000 Subject: media: cec: add optional adap_configured callback This new optional callback is called when the adapter is fully configured or fully unconfigured. Some drivers may have to take action when this happens. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- drivers/media/cec/core/cec-adap.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'drivers/media/cec/core/cec-adap.c') diff --git a/drivers/media/cec/core/cec-adap.c b/drivers/media/cec/core/cec-adap.c index 2425cb4c6a9a..e789aec7455c 100644 --- a/drivers/media/cec/core/cec-adap.c +++ b/drivers/media/cec/core/cec-adap.c @@ -1336,6 +1336,7 @@ static void cec_adap_unconfigure(struct cec_adapter *adap) cec_flush(adap); wake_up_interruptible(&adap->kthread_waitq); cec_post_state_event(adap); + call_void_op(adap, adap_configured, false); } /* @@ -1517,6 +1518,7 @@ configured: adap->kthread_config = NULL; complete(&adap->config_completion); mutex_unlock(&adap->lock); + call_void_op(adap, adap_configured, true); return 0; unconfigure: -- cgit