* [PATCH v2 02/24] Bluetooth: hci_bcm: Add serdev_id_table
[not found] <20180611115240.32606-1-ricardo.ribalda@gmail.com>
@ 2018-06-11 11:52 ` Ricardo Ribalda Delgado
2018-06-11 11:52 ` [PATCH v2 03/24] Bluetooth: hci_ll: " Ricardo Ribalda Delgado
` (4 subsequent siblings)
5 siblings, 0 replies; 10+ messages in thread
From: Ricardo Ribalda Delgado @ 2018-06-11 11:52 UTC (permalink / raw)
To: linux-kernel, linux-serial
Cc: Ricardo Ribalda Delgado, Marcel Holtmann, Johan Hedberg,
Rob Herring, Johan Hovold, linux-bluetooth
Describe which hardware is supported by the current driver.
Cc: Marcel Holtmann <marcel@holtmann.org>
Cc: Johan Hedberg <johan.hedberg@gmail.com>
Cc: Rob Herring <robh@kernel.org>
Cc: Johan Hovold <johan@kernel.org>
Cc: linux-bluetooth@vger.kernel.org
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
drivers/bluetooth/hci_bcm.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/bluetooth/hci_bcm.c b/drivers/bluetooth/hci_bcm.c
index 441f5e1deb11..f4d7846c06b8 100644
--- a/drivers/bluetooth/hci_bcm.c
+++ b/drivers/bluetooth/hci_bcm.c
@@ -1325,6 +1325,11 @@ static const struct of_device_id bcm_bluetooth_of_match[] = {
MODULE_DEVICE_TABLE(of, bcm_bluetooth_of_match);
#endif
+static const struct serdev_device_id bcm_serdev_id[] = {
+ { "bcm43438-bt", },
+ {}
+};
+
static struct serdev_device_driver bcm_serdev_driver = {
.probe = bcm_serdev_probe,
.remove = bcm_serdev_remove,
@@ -1334,6 +1339,7 @@ static struct serdev_device_driver bcm_serdev_driver = {
.acpi_match_table = ACPI_PTR(bcm_acpi_match),
.pm = &bcm_pm_ops,
},
+ .id_table = bcm_serdev_id,
};
int __init bcm_init(void)
--
2.17.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* [PATCH v2 03/24] Bluetooth: hci_ll: Add serdev_id_table
[not found] <20180611115240.32606-1-ricardo.ribalda@gmail.com>
2018-06-11 11:52 ` [PATCH v2 02/24] Bluetooth: hci_bcm: Add serdev_id_table Ricardo Ribalda Delgado
@ 2018-06-11 11:52 ` Ricardo Ribalda Delgado
2018-06-11 11:52 ` [PATCH v2 04/24] Bluetooth: hci_nokia: " Ricardo Ribalda Delgado
` (3 subsequent siblings)
5 siblings, 0 replies; 10+ messages in thread
From: Ricardo Ribalda Delgado @ 2018-06-11 11:52 UTC (permalink / raw)
To: linux-kernel, linux-serial
Cc: Ricardo Ribalda Delgado, Marcel Holtmann, Johan Hedberg,
Rob Herring, Johan Hovold, linux-bluetooth
Describe which hardware is supported by the current driver.
Cc: Marcel Holtmann <marcel@holtmann.org>
Cc: Johan Hedberg <johan.hedberg@gmail.com>
Cc: Rob Herring <robh@kernel.org>
Cc: Johan Hovold <johan@kernel.org>
Cc: linux-bluetooth@vger.kernel.org
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
drivers/bluetooth/hci_ll.c | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/drivers/bluetooth/hci_ll.c b/drivers/bluetooth/hci_ll.c
index 27e414b4e3a2..276fdf677df4 100644
--- a/drivers/bluetooth/hci_ll.c
+++ b/drivers/bluetooth/hci_ll.c
@@ -776,6 +776,23 @@ static const struct of_device_id hci_ti_of_match[] = {
};
MODULE_DEVICE_TABLE(of, hci_ti_of_match);
+static struct serdev_device_id hci_ti_id[] = {
+ { "cc2560", },
+ { "wl1271-st", },
+ { "wl1273-st", },
+ { "wl1281-st", },
+ { "wl1283-st", },
+ { "wl1285-st", },
+ { "wl1801-st", },
+ { "wl1805-st", },
+ { "wl1807-st", },
+ { "wl1831-st", },
+ { "wl1835-st", },
+ { "wl1837-st", },
+ {}
+};
+MODULE_DEVICE_TABLE(serdev, hci_ti_id);
+
static struct serdev_device_driver hci_ti_drv = {
.driver = {
.name = "hci-ti",
@@ -783,6 +800,7 @@ static struct serdev_device_driver hci_ti_drv = {
},
.probe = hci_ti_probe,
.remove = hci_ti_remove,
+ .id_table = hci_ti_id,
};
#else
#define ll_setup NULL
--
2.17.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* [PATCH v2 04/24] Bluetooth: hci_nokia: Add serdev_id_table
[not found] <20180611115240.32606-1-ricardo.ribalda@gmail.com>
2018-06-11 11:52 ` [PATCH v2 02/24] Bluetooth: hci_bcm: Add serdev_id_table Ricardo Ribalda Delgado
2018-06-11 11:52 ` [PATCH v2 03/24] Bluetooth: hci_ll: " Ricardo Ribalda Delgado
@ 2018-06-11 11:52 ` Ricardo Ribalda Delgado
2018-06-11 12:56 ` Marcel Holtmann
2018-06-11 11:52 ` [PATCH v2 11/24] Bluetooth: hci_bcm: MODULE_DEVICE_TABLE(serdev) Ricardo Ribalda Delgado
` (2 subsequent siblings)
5 siblings, 1 reply; 10+ messages in thread
From: Ricardo Ribalda Delgado @ 2018-06-11 11:52 UTC (permalink / raw)
To: linux-kernel, linux-serial
Cc: Ricardo Ribalda Delgado, Marcel Holtmann, Johan Hedberg,
Rob Herring, Johan Hovold, Andy Shevchenko, linux-bluetooth
Describe which hardware is supported by the current driver.
Cc: Marcel Holtmann <marcel@holtmann.org>
Cc: Johan Hedberg <johan.hedberg@gmail.com>
Cc: Rob Herring <robh@kernel.org>
Cc: Johan Hovold <johan@kernel.org>
Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: linux-bluetooth@vger.kernel.org
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
drivers/bluetooth/hci_nokia.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/drivers/bluetooth/hci_nokia.c b/drivers/bluetooth/hci_nokia.c
index 3539fd03f47e..eb3d59894aef 100644
--- a/drivers/bluetooth/hci_nokia.c
+++ b/drivers/bluetooth/hci_nokia.c
@@ -801,6 +801,11 @@ static const struct of_device_id nokia_bluetooth_of_match[] = {
MODULE_DEVICE_TABLE(of, nokia_bluetooth_of_match);
#endif
+static struct serdev_device_id nokia_bluetooth_serdev_id[] = {
+ { "hp4-bluetooth", },
+ {}
+};
+
static struct serdev_device_driver nokia_bluetooth_serdev_driver = {
.probe = nokia_bluetooth_serdev_probe,
.remove = nokia_bluetooth_serdev_remove,
@@ -809,6 +814,7 @@ static struct serdev_device_driver nokia_bluetooth_serdev_driver = {
.pm = &nokia_bluetooth_pm_ops,
.of_match_table = of_match_ptr(nokia_bluetooth_of_match),
},
+ .id_table = nokia_bluetooth_serdev_id,
};
module_serdev_device_driver(nokia_bluetooth_serdev_driver);
--
2.17.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH v2 04/24] Bluetooth: hci_nokia: Add serdev_id_table
2018-06-11 11:52 ` [PATCH v2 04/24] Bluetooth: hci_nokia: " Ricardo Ribalda Delgado
@ 2018-06-11 12:56 ` Marcel Holtmann
2018-06-11 13:04 ` Ricardo Ribalda Delgado
0 siblings, 1 reply; 10+ messages in thread
From: Marcel Holtmann @ 2018-06-11 12:56 UTC (permalink / raw)
To: Ricardo Ribalda Delgado
Cc: LKML, linux-serial, Johan Hedberg, Rob Herring, Johan Hovold,
Andy Shevchenko, linux-bluetooth
Hi Ricardo,
> Describe which hardware is supported by the current driver.
>
> Cc: Marcel Holtmann <marcel@holtmann.org>
> Cc: Johan Hedberg <johan.hedberg@gmail.com>
> Cc: Rob Herring <robh@kernel.org>
> Cc: Johan Hovold <johan@kernel.org>
> Cc: Andy Shevchenko <andy.shevchenko@gmail.com>
> Cc: linux-bluetooth@vger.kernel.org
> Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
> ---
> drivers/bluetooth/hci_nokia.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/bluetooth/hci_nokia.c b/drivers/bluetooth/hci_nokia.c
> index 3539fd03f47e..eb3d59894aef 100644
> --- a/drivers/bluetooth/hci_nokia.c
> +++ b/drivers/bluetooth/hci_nokia.c
> @@ -801,6 +801,11 @@ static const struct of_device_id nokia_bluetooth_of_match[] = {
> MODULE_DEVICE_TABLE(of, nokia_bluetooth_of_match);
> #endif
>
> +static struct serdev_device_id nokia_bluetooth_serdev_id[] = {
> + { "hp4-bluetooth", },
> + {}
> +};
> +
> static struct serdev_device_driver nokia_bluetooth_serdev_driver = {
> .probe = nokia_bluetooth_serdev_probe,
> .remove = nokia_bluetooth_serdev_remove,
> @@ -809,6 +814,7 @@ static struct serdev_device_driver nokia_bluetooth_serdev_driver = {
> .pm = &nokia_bluetooth_pm_ops,
> .of_match_table = of_match_ptr(nokia_bluetooth_of_match),
> },
> + .id_table = nokia_bluetooth_serdev_id,
> };
as I said before, don’t bother with this driver. There is no need for this. Nothing is generic here, it is all specific for each of the 5 devices they shipped. Nokia is not building these kind of devices anymore and if they start changing their mind, then we add a patch for it listening this id.
Regards
Marcel
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH v2 11/24] Bluetooth: hci_bcm: MODULE_DEVICE_TABLE(serdev)
[not found] <20180611115240.32606-1-ricardo.ribalda@gmail.com>
` (2 preceding siblings ...)
2018-06-11 11:52 ` [PATCH v2 04/24] Bluetooth: hci_nokia: " Ricardo Ribalda Delgado
@ 2018-06-11 11:52 ` Ricardo Ribalda Delgado
2018-06-11 12:59 ` Marcel Holtmann
2018-06-11 11:52 ` [PATCH v2 12/24] Bluetooth: hci_ll: MODULE_DEVICE_TABLE(serdev) Ricardo Ribalda Delgado
2018-06-11 11:52 ` [PATCH v2 13/24] Bluetooth: hci_nokia: MODULE_DEVICE_TABLE(serdev) Ricardo Ribalda Delgado
5 siblings, 1 reply; 10+ messages in thread
From: Ricardo Ribalda Delgado @ 2018-06-11 11:52 UTC (permalink / raw)
To: linux-kernel, linux-serial
Cc: Ricardo Ribalda Delgado, Marcel Holtmann, Johan Hedberg,
Rob Herring, Johan Hovold, linux-bluetooth
Export serdev table to the module header, allowing module autoload via
udev/modprobe.
Cc: Marcel Holtmann <marcel@holtmann.org>
Cc: Johan Hedberg <johan.hedberg@gmail.com>
Cc: Rob Herring <robh@kernel.org>
Cc: Johan Hovold <johan@kernel.org>
Cc: linux-bluetooth@vger.kernel.org
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
drivers/bluetooth/hci_bcm.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/bluetooth/hci_bcm.c b/drivers/bluetooth/hci_bcm.c
index f4d7846c06b8..ff0fd3502a90 100644
--- a/drivers/bluetooth/hci_bcm.c
+++ b/drivers/bluetooth/hci_bcm.c
@@ -1327,8 +1327,10 @@ MODULE_DEVICE_TABLE(of, bcm_bluetooth_of_match);
static const struct serdev_device_id bcm_serdev_id[] = {
{ "bcm43438-bt", },
+ { "hci_uart_bcm", },
{}
};
+MODULE_DEVICE_TABLE(serdev, bcm_serdev_id);
static struct serdev_device_driver bcm_serdev_driver = {
.probe = bcm_serdev_probe,
--
2.17.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* Re: [PATCH v2 11/24] Bluetooth: hci_bcm: MODULE_DEVICE_TABLE(serdev)
2018-06-11 11:52 ` [PATCH v2 11/24] Bluetooth: hci_bcm: MODULE_DEVICE_TABLE(serdev) Ricardo Ribalda Delgado
@ 2018-06-11 12:59 ` Marcel Holtmann
2018-06-11 13:31 ` Andy Shevchenko
0 siblings, 1 reply; 10+ messages in thread
From: Marcel Holtmann @ 2018-06-11 12:59 UTC (permalink / raw)
To: Ricardo Ribalda Delgado
Cc: linux-kernel, linux-serial, Johan Hedberg, Rob Herring,
Johan Hovold, linux-bluetooth
Hi Ricardo,
> Export serdev table to the module header, allowing module autoload via
> udev/modprobe.
>
> Cc: Marcel Holtmann <marcel@holtmann.org>
> Cc: Johan Hedberg <johan.hedberg@gmail.com>
> Cc: Rob Herring <robh@kernel.org>
> Cc: Johan Hovold <johan@kernel.org>
> Cc: linux-bluetooth@vger.kernel.org
> Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
> ---
> drivers/bluetooth/hci_bcm.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/bluetooth/hci_bcm.c b/drivers/bluetooth/hci_bcm.c
> index f4d7846c06b8..ff0fd3502a90 100644
> --- a/drivers/bluetooth/hci_bcm.c
> +++ b/drivers/bluetooth/hci_bcm.c
> @@ -1327,8 +1327,10 @@ MODULE_DEVICE_TABLE(of, bcm_bluetooth_of_match);
>
> static const struct serdev_device_id bcm_serdev_id[] = {
> { "bcm43438-bt", },
> + { "hci_uart_bcm", },
> {}
> };
> +MODULE_DEVICE_TABLE(serdev, bcm_serdev_id);
so this one I can see real use of and is a good fix to finally clean up hci_bcm.c and remove platform support for the Edison hardware. However, I would really then first rename hci_uart_bcm into some Edison specific string since this is really just one outlier here. Everything else will have ACPI or DT support.
With that said, I do not understand why we need to duplicate the DT compatible strings in serdev_device_id. They will be enumerated fine via ACPI or DT in the first place. So if we want some new_id support, then wouldn’t an empty serdev_device_id table just be fine?
Regards
Marcel
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [PATCH v2 11/24] Bluetooth: hci_bcm: MODULE_DEVICE_TABLE(serdev)
2018-06-11 12:59 ` Marcel Holtmann
@ 2018-06-11 13:31 ` Andy Shevchenko
0 siblings, 0 replies; 10+ messages in thread
From: Andy Shevchenko @ 2018-06-11 13:31 UTC (permalink / raw)
To: Marcel Holtmann
Cc: Ricardo Ribalda Delgado, Linux Kernel Mailing List,
open list:SERIAL DRIVERS, Johan Hedberg, Rob Herring,
Johan Hovold, linux-bluetooth
On Mon, Jun 11, 2018 at 3:59 PM, Marcel Holtmann <marcel@holtmann.org> wrot=
e:
> Hi Ricardo,
>
>> Export serdev table to the module header, allowing module autoload via
>> udev/modprobe.
>> static const struct serdev_device_id bcm_serdev_id[] =3D {
>> { "bcm43438-bt", },
>> + { "hci_uart_bcm", },
>> {}
>> };
>> +MODULE_DEVICE_TABLE(serdev, bcm_serdev_id);
>
> so this one I can see real use of and is a good fix to finally clean up h=
ci_bcm.c and remove platform support for the Edison hardware. However, I wo=
uld really then first rename hci_uart_bcm into some Edison specific string =
since this is really just one outlier here.
Or other way around, hack
arch/x86/platform/intel-mid/device_libs/platform_bt.c to be compatible
with these changes (Dunno if it's possible).
--=20
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH v2 12/24] Bluetooth: hci_ll: MODULE_DEVICE_TABLE(serdev)
[not found] <20180611115240.32606-1-ricardo.ribalda@gmail.com>
` (3 preceding siblings ...)
2018-06-11 11:52 ` [PATCH v2 11/24] Bluetooth: hci_bcm: MODULE_DEVICE_TABLE(serdev) Ricardo Ribalda Delgado
@ 2018-06-11 11:52 ` Ricardo Ribalda Delgado
2018-06-11 11:52 ` [PATCH v2 13/24] Bluetooth: hci_nokia: MODULE_DEVICE_TABLE(serdev) Ricardo Ribalda Delgado
5 siblings, 0 replies; 10+ messages in thread
From: Ricardo Ribalda Delgado @ 2018-06-11 11:52 UTC (permalink / raw)
To: linux-kernel, linux-serial
Cc: Ricardo Ribalda Delgado, Marcel Holtmann, Johan Hedberg,
Rob Herring, Johan Hovold, linux-bluetooth
Export serdev table to the module header, allowing module autoload via
udev/modprobe.
Cc: Marcel Holtmann <marcel@holtmann.org>
Cc: Johan Hedberg <johan.hedberg@gmail.com>
Cc: Rob Herring <robh@kernel.org>
Cc: Johan Hovold <johan@kernel.org>
Cc: linux-bluetooth@vger.kernel.org
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
drivers/bluetooth/hci_ll.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/bluetooth/hci_ll.c b/drivers/bluetooth/hci_ll.c
index 276fdf677df4..3fbe7045e857 100644
--- a/drivers/bluetooth/hci_ll.c
+++ b/drivers/bluetooth/hci_ll.c
@@ -789,6 +789,7 @@ static struct serdev_device_id hci_ti_id[] = {
{ "wl1831-st", },
{ "wl1835-st", },
{ "wl1837-st", },
+ { "hci-ti", },
{}
};
MODULE_DEVICE_TABLE(serdev, hci_ti_id);
--
2.17.1
^ permalink raw reply related [flat|nested] 10+ messages in thread* [PATCH v2 13/24] Bluetooth: hci_nokia: MODULE_DEVICE_TABLE(serdev)
[not found] <20180611115240.32606-1-ricardo.ribalda@gmail.com>
` (4 preceding siblings ...)
2018-06-11 11:52 ` [PATCH v2 12/24] Bluetooth: hci_ll: MODULE_DEVICE_TABLE(serdev) Ricardo Ribalda Delgado
@ 2018-06-11 11:52 ` Ricardo Ribalda Delgado
5 siblings, 0 replies; 10+ messages in thread
From: Ricardo Ribalda Delgado @ 2018-06-11 11:52 UTC (permalink / raw)
To: linux-kernel, linux-serial
Cc: Ricardo Ribalda Delgado, Marcel Holtmann, Johan Hedberg,
Rob Herring, Johan Hovold, linux-bluetooth
Export serdev table to the module header, allowing module autoload via
udev/modprobe.
Cc: Marcel Holtmann <marcel@holtmann.org>
Cc: Johan Hedberg <johan.hedberg@gmail.com>
Cc: Rob Herring <robh@kernel.org>
Cc: Johan Hovold <johan@kernel.org>
Cc: linux-bluetooth@vger.kernel.org
Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com>
---
drivers/bluetooth/hci_nokia.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/bluetooth/hci_nokia.c b/drivers/bluetooth/hci_nokia.c
index eb3d59894aef..fef285608f10 100644
--- a/drivers/bluetooth/hci_nokia.c
+++ b/drivers/bluetooth/hci_nokia.c
@@ -803,8 +803,10 @@ MODULE_DEVICE_TABLE(of, nokia_bluetooth_of_match);
static struct serdev_device_id nokia_bluetooth_serdev_id[] = {
{ "hp4-bluetooth", },
+ { "nokia-bluetooth", },
{}
};
+MODULE_DEVICE_TABLE(serdev, nokia_bluetooth_serdev_id);
static struct serdev_device_driver nokia_bluetooth_serdev_driver = {
.probe = nokia_bluetooth_serdev_probe,
--
2.17.1
^ permalink raw reply related [flat|nested] 10+ messages in thread