From: Stephen Rothwell <sfr@canb•auug.org.au>
To: David Miller <davem@davemloft•net>, netdev@vger•kernel.org
Cc: linux-next@vger•kernel.org, linux-kernel@vger•kernel.org,
Antonio Quartulli <ordex@autistici•org>,
Marek Lindner <lindner_marek@yahoo•de>,
Simon Wunderlich <simon@open-mesh•com>
Subject: linux-next: manual merge of the net-next tree with Linus' tree
Date: Mon, 17 Jun 2013 12:44:41 +1000 [thread overview]
Message-ID: <20130617124441.e2e93d3a9e48952d685afa6b@canb.auug.org.au> (raw)
[-- Attachment #1: Type: text/plain, Size: 2895 bytes --]
Hi all,
Today's linux-next merge of the net-next tree got a conflict in
net/batman-adv/bat_iv_ogm.c between commit 7c24bbbeab41 ("batman-adv:
forward late OGMs from best next hop") from Linus' tree and commit
24a5deeb8a19 ("batman-adv: move ring_buffer helper functions in
bat_iv_ogm") from the net-next tree.
I fixed it up (as specified in your email (thanks) - see below) and can
carry the fix as necessary (no action is required).
--
Cheers,
Stephen Rothwell sfr@canb•auug.org.au
diff --cc net/batman-adv/bat_iv_ogm.c
index f680ee1,d07323b..0000000
--- a/net/batman-adv/bat_iv_ogm.c
+++ b/net/batman-adv/bat_iv_ogm.c
@@@ -30,20 -29,47 +29,63 @@@
#include "network-coding.h"
/**
+ * batadv_dup_status - duplicate status
+ * @BATADV_NO_DUP: the packet is a duplicate
+ * @BATADV_ORIG_DUP: OGM is a duplicate in the originator (but not for the
+ * neighbor)
+ * @BATADV_NEIGH_DUP: OGM is a duplicate for the neighbor
+ * @BATADV_PROTECTED: originator is currently protected (after reboot)
+ */
+enum batadv_dup_status {
+ BATADV_NO_DUP = 0,
+ BATADV_ORIG_DUP,
+ BATADV_NEIGH_DUP,
+ BATADV_PROTECTED,
+};
+
++/**
+ * batadv_ring_buffer_set - update the ring buffer with the given value
+ * @lq_recv: pointer to the ring buffer
+ * @lq_index: index to store the value at
+ * @value: value to store in the ring buffer
+ */
+ static void batadv_ring_buffer_set(uint8_t lq_recv[], uint8_t *lq_index,
+ uint8_t value)
+ {
+ lq_recv[*lq_index] = value;
+ *lq_index = (*lq_index + 1) % BATADV_TQ_GLOBAL_WINDOW_SIZE;
+ }
+
+ /**
+ * batadv_ring_buffer_set - compute the average of all non-zero values stored
+ * in the given ring buffer
+ * @lq_recv: pointer to the ring buffer
+ *
+ * Returns computed average value.
+ */
+ static uint8_t batadv_ring_buffer_avg(const uint8_t lq_recv[])
+ {
+ const uint8_t *ptr;
+ uint16_t count = 0, i = 0, sum = 0;
+
+ ptr = lq_recv;
+
+ while (i < BATADV_TQ_GLOBAL_WINDOW_SIZE) {
+ if (*ptr != 0) {
+ count++;
+ sum += *ptr;
+ }
+
+ i++;
+ ptr++;
+ }
+
+ if (count == 0)
+ return 0;
+
+ return (uint8_t)(sum / count);
+ }
++
static struct batadv_neigh_node *
batadv_iv_ogm_neigh_new(struct batadv_hard_iface *hard_iface,
const uint8_t *neigh_addr,
@@@ -1013,11 -1062,10 +1085,11 @@@ static void batadv_iv_ogm_process(cons
struct batadv_neigh_node *orig_neigh_router = NULL;
int has_directlink_flag;
int is_my_addr = 0, is_my_orig = 0, is_my_oldorig = 0;
- int is_broadcast = 0, is_bidirect;
+ int is_bidirect;
bool is_single_hop_neigh = false;
bool is_from_best_next_hop = false;
- int is_duplicate, sameseq, simlar_ttl;
+ int sameseq, similar_ttl;
+ enum batadv_dup_status dup_status;
uint32_t if_incoming_seqno;
uint8_t *prev_sender;
[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]
next reply other threads:[~2013-06-17 2:44 UTC|newest]
Thread overview: 83+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-17 2:44 Stephen Rothwell [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-10-18 1:00 linux-next: manual merge of the net-next tree with Linus' tree Stephen Rothwell
2023-12-14 23:52 Stephen Rothwell
2023-02-16 23:40 Stephen Rothwell
2023-02-16 23:18 Stephen Rothwell
2022-10-27 23:28 Stephen Rothwell
2022-10-28 6:53 ` Marc Kleine-Budde
2022-09-21 1:00 Stephen Rothwell
2022-09-21 4:40 ` Colin Foster
2022-07-15 2:01 Stephen Rothwell
2022-07-15 1:48 Stephen Rothwell
2021-07-23 2:32 Stephen Rothwell
2021-01-29 0:59 Stephen Rothwell
2021-01-29 0:48 Stephen Rothwell
2021-01-29 0:43 Stephen Rothwell
2019-10-21 0:07 Stephen Rothwell
2019-09-15 20:31 Mark Brown
2019-09-15 20:24 Mark Brown
2019-06-17 1:44 Stephen Rothwell
2019-06-04 0:30 Stephen Rothwell
2019-06-04 0:29 Stephen Rothwell
2019-04-02 22:56 Stephen Rothwell
2018-07-20 1:49 Stephen Rothwell
2018-06-06 4:37 Stephen Rothwell
2017-12-04 22:59 Stephen Rothwell
2017-11-09 23:31 Stephen Rothwell
2017-11-10 4:37 ` Cong Wang
2017-11-10 4:39 ` David Miller
2017-10-30 17:24 Mark Brown
2017-10-30 17:08 Mark Brown
2017-10-30 17:02 Mark Brown
2017-10-30 17:43 ` Jakub Kicinski
2017-10-30 18:10 ` Mark Brown
2017-06-30 0:57 Stephen Rothwell
2017-05-03 1:07 Stephen Rothwell
2017-05-03 4:08 ` David Miller
2017-03-24 0:05 Stephen Rothwell
2017-03-24 0:10 ` David Miller
2017-03-24 1:24 ` Alexei Starovoitov
2017-02-02 1:49 Stephen Rothwell
2017-02-02 8:40 ` Yotam Gigi
2016-10-02 22:37 Stephen Rothwell
2016-10-02 22:32 Stephen Rothwell
2016-06-30 1:01 Stephen Rothwell
2016-05-03 3:15 Stephen Rothwell
2016-03-15 0:07 Stephen Rothwell
2016-03-15 8:53 ` Gregory CLEMENT
2015-07-14 1:46 Stephen Rothwell
2015-07-14 8:23 ` Nikolay Aleksandrov
2015-05-28 4:17 Stephen Rothwell
2015-05-28 13:34 ` Tom Lendacky
2015-02-12 1:05 Stephen Rothwell
2014-06-12 2:01 Stephen Rothwell
2014-06-05 3:13 Stephen Rothwell
2014-06-05 3:26 ` KY Srinivasan
2013-12-18 1:46 Stephen Rothwell
2013-12-18 1:56 ` Jeff Kirsher
2013-12-18 2:19 ` Stephen Rothwell
2013-09-05 5:23 Stephen Rothwell
2013-09-05 5:19 Stephen Rothwell
2013-09-05 7:33 ` Daniel Borkmann
2013-09-02 3:12 Stephen Rothwell
2013-06-17 2:38 Stephen Rothwell
2013-04-22 3:09 Stephen Rothwell
2013-04-23 0:42 ` David Miller
2013-04-22 3:03 Stephen Rothwell
2013-04-23 0:41 ` David Miller
2013-04-22 2:48 Stephen Rothwell
2013-04-22 2:43 Stephen Rothwell
2013-04-23 0:41 ` David Miller
2013-03-27 0:57 Stephen Rothwell
2013-03-27 4:54 ` David Miller
2013-03-12 0:33 Stephen Rothwell
2013-03-12 10:49 ` David Miller
2012-11-08 23:53 Stephen Rothwell
2012-11-10 23:34 ` David Miller
2012-10-02 1:51 Stephen Rothwell
2012-09-26 1:46 Stephen Rothwell
2012-07-19 1:15 Stephen Rothwell
2012-07-19 1:18 ` Jeff Kirsher
2012-02-27 1:11 Stephen Rothwell
2012-02-27 4:05 ` David Miller
2012-02-29 3:21 ` Ben Hutchings
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=20130617124441.e2e93d3a9e48952d685afa6b@canb.auug.org.au \
--to=sfr@canb$(echo .)auug.org.au \
--cc=davem@davemloft$(echo .)net \
--cc=lindner_marek@yahoo$(echo .)de \
--cc=linux-kernel@vger$(echo .)kernel.org \
--cc=linux-next@vger$(echo .)kernel.org \
--cc=netdev@vger$(echo .)kernel.org \
--cc=ordex@autistici$(echo .)org \
--cc=simon@open-mesh$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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