platform/x86: mlx-platform: fix module aliases
PATCH v2 1/1 platform/x86: mlx-platform: fix module aliases
Missing prefix 'pn' in MODULE_ALIAS lines causes that the module is not loaded automatically. The driver should use MODULE_DEVICE_TABLE together with existing mlxplat_dmi_table instead.
Changes:
v2 - conversion to usage of MODULE_DEVICE_TABLE (thanks Bjørn)
--- drivers/platform/x86/mlx-platform.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)
drivers/platform/x86/mlx-platform.c +1 -5
@@ -370,8 +370,4 @@ module_exit(mlxplat_exit);MODULE_AUTHOR ("Vadim Pasternak ([email protected])" );MODULE_DESCRIPTION ("Mellanox platform driver" );MODULE_LICENSE ("Dual BSD/GPL" ); -MODULE_ALIAS ("dmi:*:*Mellanox*:MSN24*:" ); -MODULE_ALIAS ("dmi:*:*Mellanox*:MSN27*:" ); -MODULE_ALIAS ("dmi:*:*Mellanox*:MSB*:" ); -MODULE_ALIAS ("dmi:*:*Mellanox*:MSX*:" ); -MODULE_ALIAS ("dmi:*:*Mellanox*:MSN21*:" ); +MODULE_DEVICE_TABLE (dmi, mlxplat_dmi_table);
Signature · 1 line
2.13.6
Quoted 34 lines
-----Original Message-----
From: Ivan Vecera [mailto:[email protected]]
Sent: Monday, January 22, 2018 12:12 PM
To: [email protected]
Cc: Vadim Pasternak <[email protected]>; Bjørn Mork <[email protected]>
Subject: [PATCH v2] platform/x86: mlx-platform: fix module aliasesMissing prefix 'pn' in
MODULE_ALIASlines causes that the module is not loaded automatically. The driver should useMODULE_DEVICE_TABLEtogether with existingmlxplat_dmi_tableinstead.Changes:
v2 - conversion to usage ofMODULE_DEVICE_TABLE(thanks Bjørn)Fixes 6613d18e9038 ("platform/x86: mlx-platform: Move module from
arch/x86")Cc Vadim Pasternak <[email protected]>Cc Bjørn Mork <[email protected]>Signed-off-by Ivan Vecera <[email protected]>--- drivers/platform/x86/mlx-platform.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)drivers/platform/x86/mlx- renamed from drivers/platform/x86/mlx-platform.c +0
-0
platform.c
index504256c3660d..5a8b475668fb100644drivers/platform/x86/mlx-platform.c +0
-0@@ -370,8 +370,4 @@ module_exit(mlxplat_exit); MODULE_AUTHOR("VadimPasternak ([email protected])");
MODULE_DESCRIPTION("Mellanox platform driver");MODULE_LICENSE("Dual BSD/GPL"); -MODULE_ALIAS("dmi:*:*Mellanox*:MSN24*:");
drivers/platform/x86/mlx-platform.c module_exit(mlxplat_exit); · line 373
Quoted 5 lines
drivers/platform/x86/mlx-platform.c +1
-4-MODULE_ALIAS ("dmi:*:*Mellanox*:MSN27*:" ); -MODULE_ALIAS ("dmi:*:*Mellanox*:MSB*:" ); -MODULE_ALIAS ("dmi:*:*Mellanox*:MSX*:" ); -MODULE_ALIAS ("dmi:*:*Mellanox*:MSN21*:" ); +MODULE_DEVICE_TABLE (dmi, mlxplat_dmi_table);
I am not sure about the location of MODULE_DEVICE_TABLE record. Should it be placed at the end of the module or after mlxplat_dmi_table declaration?
Quoted 2 lines
--
2.13.6
Quoted 5 lines · Vadim Pasternak
Quoted 1 line
+MODULE_DEVICE_TABLE(dmi,
mlxplat_dmi_table);I am not sure about the location of
MODULE_DEVICE_TABLErecord. Should it be placed at the end of the module or aftermlxplat_dmi_tabledeclaration?
Yeah, it would be better.
I dunno if Darren is going to ask for another version or fix this manually when apply.
To be on the safer side, send a v3 with properly attached line as Vadim suggested.
Signature · 2 lines
With Best Regards, Andy Shevchenko
Quoted 8 lines · Andy Shevchenko
Quoted 5 lines · Vadim Pasternak
Quoted 1 line
+MODULE_DEVICE_TABLE(dmi,
mlxplat_dmi_table);I am not sure about the location of
MODULE_DEVICE_TABLErecord. Should it be placed at the end of the module or aftermlxplat_dmi_tabledeclaration?
Quoted 6 lines
Yeah, it would be better.
I dunno if Darren is going to ask for another version or fix this manually when apply.
To be on the safer side, send a v3 with properly attached line as Vadim suggested.
Will do.
Thanks,
I.