[prev in list] [next in list] [prev in thread] [next in thread] 

List:       quagga-dev
Subject:    [quagga-dev 10442] Re: [PATCH 1/3] ospfd: make ospf_maxage_lsa_remover actually yield
From:       Joachim Nilsson <troglobit () gmail ! com>
Date:       2013-04-19 14:50:38
Message-ID: 517159BE.9040000 () gmail ! com
[Download RAW message or body]

This patch seems sane, have tested it and run this in production.

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>

On 02/20/2013 12:00 PM, Christian Franke wrote:
> ospf_maxage_lsa_remover whould check whether to yield,
> but run on anyway.
>
> Signed-off-by: Christian Franke <chris@opensourcerouting.org>
> ---
>   ospfd/ospf_lsa.c |    8 +++++++-
>   1 file changed, 7 insertions(+), 1 deletion(-)
>
> diff --git a/ospfd/ospf_lsa.c b/ospfd/ospf_lsa.c
> index dfd1a61..e0e05ab 100644
> --- a/ospfd/ospf_lsa.c
> +++ b/ospfd/ospf_lsa.c
> @@ -2843,6 +2843,9 @@ ospf_maxage_lsa_remover (struct thread *thread)
>   	    continue;
>   	  }
>   
> +        /* There is at least one neighbor from which we still await an ack
> +         * for that LSA, so we are not allowed to remove it from our lsdb yet
> +         * as per RFC 2328 section 14 para 4 a) */
>           if (lsa->retransmit_counter > 0)
>             {
>               reschedule = 1;
> @@ -2851,7 +2854,10 @@ ospf_maxage_lsa_remover (struct thread *thread)
>           
>           /* TODO: maybe convert this function to a work-queue */
>           if (thread_should_yield (thread))
> -          OSPF_TIMER_ON (ospf->t_maxage, ospf_maxage_lsa_remover, 0);
> +          {
> +            OSPF_TIMER_ON (ospf->t_maxage, ospf_maxage_lsa_remover, 0);
> +            return 0;
> +          }
>             
>           /* Remove LSA from the LSDB */
>           if (IS_LSA_SELF (lsa))


_______________________________________________
Quagga-dev mailing list
Quagga-dev@lists.quagga.net
http://lists.quagga.net/mailman/listinfo/quagga-dev
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic