From: Javier Martinez Canillas Date: Mon, 2 Jan 2017 13:09:56 +0000 (-0300) Subject: Bluetooth: btqcomsmd: Fix module autoload X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=747d3f1a8a2fc4d8447c63205421a6a67f22799b;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git Bluetooth: btqcomsmd: Fix module autoload If the driver is built as a module, autoload won't work because the module alias information is not filled. So user-space can't match the registered device with the corresponding module. Export the module alias information using the MODULE_DEVICE_TABLE() macro. Before this patch: $ modinfo drivers/bluetooth/btqcomsmd.ko | grep alias $ After this patch: $ modinfo drivers/bluetooth/btqcomsmd.ko | grep alias alias: of:N*T*Cqcom,wcnss-btC* alias: of:N*T*Cqcom,wcnss-bt Signed-off-by: Javier Martinez Canillas Signed-off-by: Marcel Holtmann --- diff --git a/drivers/bluetooth/btqcomsmd.c b/drivers/bluetooth/btqcomsmd.c index 08c2c93887c1..8d4868af9bbd 100644 --- a/drivers/bluetooth/btqcomsmd.c +++ b/drivers/bluetooth/btqcomsmd.c @@ -165,6 +165,7 @@ static const struct of_device_id btqcomsmd_of_match[] = { { .compatible = "qcom,wcnss-bt", }, { }, }; +MODULE_DEVICE_TABLE(of, btqcomsmd_of_match); static struct platform_driver btqcomsmd_driver = { .probe = btqcomsmd_probe,