[Olsr-dev] process unspec. link quality information

Hannes Gredler (spam-protected)
Tue Apr 14 08:54:37 CEST 2009


have you reach consensus what to do ?
shall we pick up peters patch ?

Peter Tarjan wrote:
> Hello,
> 
> 2009/4/2 Henning Rogge <(spam-protected) 
> <mailto:(spam-protected)>>
> 
>     On Dienstag 31 März 2009 16:43:44 Peter Tarjan wrote:
> 
>  
> 
>      > --- a/src/process_package.c    2009-03-31 16:12:14.215112467 +0200
>      > +++ b/src/process_package.c    2009-03-31 16:13:05.643112066 +0200
>      > @@ -424,7 +424,9 @@
>      >
>      >      /* find the input interface in the list of neighbor
>     interfaces */
>      >      for (walker = message->neighbors; walker != NULL; walker =
>      > walker->next)
>      > -      if (ipequal(&walker->address, &in_if->ip_addr))
>      > +      if (ipequal(&walker->address, &in_if->ip_addr)  &&
>      > +            walker->link != UNSPEC_LINK)
>      > +
>      >          break;
>      >
>      >      // memorize our neighbour's idea of the link quality, so that we
> 
>     Hmm... I'm not sure about this patch... shouldn't we set the LQ
>     value to zero
>     for an unspecified link at another place ?
> 
>     With your patch we might just ignore the value measured by the
>     UNSPEC-link
>     (correct) and keep the old LQ value !
> 
> 
> I decided to ignore the link quality information, because UNSPEC_LINK 
> type message is created by the following in lq_packet.c file:
> ---------------------------------------------------------------------------------------------------------
> static void
> create_lq_hello(struct lq_hello_message *lq_hello, struct interface *outif)
> ...
>   OLSR_FOR_ALL_LINK_ENTRIES(walker) {
> 
>     // allocate a neighbour entry
>     struct lq_hello_neighbor *neigh = 
> olsr_malloc_lq_hello_neighbor("Build LQ_HELLO");
> 
>     // a) this neighbor interface IS NOT visible via the output interface
>     if (!ipequal(&walker->local_iface_addr, &outif->ip_addr))
>       neigh->link_type = UNSPEC_LINK;
> ---------------------------------------------------------------------------------------------------------
> I wondered when I looked into the code, why this information was even 
> included in a HELLO packet.
> 
> In my network scenario B sends HELLO packets from both interfaces. Every 
> HELLO packet lists all the links regardless which interface it is 
> broadcast on.
> When these packets are processed, A is considering the first information 
> that can be found in the packet about the LQ information of the link 
> directed to it. So if there is an UNSPEC link first and later a 
> SYM_NEIGH to A, UNSPEC link information is considered.
> 
> --
> Péter Tarján
> 





More information about the Olsr-dev mailing list