This patch fails checkpatch.pl --strict.
On Sun, Oct 30, 2011 at 09:56:01AM +0100, Antonio Quartulli wrote:
+bool arp_snoop_outgoing_request(struct bat_priv *bat_priv, struct sk_buff *skb) [...]
- arp_neigh_update(bat_priv, ip_src, hw_src);
- n = neigh_lookup(&arp_tbl, &ip_dst, primary_if->soft_iface);
- /* check if it is a valid neigh entry */
- if (n && (n->nud_state & NUD_CONNECTED)) {
skb_new = arp_create(ARPOP_REPLY, ETH_P_ARP, ip_src,
primary_if->soft_iface, ip_dst, hw_src, n->ha,
hw_src);
unicast_send_skb(skb_new, bat_priv);
bat_dbg(DBG_ARP, bat_priv, "ARP request replied locally\n");
This function is hooked up in the tx patch, why do we send the unicast reply to the mesh? Shouldn't it be sent on the soft interface instead? I don't really understand this one ...
- } else
/* Send the request on the DHT */
ret = dht_send_data(bat_priv, skb, ip_dst);
- if (n)
neigh_release(n);
+out:
- if (primary_if)
hardif_free_ref(primary_if);
- return ret;
+}
diff --git a/routing.c b/routing.c index ef24a72..4f2b417 100644 --- a/routing.c +++ b/routing.c @@ -965,6 +966,7 @@ int recv_unicast_packet(struct sk_buff *skb, struct hard_iface *recv_if) /* packet for me */ if (is_my_mac(unicast_packet->dest)) { interface_rx(recv_if->soft_iface, skb, recv_if, hdr_size);
- return NET_RX_SUCCESS; }
This added newline is useless.