Hi Patrik,

Sorry for the late response. Thank you for the suggestion. I tested your
patch, it can catch the zero address there but it doesn't continue to
receive any other message. Next following the last part of the debug output
of connman. Before usb1-1: is the output when I removed the USB and after
when I plugged it in.

connmand[2261]: src/rtnl.c:netlink_event() chan 0x555ea2e8
connmand[2261]: src/rtnl.c:netlink_event() Before status 1
connmand[2261]: src/rtnl.c:netlink_event() After status 1
connmand[2261]: src/rtnl.c:rtnl_message() buf 0x7ff31610 len 60
connmand[2261]: src/rtnl.c:rtnl_message() DELROUTE len 60 type 25 flags
0x0000 seq 0
connmand[2261]: plugins/wifi.c:interface_state() wifi (nil) interface state
1
connmand[2261]: plugins/wifi.c:scan_finished()
connmand[2261]: plugins/wifi.c:scan_finished()
connmand[2261]: plugins/wifi.c:network_removed() name Deise
connmand[2261]: plugins/wifi.c:network_removed() name DigisoftWireless-N
connmand[2261]: plugins/wifi.c:network_removed() name fortinet
connmand[2261]: plugins/wifi.c:network_removed() name DIR-300NRU
connmand[2261]: plugins/wifi.c:network_removed() name TP-LINK_RUSSIA
connmand[2261]: plugins/wifi.c:network_removed() name TVTBWireless
connmand[2261]: plugins/wifi.c:network_removed() name TVTBTest
connmand[2261]: plugins/wifi.c:network_removed() name DigiWIFI
connmand[2261]: plugins/wifi.c:interface_removed() ifname ra0
connmand[2261]: Wrong wifi pointer
connmand[2261]: plugins/wifi.c:interface_remove_callback() result 0 wifi
(nil)

i93[~]#
i93[~]#
i93[~]#
i93[~]#
i93[~]# usb 1-1: new high speed USB device using tangox-ehci-hcd-0 and
address 7
usb 1-1: configuration #1 chosen from 1 choice


=== pAd = c1510000, size = 508592 ===

<-- RTMPAllocTxRxRingMemory, Status=0
<-- RTMPAllocAdapterBlock, Status=0
ra0 (usb): not using net_device_ops yet
connmand[2261]: src/rtnl.c:netlink_event() chan 0x555ea2e8
connmand[2261]: src/rtnl.c:netlink_event() Before status 1
connmand[2261]: src/rtnl.c:netlink_event() After status 1
connmand[2261]: src/rtnl.c:rtnl_message() buf 0x7ff31610 len 240
connmand[2261]: src/rtnl.c:rtnl_message() NEWLINK len 240 type 16 flags
0x0000 seq 0
connmand[2261]: src/rtnl.c:rtnl_newlink() hdr 0x7ff31610
connmand[2261]: ra0 {newlink} ignore index 14 address 00:00:00:00:00:00

After the above line it doesn't do anything. I suppose it's waiting to
receive a message from dbus?

Regards,
Stavros

On 25 June 2012 13:25, Patrik Flykt <[email protected]> wrote:

>
>         Hi,
>
> On Wed, 2012-06-20 at 15:42 +0100, Stavros Vagionitis wrote:
> > Instead of removing and creating again the device, now I just change the
> > identification string, from zero to the real one. The change is happening
> > in the same file, src/detect.c and as follows:
>
> I think we can catch a zero address earlier than that, can you try with
> the following patch and see if it works out?
>
>         Patrik
>
>
>
> ---
>  src/rtnl.c |    6 ++++++
>  1 file changed, 6 insertions(+)
>
> diff --git a/src/rtnl.c b/src/rtnl.c
> index a6ff84b..d324385 100644
> --- a/src/rtnl.c
> +++ b/src/rtnl.c
> @@ -427,6 +427,12 @@ static void process_newlink(unsigned short type, int
> index, unsigned flags,
>
>         switch (type) {
>         case ARPHRD_ETHER:
> +               if (memcmp(&address, &compare, ETH_ALEN) == 0) {
> +                       connman_info("%s {newlink} ignore index %d address
> %s",
> +                                       ifname, index, str);
> +                       return;
> +               }
> +               /* fall through */
>         case ARPHRD_LOOPBACK:
>         case ARPHDR_PHONET_PIPE:
>         case ARPHRD_NONE:
> --
> 1.7.10
>
>
>
> _______________________________________________
> connman mailing list
> [email protected]
> http://lists.connman.net/listinfo/connman
>
_______________________________________________
connman mailing list
[email protected]
http://lists.connman.net/listinfo/connman

Reply via email to