public inbox for b.a.t.m.a.n@lists.open-mesh.org
 help / color / mirror / Atom feed
* [B.A.T.M.A.N.] [PATCH] batman-adv: fix tt_global_entries flags update
@ 2012-11-07 14:05 Antonio Quartulli
  2012-11-08 13:06 ` Marek Lindner
  0 siblings, 1 reply; 2+ messages in thread
From: Antonio Quartulli @ 2012-11-07 14:05 UTC (permalink / raw)
  To: b.a.t.m.a.n

Flags carried by a change_entry have to be always copied into the
client entry as they may contain important attributes (e.g.
TT_CLIENT_WIFI).

For instance, a client added by means of the "early detection
mechanism" has no flag set at the beginning, so they must be updated once the
proper ADD event is received.

This was introduced by ("batman-adv: detect not yet announced clients")

Signed-off-by: Antonio Quartulli <ordex@autistici.org>
---

This patch is based on "maint"


 translation-table.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/translation-table.c b/translation-table.c
index 112edd3..64c0012 100644
--- a/translation-table.c
+++ b/translation-table.c
@@ -769,6 +769,12 @@ int batadv_tt_global_add(struct batadv_priv *bat_priv,
 		 */
 		tt_global_entry->common.flags &= ~BATADV_TT_CLIENT_TEMP;
 
+		/* the change can carry possible "attribute" flags like the
+		 * TT_CLIENT_WIFI, therefore they have to be copied in the
+		 * client entry
+		 */
+		tt_global_entry->common.flags |= flags;
+
 		/* If there is the BATADV_TT_CLIENT_ROAM flag set, there is only
 		 * one originator left in the list and we previously received a
 		 * delete + roaming change for this originator.
-- 
1.8.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [B.A.T.M.A.N.] [PATCH] batman-adv: fix tt_global_entries flags update
  2012-11-07 14:05 [B.A.T.M.A.N.] [PATCH] batman-adv: fix tt_global_entries flags update Antonio Quartulli
@ 2012-11-08 13:06 ` Marek Lindner
  0 siblings, 0 replies; 2+ messages in thread
From: Marek Lindner @ 2012-11-08 13:06 UTC (permalink / raw)
  To: b.a.t.m.a.n

On Wednesday, November 07, 2012 22:05:33 Antonio Quartulli wrote:
> Flags carried by a change_entry have to be always copied into the
> client entry as they may contain important attributes (e.g.
> TT_CLIENT_WIFI).
> 
> For instance, a client added by means of the "early detection
> mechanism" has no flag set at the beginning, so they must be updated once
> the proper ADD event is received.
> 
> This was introduced by ("batman-adv: detect not yet announced clients")
> 
> Signed-off-by: Antonio Quartulli <ordex@autistici.org>
> ---
> 
> This patch is based on "maint"
> 
> 
>  translation-table.c | 6 ++++++
>  1 file changed, 6 insertions(+)

Applied in revision fa614fd.

Thanks,
Marek

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-11-08 13:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-11-07 14:05 [B.A.T.M.A.N.] [PATCH] batman-adv: fix tt_global_entries flags update Antonio Quartulli
2012-11-08 13:06 ` Marek Lindner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox