public inbox for b.a.t.m.a.n@lists.open-mesh.org
 help / color / mirror / Atom feed
From: Sven Eckelmann <sven@narfation.org>
To: b.a.t.m.a.n@lists.open-mesh.org
Subject: Re: [PATCH 2/3] batman-adv: allow broadcast packet type with unicast destination
Date: Sat, 25 May 2019 12:24:38 +0200	[thread overview]
Message-ID: <1643666.5vcEtJMyOp@sven-edge> (raw)
In-Reply-To: <20190514073859.2053-3-linus.luessing@c0d3.blue>

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

On Tuesday, 14 May 2019 09:38:58 CEST Linus Lüssing wrote:
[...]
> +/**
> + * batadv_orig_bcast_tvlv_ogm_handler() - process incoming broadcast tvlv
> + * @bat_priv: the bat priv with all the soft interface information
> + * @orig: the orig_node of the ogm
> + * @flags: flags indicating the tvlv state (see batadv_tvlv_handler_flags)
> + * @tvlv_value: tvlv buffer containing the multicast data
> + * @tvlv_value_len: tvlv buffer length
> + */
> +static void batadv_orig_bcast_tvlv_ogm_handler(struct batadv_priv *bat_priv,
> +                                              struct batadv_orig_node *orig,
> +                                              u8 flags,
> +                                              void *tvlv_value,
> +                                              u16 tvlv_value_len)
> +{
> +       if (flags & BATADV_TVLV_HANDLER_OGM_CIFNOTFND)
> +               clear_bit(BATADV_ORIG_CAPA_HAS_BCAST_URCV, &orig->capabilities);
> +       else
> +               set_bit(BATADV_ORIG_CAPA_HAS_BCAST_URCV, &orig->capabilities);
> +}
> +

Bitops require #include <linux/bitops.h>

>  /**
>   * batadv_originator_init() - Initialize all originator structures
>   * @bat_priv: the bat priv with all the soft interface information
> @@ -215,6 +236,12 @@ int batadv_originator_init(struct batadv_priv *bat_priv)
>         batadv_hash_set_lock_class(bat_priv->orig_hash,
>                                    &batadv_orig_hash_lock_class_key);
>  
> +       batadv_tvlv_container_register(bat_priv, BATADV_TVLV_BCAST, 1, NULL, 0);

BATADV_TVLV_BCAST requires #include <uapi/linux/batadv_packet.h>

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

  parent reply	other threads:[~2019-05-25 10:24 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-14  7:38 [PATCH 0/3] batman-adv: broadcast flooding improvements Linus Lüssing
2019-05-14  7:38 ` [PATCH 1/3] batman-adv: bcast: queue per interface, if needed Linus Lüssing
2019-05-25 10:21   ` Sven Eckelmann
2019-05-14  7:38 ` [PATCH 2/3] batman-adv: allow broadcast packet type with unicast destination Linus Lüssing
2019-05-25 10:02   ` Sven Eckelmann
2019-05-25 10:24   ` Sven Eckelmann [this message]
2019-05-25 10:53   ` Sven Eckelmann
2019-05-14  7:38 ` [PATCH 3/3] batman-adv: forward broadcast packets via unicast transmissions Linus Lüssing
2019-05-25 10:21   ` Sven Eckelmann

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=1643666.5vcEtJMyOp@sven-edge \
    --to=sven@narfation.org \
    --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