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

Commit f6dcf561 authored by Veaceslav Falico's avatar Veaceslav Falico Committed by David S. Miller
Browse files

bonding: remove NULL verification from bond_get_bond_by_slave()



Every caller relies on the result being the actual bond, so this
verification just masks the real problem.

CC: Jay Vosburgh <j.vosburgh@gmail.com>
CC: Andy Gospodarek <andy@greyhouse.net>
Signed-off-by: default avatarVeaceslav Falico <vfalico@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent dc73c41f
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -249,8 +249,6 @@ static inline struct slave *bond_get_slave_by_dev(struct bonding *bond,

static inline struct bonding *bond_get_bond_by_slave(struct slave *slave)
{
	if (!slave || !slave->bond)
		return NULL;
	return slave->bond;
}