[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20240815090225.756845-1-liuyuntao12@huawei.com>
Date: Thu, 15 Aug 2024 09:02:25 +0000
From: Yuntao Liu <liuyuntao12@...wei.com>
To: <linux-kernel@...r.kernel.org>, <linux-i2c@...r.kernel.org>
CC: <david-b@...bell.net>, <khali@...ux-fr.org>,
<wsa+renesas@...g-engineering.com>, <liuyuntao12@...wei.com>
Subject: [PATCH] i2c: fix module autoloading
Add MODULE_DEVICE_TABLE(), so modules could be properly autoloaded
based on the alias from i2c_device_id table.
Fixes: e9f1373b64388 ("i2c: Add i2c_new_dummy() utility")
Signed-off-by: Yuntao Liu <liuyuntao12@...wei.com>
---
drivers/i2c/i2c-core-base.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/i2c/i2c-core-base.c b/drivers/i2c/i2c-core-base.c
index b63f75e44296..82622ef71b41 100644
--- a/drivers/i2c/i2c-core-base.c
+++ b/drivers/i2c/i2c-core-base.c
@@ -1070,6 +1070,7 @@ static const struct i2c_device_id dummy_id[] = {
{ "smbus_host_notify", },
{ },
};
+MODULE_DEVICE_TABLE(i2c, dummy_id);
static int dummy_probe(struct i2c_client *client)
{
--
2.34.1
Powered by blists - more mailing lists