public inbox for b.a.t.m.a.n@lists.open-mesh.org
 help / color / mirror / Atom feed
From: Marek Lindner <mareklindner@neomailbox.ch>
To: The list for a Better Approach To Mobile Ad-hoc Networking
	<b.a.t.m.a.n@lists.open-mesh.org>
Subject: Re: [B.A.T.M.A.N.] [PATCHv5 1/2] batman-adv: Add multicast optimization support for bridged setups
Date: Sat, 19 Jul 2014 18:11:50 +0800	[thread overview]
Message-ID: <21319292.8F7hNISJSU@diderot> (raw)
In-Reply-To: <1405391898-5258-1-git-send-email-linus.luessing@web.de>

[-- Attachment #1: Type: text/plain, Size: 1667 bytes --]

On Tuesday 15 July 2014 04:38:17 Linus Lüssing wrote:
>  /**
> + * batadv_mcast_get_bridge - get the bridge on top of the softif if it exists
> + * @soft_iface: netdev struct of the mesh interface
> + *
> + * Returns either a bridge interface on top of our soft interface or
> + * NULL if no such bridge exists.
> + */

The kernel doc should mention that the bridge object's refcount is increased 
(if found).


> +update:
>  	if (!bat_priv->mcast.enabled ||
>  	    mcast_data.flags != bat_priv->mcast.flags) {
> +		if (!bat_priv->mcast.enabled)
> +			sprintf(str_flags_old, "<undefined>");
> +		else
> +			sprintf(str_flags_old, "[%c%c%c]",
> +				(bat_priv->mcast.flags &
> +				 BATADV_MCAST_WANT_ALL_UNSNOOPABLES ?
> +				 'U' : '.'),
> +				(bat_priv->mcast.flags &
> +				 BATADV_MCAST_WANT_ALL_IPV4 ? '4' : '.'),
> +				(bat_priv->mcast.flags &
> +				 BATADV_MCAST_WANT_ALL_IPV6 ? '6' : '.'));
> +
> +		sprintf(str_flags_new, "[%c%c%c]",
> +			(mcast_data.flags &
> +			 BATADV_MCAST_WANT_ALL_UNSNOOPABLES ? 'U' : '.'),
> +			(mcast_data.flags &
> +			 BATADV_MCAST_WANT_ALL_IPV4 ? '4' : '.'),
> +			(mcast_data.flags &
> +			 BATADV_MCAST_WANT_ALL_IPV6 ? '6' : '.'));
> +
> +		batadv_dbg(BATADV_DBG_MCAST, bat_priv,
> +			   "Changing multicast flags from '%s' to '%s'\n",
> +			   str_flags_old, str_flags_new);

IMHO the debug log should be more verbose about why a given flag was enabled or 
disabled. As it is now, one can't learn anything from this log that isn't already
part of the mcast table. If you think that is too big of a change you can also
move this chunk into a separate patch.

Cheers,
Marek

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

      parent reply	other threads:[~2014-07-19 10:11 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-15  2:38 [B.A.T.M.A.N.] [PATCHv5 1/2] batman-adv: Add multicast optimization support for bridged setups Linus Lüssing
2014-07-15  2:38 ` [B.A.T.M.A.N.] [PATCHv5 2/2] batman-adv: Add debugfs table for mcast flags Linus Lüssing
2014-07-19 10:02   ` Marek Lindner
2014-07-21 15:29     ` Linus Lüssing
2014-08-02 19:43     ` Linus Lüssing
2014-07-19 10:11 ` Marek Lindner [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=21319292.8F7hNISJSU@diderot \
    --to=mareklindner@neomailbox.ch \
    --cc=b.a.t.m.a.n@lists.open-mesh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox