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

Commit 080aadda authored by Colin Ian King's avatar Colin Ian King Committed by David S. Miller
Browse files

fsl/fman_port: remove redundant check on port->rev_info.major



The check port->rev_info.major >= 6 is being performed twice, thus
the inner second check is always true and is redundant, hence it
can be removed. Detected by cppcheck.

drivers/net/ethernet/freescale/fman/fman_port.c:1394]: (warning)
Identical inner 'if' condition is always true.

Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c7d852e3
Loading
Loading
Loading
Loading
+3 −5
Original line number Diff line number Diff line
@@ -1391,13 +1391,11 @@ int fman_port_config(struct fman_port *port, struct fman_port_params *params)
		/* FM_WRONG_RESET_VALUES_ERRATA_FMAN_A005127 Errata
		 * workaround
		 */
		if (port->rev_info.major >= 6) {
		u32 reg;

		reg = 0x00001013;
		iowrite32be(reg, &port->bmi_regs->tx.fmbm_tfp);
	}
	}

	return 0;