From: Sven Eckelmann <sven-KaDOiPu9UxWEi8DpZVb4nw@public.gmane.org>
To: davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org
Cc: netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
b.a.t.m.a.n-ZwoEplunGu2X36UT3dwllkB+6BGkLq7r@public.gmane.org,
Simon Wunderlich
<siwu-MaAgPAbsBIVS8oHt8HbXEIQuADTiUCJX@public.gmane.org>
Subject: [PATCH 07/13] batman-adv: remove unused parameters
Date: Sat, 29 Jan 2011 22:47:34 +0100 [thread overview]
Message-ID: <1296337660-12376-8-git-send-email-sven@narfation.org> (raw)
In-Reply-To: <1296337660-12376-1-git-send-email-sven-KaDOiPu9UxWEi8DpZVb4nw@public.gmane.org>
From: Simon Wunderlich <siwu-MaAgPAbsBIVS8oHt8HbXEIQuADTiUCJX@public.gmane.org>
Some function parameters are obsolete now and can be removed.
Reported-by: Sven Eckelmann <sven-KaDOiPu9UxWEi8DpZVb4nw@public.gmane.org>
Signed-off-by: Simon Wunderlich <siwu-MaAgPAbsBIVS8oHt8HbXEIQuADTiUCJX@public.gmane.org>
Signed-off-by: Sven Eckelmann <sven-KaDOiPu9UxWEi8DpZVb4nw@public.gmane.org>
---
net/batman-adv/originator.c | 2 +-
net/batman-adv/routing.c | 15 ++++++---------
net/batman-adv/routing.h | 3 +--
net/batman-adv/send.c | 4 ++--
4 files changed, 10 insertions(+), 14 deletions(-)
diff --git a/net/batman-adv/originator.c b/net/batman-adv/originator.c
index 6b7fb6b..3c5c889 100644
--- a/net/batman-adv/originator.c
+++ b/net/batman-adv/originator.c
@@ -247,7 +247,7 @@ static bool purge_orig_node(struct bat_priv *bat_priv,
orig_node->hna_buff_len);
/* update bonding candidates, we could have lost
* some candidates. */
- update_bonding_candidates(bat_priv, orig_node);
+ update_bonding_candidates(orig_node);
}
}
diff --git a/net/batman-adv/routing.c b/net/batman-adv/routing.c
index a8cd389..e946dc9 100644
--- a/net/batman-adv/routing.c
+++ b/net/batman-adv/routing.c
@@ -433,8 +433,7 @@ static char count_real_packets(struct ethhdr *ethhdr,
}
/* copy primary address for bonding */
-static void mark_bonding_address(struct bat_priv *bat_priv,
- struct orig_node *orig_node,
+static void mark_bonding_address(struct orig_node *orig_node,
struct orig_node *orig_neigh_node,
struct batman_packet *batman_packet)
@@ -447,8 +446,7 @@ static void mark_bonding_address(struct bat_priv *bat_priv,
}
/* mark possible bond.candidates in the neighbor list */
-void update_bonding_candidates(struct bat_priv *bat_priv,
- struct orig_node *orig_node)
+void update_bonding_candidates(struct orig_node *orig_node)
{
int candidates;
int interference_candidate;
@@ -730,9 +728,8 @@ void receive_bat_packet(struct ethhdr *ethhdr,
update_orig(bat_priv, orig_node, ethhdr, batman_packet,
if_incoming, hna_buff, hna_buff_len, is_duplicate);
- mark_bonding_address(bat_priv, orig_node,
- orig_neigh_node, batman_packet);
- update_bonding_candidates(bat_priv, orig_node);
+ mark_bonding_address(orig_node, orig_neigh_node, batman_packet);
+ update_bonding_candidates(orig_node);
/* is single hop (direct) neighbor */
if (is_single_hop_neigh) {
@@ -866,7 +863,7 @@ static int recv_my_icmp_packet(struct bat_priv *bat_priv,
}
static int recv_icmp_ttl_exceeded(struct bat_priv *bat_priv,
- struct sk_buff *skb, size_t icmp_len)
+ struct sk_buff *skb)
{
struct orig_node *orig_node;
struct icmp_packet *icmp_packet;
@@ -978,7 +975,7 @@ int recv_icmp_packet(struct sk_buff *skb, struct batman_if *recv_if)
/* TTL exceeded */
if (icmp_packet->ttl < 2)
- return recv_icmp_ttl_exceeded(bat_priv, skb, hdr_size);
+ return recv_icmp_ttl_exceeded(bat_priv, skb);
ret = NET_RX_DROP;
diff --git a/net/batman-adv/routing.h b/net/batman-adv/routing.h
index f108f23..725cc38 100644
--- a/net/batman-adv/routing.h
+++ b/net/batman-adv/routing.h
@@ -42,7 +42,6 @@ int recv_vis_packet(struct sk_buff *skb, struct batman_if *recv_if);
int recv_bat_packet(struct sk_buff *skb, struct batman_if *recv_if);
struct neigh_node *find_router(struct bat_priv *bat_priv,
struct orig_node *orig_node, struct batman_if *recv_if);
-void update_bonding_candidates(struct bat_priv *bat_priv,
- struct orig_node *orig_node);
+void update_bonding_candidates(struct orig_node *orig_node);
#endif /* _NET_BATMAN_ADV_ROUTING_H_ */
diff --git a/net/batman-adv/send.c b/net/batman-adv/send.c
index b89b9f7..77f8297 100644
--- a/net/batman-adv/send.c
+++ b/net/batman-adv/send.c
@@ -49,7 +49,7 @@ static unsigned long own_send_time(struct bat_priv *bat_priv)
}
/* when do we schedule a forwarded packet to be sent */
-static unsigned long forward_send_time(struct bat_priv *bat_priv)
+static unsigned long forward_send_time(void)
{
return jiffies + msecs_to_jiffies(random32() % (JITTER/2));
}
@@ -356,7 +356,7 @@ void schedule_forward_packet(struct orig_node *orig_node,
else
batman_packet->flags &= ~DIRECTLINK;
- send_time = forward_send_time(bat_priv);
+ send_time = forward_send_time();
add_bat_packet_to_list(bat_priv,
(unsigned char *)batman_packet,
sizeof(struct batman_packet) + hna_buff_len,
--
1.7.2.3
next prev parent reply other threads:[~2011-01-29 21:47 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-29 21:47 pull request: batman-adv 2011-01-29 Sven Eckelmann
[not found] ` <1296337660-12376-1-git-send-email-sven-KaDOiPu9UxWEi8DpZVb4nw@public.gmane.org>
2011-01-29 21:47 ` [PATCH 01/13] batman-adv: Fix kernel panic when fetching vis data on a vis server Sven Eckelmann
2011-01-29 21:47 ` [PATCH 02/13] batman-adv: Create roughly equal sized fragments Sven Eckelmann
2011-01-29 21:47 ` [PATCH 03/13] batman-adv: Calculate correct size for merged packets Sven Eckelmann
2011-01-29 21:47 ` [PATCH 04/13] batman-adv: Remove vis info on hashing errors Sven Eckelmann
2011-01-29 21:47 ` [PATCH 05/13] batman-adv: Remove vis info element in free_info Sven Eckelmann
2011-01-29 21:47 ` [PATCH 06/13] batman-adv: Make vis info stack traversal threadsafe Sven Eckelmann
2011-01-29 21:47 ` Sven Eckelmann [this message]
2011-01-29 21:47 ` [PATCH 08/13] batman-adv: Remove dangling declaration of hash_remove_element Sven Eckelmann
2011-01-29 21:47 ` [PATCH 09/13] batman-adv: Remove unused definitions Sven Eckelmann
2011-01-29 21:47 ` [PATCH 10/13] batman-adv: Remove declaration of batman_skb_recv Sven Eckelmann
2011-01-29 21:47 ` [PATCH 11/13] batman-adv: Remove unused variables Sven Eckelmann
2011-01-29 21:47 ` [PATCH 12/13] batman-adv: Update copyright years Sven Eckelmann
2011-01-29 21:47 ` [PATCH 13/13] batman-adv: Merge README of v2011.0.0 release Sven Eckelmann
2011-01-30 3:08 ` pull request: batman-adv 2011-01-29 David Miller
[not found] ` <20110129.190815.226768755.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
2011-01-30 9:36 ` Sven Eckelmann
2011-01-30 9:38 ` [PATCH 1/4] batman-adv: Fix kernel panic when fetching vis data on a vis server Sven Eckelmann
2011-01-30 9:38 ` [PATCH 2/4] batman-adv: Remove vis info on hashing errors Sven Eckelmann
2011-01-30 9:38 ` [PATCH 3/4] batman-adv: Remove vis info element in free_info Sven Eckelmann
2011-01-30 9:38 ` [PATCH 4/4] batman-adv: Make vis info stack traversal threadsafe Sven Eckelmann
[not found] ` <201101301036.57928.sven-KaDOiPu9UxWEi8DpZVb4nw@public.gmane.org>
2011-01-30 11:56 ` pull request: batman-adv 2011-01-29 David Miller
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=1296337660-12376-8-git-send-email-sven@narfation.org \
--to=sven-kadoipu9uxwei8dpzvb4nw@public.gmane.org \
--cc=b.a.t.m.a.n-ZwoEplunGu2X36UT3dwllkB+6BGkLq7r@public.gmane.org \
--cc=davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org \
--cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=siwu-MaAgPAbsBIVS8oHt8HbXEIQuADTiUCJX@public.gmane.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;
as well as URLs for NNTP newsgroup(s).