On Mon, Sep 11, 2017 at 01:49:05PM -0500, Denis Kenzior wrote:
If Jonas or you want to combine these into a single proper patch, I'll take it up.


Challenge accepted! Combined patch below.

-Clayton



plugins/udevng.c | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/plugins/udevng.c b/plugins/udevng.c
index 518eda8e..a4b99aa4 100644
--- a/plugins/udevng.c
+++ b/plugins/udevng.c
@@ -1013,8 +1013,6 @@ static gboolean setup_isi_serial(struct modem_info* modem)
        if (value)
                ofono_modem_set_integer(modem->modem, "Address", atoi(value));

-       ofono_modem_set_string(modem->modem, "Device", info->devnode);
-
        return TRUE;
}

@@ -1325,7 +1323,7 @@ static void add_serial_device(struct udev_device *dev)

        devnode = udev_device_get_devnode(dev);

-       if (!syspath || !devname || !devpath || !devnode)
+       if (!syspath || !devpath)
                return;

        modem = g_hash_table_lookup(modem_list, syspath);
@@ -1337,7 +1335,7 @@ static void add_serial_device(struct udev_device *dev)
                modem->type = MODEM_TYPE_SERIAL;
                modem->syspath = g_strdup(syspath);
                modem->devname = g_strdup(devname);
-               modem->driver = g_strdup("legacy");
+               modem->driver = g_strdup(driver);

                g_hash_table_replace(modem_list, modem->syspath, modem);
        }
@@ -1357,7 +1355,7 @@ static void add_serial_device(struct udev_device *dev)
        info->subsystem = g_strdup(subsystem);
        info->dev = udev_device_ref(dev);

-       modem->devices = g_slist_append(modem->devices, info);
+       modem->serial = info;
}

static void add_device(const char *syspath, const char *devname,
_______________________________________________
ofono mailing list
ofono@ofono.org
https://lists.ofono.org/mailman/listinfo/ofono

Reply via email to