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

Commit f667724b authored by Michael Chan's avatar Michael Chan Committed by David S. Miller
Browse files

bnxt_en: Check status of firmware DCBX agent before setting DCB_CAP_DCBX_HOST.



Otherwise, all the host based DCBX settings from lldpad will fail if the
firmware DCBX agent is running.

Signed-off-by: default avatarMichael Chan <michael.chan@broadcom.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 87fe6032
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -553,8 +553,10 @@ static u8 bnxt_dcbnl_setdcbx(struct net_device *dev, u8 mode)
	if ((mode & DCB_CAP_DCBX_VER_CEE) || !(mode & DCB_CAP_DCBX_VER_IEEE))
		return 1;

	if ((mode & DCB_CAP_DCBX_HOST) && BNXT_VF(bp))
	if (mode & DCB_CAP_DCBX_HOST) {
		if (BNXT_VF(bp) || (bp->flags & BNXT_FLAG_FW_LLDP_AGENT))
			return 1;
	}

	if (mode == bp->dcbx_cap)
		return 0;