[B.A.T.M.A.N.] [PATCH 4/4] batman-adv: fix removing neigh_ifinfo

Sergei Shtylyov sergei.shtylyov at cogentembedded.com
Sat May 10 22:39:50 CEST 2014


Hello.

On 05/10/2014 07:35 PM, Antonio Quartulli wrote:

> From: Simon Wunderlich <simon at open-mesh.com>

> When an interface is removed separately, all neighbors need to be
> checked if they have a neigh_ifinfo structure for that particular
> interface. If that is the case, remove that ifinfo so any references to
> a hard interface can be freed.

> This is a regression introduced by
> 89652331c00f43574515059ecbf262d26d885717
> ("batman-adv: split tq information in neigh_node struct")

> Reported-by: Antonio Quartulli <antonio at open-mesh.com>
> Signed-off-by: Simon Wunderlich <simon at open-mesh.com>
> Signed-off-by: Marek Lindner <mareklindner at neomailbox.ch>
> Signed-off-by: Antonio Quartulli <antonio at meshcoding.com>
> ---
>   net/batman-adv/originator.c | 46 +++++++++++++++++++++++++++++++++++++++++++++
>   1 file changed, 46 insertions(+)

> diff --git a/net/batman-adv/originator.c b/net/batman-adv/originator.c
> index 8104c3c..427c07d 100644
> --- a/net/batman-adv/originator.c
> +++ b/net/batman-adv/originator.c
> @@ -707,6 +707,47 @@ free_orig_node:
>   }
>
>   /**
> + * batadv_purge_neigh_ifinfo - purge obsolete ifinfo entries from neighbor
> + * @bat_priv: the bat priv with all the soft interface information
> + * @neigh_node: orig node which is to be checked

    The corresponding parameter is called just 'neigh'.

> + */
> +static void
> +batadv_purge_neigh_ifinfo(struct batadv_priv *bat_priv,
> +			  struct batadv_neigh_node *neigh)
[...]

WBR, Sergei



More information about the B.A.T.M.A.N mailing list