Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9bea9559 authored by Mohammed Javid's avatar Mohammed Javid
Browse files

net: core: Fix to update the neigh entry correctly



When neigh_probe_enable is enabled, neigh entry is not updated
when the client updates the mac address. Make a change to update
the neigh entry always.

Change-Id: I5bee340435b61e97186b99bc76ea9f1f0f3bf2e2
Acked-by: default avatarChaitanya Pratapa <cpratapa@qti.qualcomm.com>
Signed-off-by: default avatarMohammed Javid <mjavid@codeaurora.org>
parent aa89b686
Loading
Loading
Loading
Loading
+2 −5
Original line number Diff line number Diff line
@@ -1288,17 +1288,14 @@ struct neighbour *neigh_event_ns(struct neigh_table *tbl,
	struct neighbour *neigh = __neigh_lookup(tbl, saddr, dev,
						 lladdr || !dev->addr_len);
	if (neigh) {
		if (neigh_probe_enable) {
			if (!(neigh->nud_state == NUD_REACHABLE)) {
		neigh_update(neigh, lladdr, NUD_STALE,
			     NEIGH_UPDATE_F_OVERRIDE);
		if (neigh_probe_enable) {
			if (!(neigh->nud_state == NUD_REACHABLE)) {
				write_lock(&neigh->lock);
				neigh_probe(neigh);
				neigh_update_notify(neigh);
			}
		} else {
			neigh_update(neigh, lladdr, NUD_STALE,
				     NEIGH_UPDATE_F_OVERRIDE);
		}
	}
	return neigh;