hc
2023-12-11 6778948f9de86c3cfaf36725a7c87dcff9ba247f
kernel/drivers/input/touchscreen/gt1x/gt1x.c
....@@ -656,6 +656,18 @@
656656 }
657657
658658 #if defined(CONFIG_FB)
659
+#include <linux/async.h>
660
+
661
+static void gt1x_resume_async(void *data, async_cookie_t cookie)
662
+{
663
+ gt1x_resume();
664
+}
665
+
666
+static void gt1x_suspend_async(void *data, async_cookie_t cookie)
667
+{
668
+ gt1x_suspend();
669
+}
670
+
659671 /* frame buffer notifier block control the suspend/resume procedure */
660672 static struct notifier_block gt1x_fb_notifier;
661673 static int tp_status;
....@@ -686,7 +698,7 @@
686698 if (*blank == FB_BLANK_UNBLANK) {
687699 tp_status = *blank;
688700 GTP_DEBUG("Resume by fb notifier.");
689
- gt1x_resume();
701
+ async_schedule(gt1x_resume_async, NULL);
690702 }
691703 }
692704 #endif
....@@ -697,7 +709,7 @@
697709 if (*blank == FB_BLANK_POWERDOWN) {
698710 tp_status = *blank;
699711 GTP_DEBUG("Suspend by fb notifier.");
700
- gt1x_suspend();
712
+ async_schedule(gt1x_suspend_async, NULL);
701713 }
702714 }
703715