MLK-19989 drivers: mxc: hdp-cec: make the hdp-cec kernel thread freezeable
the hdp-cec kernel thread should be freezeable during system suspend phase, othwerwise, it will cause issues(hang) since it will still try to access some resources such as clocks which are off during system suspend process. Signed-off-by: Jason Liu <jason.hui.liu@nxp.com> Cc: Sandor Yu <sandor.yu@nxp.com> Cc: Laurentiu Palcu <laurentiu.palcu@nxp.com> Acked-by: Sandor Yu <sandor.yu@nxp.com> Reviewed-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>pull/10/head
parent
a858e9c0ed
commit
50acd9fc74
|
@ -22,6 +22,7 @@
|
|||
#include <linux/version.h>
|
||||
#include <linux/workqueue.h>
|
||||
#include <linux/kthread.h>
|
||||
#include <linux/freezer.h>
|
||||
#include <media/cec.h>
|
||||
#include <soc/imx8/soc.h>
|
||||
|
||||
|
@ -173,8 +174,10 @@ static int cec_poll_worker(void *_cec)
|
|||
int num_rx_msgs, i;
|
||||
int sts;
|
||||
|
||||
set_freezable();
|
||||
|
||||
for (;;) {
|
||||
if (kthread_should_stop())
|
||||
if (kthread_freezable_should_stop(NULL))
|
||||
break;
|
||||
|
||||
/* Check TX State */
|
||||
|
|
Loading…
Reference in New Issue