[PATCH] coresight: etm4x: add OF module alias for platform driver

Can Peng posted 1 patch 1 week, 4 days ago
drivers/hwtracing/coresight/coresight-etm4x-core.c | 1 +
1 file changed, 1 insertion(+)
[PATCH] coresight: etm4x: add OF module alias for platform driver
Posted by Can Peng 1 week, 4 days ago
The ETM4x platform driver uses etm4_sysreg_match as its OF match table,
but the table is not exported for module alias generation.

Add the MODULE_DEVICE_TABLE(of, ...) entry so modpost can generate OF
module aliases for the sysreg platform-device path when
CORESIGHT_SOURCE_ETM4X is built as a module.

Fixes: 5214b563588e ("coresight: etm4x: Add support for sysreg only devices")
Signed-off-by: Can Peng <pengcan@kylinos.cn>
---
 drivers/hwtracing/coresight/coresight-etm4x-core.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/hwtracing/coresight/coresight-etm4x-core.c b/drivers/hwtracing/coresight/coresight-etm4x-core.c
index 14bb31bd6a0b..634ed9ad9550 100644
--- a/drivers/hwtracing/coresight/coresight-etm4x-core.c
+++ b/drivers/hwtracing/coresight/coresight-etm4x-core.c
@@ -2496,6 +2496,7 @@ static const struct of_device_id etm4_sysreg_match[] = {
 	{ .compatible	= "arm,embedded-trace-extension" },
 	{}
 };
+MODULE_DEVICE_TABLE(of, etm4_sysreg_match);
 
 #ifdef CONFIG_ACPI
 static const struct acpi_device_id etm4x_acpi_ids[] = {
-- 
2.53.0