Hi Denis,
On 03/05/2016 05:23, Denis Kenzior
wrote:
Hi
Martin,
On 05/02/2016 11:33 AM, Martin Chaplet wrote:
* Add driver's subsystem information
(net, usb, tty, ...)
* Improve interface number extraction by scanning also device
and
parent attributes
Signed-off-by: Martin Chaplet <m.chaplet@kerlink.fr>
No signed-off-by please. See HACKING, 'Submitting Patches'
section.
devpath = udev_device_get_syspath(device);
if (devpath == NULL)
@@ -1037,7 +1040,19 @@ static void add_device(const char
*syspath, const char *devname,
interface = udev_device_get_property_value(intf,
"INTERFACE");
number = udev_device_get_property_value(device,
"ID_USB_INTERFACE_NUM");
+ /* If environment variable is not set, get value from
attributes (or parent's ones) */
+ if(number == NULL)
+ {
Not our style. oFono uses the Linux Kernel coding style, so the
'{' should be on the same line as the if.
+ number =
udev_device_get_sysattr_value(device, "bInterfaceNumber");
+ if(number == NULL)
+ {
as above
OK, sorry for those mistakes and thanks for your review.
I will re-send cleaner patches.
Regards,
Martin