linux-acpi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ACPI / GED: use late init to allow other drivers init
@ 2017-04-21 22:28 Sinan Kaya
  2017-04-21 22:43 ` Rafael J. Wysocki
  2017-04-24 22:49 ` Baicar, Tyler
  0 siblings, 2 replies; 21+ messages in thread
From: Sinan Kaya @ 2017-04-21 22:28 UTC (permalink / raw)
  To: linux-acpi, timur; +Cc: Sinan Kaya, Rafael J. Wysocki, Len Brown, linux-kernel

GED driver is currently set up as a platform driver. On modern operating
systems, most of the drivers are compiled as kernel modules. It is possible
that a GED interrupt event is received and the driver such as GHES/GPIO/I2C
to service it is not available yet. To accommodate this use case, delay
GED driver load to the late init phase.

Signed-off-by: Sinan Kaya <okaya@codeaurora.org>
---
 drivers/acpi/evged.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/drivers/acpi/evged.c b/drivers/acpi/evged.c
index 46f0603..30e638b 100644
--- a/drivers/acpi/evged.c
+++ b/drivers/acpi/evged.c
@@ -151,4 +151,10 @@ static int ged_probe(struct platform_device *pdev)
 		.acpi_match_table = ACPI_PTR(ged_acpi_ids),
 	},
 };
-builtin_platform_driver(ged_driver);
+
+static __init int ged_init(void)
+{
+	return platform_driver_register(&ged_driver);
+}
+
+late_initcall(ged_init);
-- 
1.9.1


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

end of thread, other threads:[~2017-05-21 15:51 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-04-21 22:28 [PATCH] ACPI / GED: use late init to allow other drivers init Sinan Kaya
2017-04-21 22:43 ` Rafael J. Wysocki
2017-04-21 22:48   ` Sinan Kaya
2017-04-21 22:48     ` Sinan Kaya
2017-04-24 23:01     ` Rafael J. Wysocki
2017-04-24 23:33       ` Sinan Kaya
2017-04-25  7:01         ` Lukas Wunner
2017-04-25 16:24           ` Sinan Kaya
2017-04-28  2:32             ` Sinan Kaya
2017-05-11  0:58               ` Rafael J. Wysocki
2017-05-11  1:38                 ` Sinan Kaya
2017-05-11  0:46             ` Rafael J. Wysocki
2017-05-11 13:43               ` Sinan Kaya
2017-05-11 14:52                 ` Rafael J. Wysocki
2017-05-15  2:36                   ` Sinan Kaya
2017-05-15 10:59                     ` Rafael J. Wysocki
2017-05-21 15:51                       ` Sinan Kaya
2017-04-25  1:43       ` Sinan Kaya
2017-04-25 11:03         ` Rafael J. Wysocki
2017-04-25 16:25           ` Sinan Kaya
2017-04-24 22:49 ` Baicar, Tyler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).