From: Thorsten Blum Date: Mon, 7 Apr 2025 09:14:42 +0000 (+0200) Subject: rocker: Simplify if condition in ofdpa_port_fdb() X-Git-Tag: v6.16-rc1~132^2~360 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4acdd3de31c878804c6be826cb8c508f18962d0e;p=thirdparty%2Fkernel%2Fstable.git rocker: Simplify if condition in ofdpa_port_fdb() Remove the double negation and simplify the if condition. No functional changes intended. Signed-off-by: Thorsten Blum Reviewed-by: Jiri Pirko Link: https://patch.msgid.link/20250407091442.743478-1-thorsten.blum@linux.dev Signed-off-by: Paolo Abeni --- diff --git a/drivers/net/ethernet/rocker/rocker_ofdpa.c b/drivers/net/ethernet/rocker/rocker_ofdpa.c index 826990459fa44..8832bfdd88330 100644 --- a/drivers/net/ethernet/rocker/rocker_ofdpa.c +++ b/drivers/net/ethernet/rocker/rocker_ofdpa.c @@ -1933,7 +1933,7 @@ static int ofdpa_port_fdb(struct ofdpa_port *ofdpa_port, spin_unlock_irqrestore(&ofdpa->fdb_tbl_lock, lock_flags); /* Check if adding and already exists, or removing and can't find */ - if (!found != !removing) { + if (!found == removing) { kfree(fdb); if (!found && removing) return 0;