[PATCH 2/2] nvmem: sprd: fix module autoloading

From: Krzysztof Kozlowski
Date: Wed Apr 10 2024 - 13:27:05 EST


Add MODULE_DEVICE_TABLE(), so the module could be properly autoloaded
based on the alias from of_device_id table.

Signed-off-by: Krzysztof Kozlowski <krzk@xxxxxxxxxx>
---
drivers/nvmem/sprd-efuse.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/nvmem/sprd-efuse.c b/drivers/nvmem/sprd-efuse.c
index bb3105f3291f..1a7e4e5d8b86 100644
--- a/drivers/nvmem/sprd-efuse.c
+++ b/drivers/nvmem/sprd-efuse.c
@@ -426,6 +426,7 @@ static const struct of_device_id sprd_efuse_of_match[] = {
{ .compatible = "sprd,ums312-efuse", .data = &ums312_data },
{ }
};
+MODULE_DEVICE_TABLE(of, sprd_efuse_of_match);

static struct platform_driver sprd_efuse_driver = {
.probe = sprd_efuse_probe,
--
2.34.1