diff mbox series

[-next,v2] EDAC: ti: Add missing MODULE_DEVICE_TABLE

Message ID 20210512033727.26701-1-cuibixuan@huawei.com (mailing list archive)
State New, archived
Headers show
Series [-next,v2] EDAC: ti: Add missing MODULE_DEVICE_TABLE | expand

Commit Message

Bixuan Cui May 12, 2021, 3:37 a.m. UTC
The module misses MODULE_DEVICE_TABLE() for of_device_id tables
and thus never autoloads on ID matches.
Add the missing declarations.

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Bixuan Cui <cuibixuan@huawei.com>
---
Changes v2:
* Modify the commit message to make it more suitable.

 drivers/edac/ti_edac.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Borislav Petkov May 14, 2021, 10:22 a.m. UTC | #1
On Wed, May 12, 2021 at 11:37:27AM +0800, Bixuan Cui wrote:
> The module misses MODULE_DEVICE_TABLE() for of_device_id tables
> and thus never autoloads on ID matches.
> Add the missing declarations.
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Bixuan Cui <cuibixuan@huawei.com>
> ---
> Changes v2:
> * Modify the commit message to make it more suitable.
> 
>  drivers/edac/ti_edac.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/edac/ti_edac.c b/drivers/edac/ti_edac.c
> index e7eae20f83d1..169f96e51c29 100644
> --- a/drivers/edac/ti_edac.c
> +++ b/drivers/edac/ti_edac.c
> @@ -197,6 +197,7 @@ static const struct of_device_id ti_edac_of_match[] = {
>  	{ .compatible = "ti,emif-dra7xx", .data = (void *)EMIF_TYPE_DRA7 },
>  	{},
>  };
> +MODULE_DEVICE_TABLE(of, ti_edac_of_match);
>  
>  static int _emif_get_id(struct device_node *node)
>  {
> -- 

Applied, thanks.
diff mbox series

Patch

diff --git a/drivers/edac/ti_edac.c b/drivers/edac/ti_edac.c
index e7eae20f83d1..169f96e51c29 100644
--- a/drivers/edac/ti_edac.c
+++ b/drivers/edac/ti_edac.c
@@ -197,6 +197,7 @@  static const struct of_device_id ti_edac_of_match[] = {
 	{ .compatible = "ti,emif-dra7xx", .data = (void *)EMIF_TYPE_DRA7 },
 	{},
 };
+MODULE_DEVICE_TABLE(of, ti_edac_of_match);
 
 static int _emif_get_id(struct device_node *node)
 {