Patch "qed: Fix overriding of supported autoneg value." has been added to the 4.9-stable tree
Subsystems (3)
This is a note to let you know that I've just added the patch titled
qed: Fix overriding of supported autoneg value.
to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
qed-fix-overriding-of-supported-autoneg-value.patch
and it can be found in the queue-4.9 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From foo@baz Mon Apr 9 17:09:24 CEST 2018
From: "[email protected]" <[email protected]>
Date: Thu, 4 May 2017 08:15:04 -0700
Subject: qed: Fix overriding of supported autoneg value.
From: "[email protected]" <[email protected]>
[ Upstream commit 34f9199ce7b7e5c641b96e928bd60e086bf7f278 ]
Driver currently uses advertised-autoneg value to populate the supported-autoneg field. When advertised field is updated, user gets the same value for supported field. Supported-autoneg value need to be populated from the link capabilities value returned by the MFW.
--- drivers/net/ethernet/qlogic/qed/qed_dev.c | 3 +++ drivers/net/ethernet/qlogic/qed/qed_main.c | 6 +++++- drivers/net/ethernet/qlogic/qed/qed_mcp.h | 1 + 3 files changed, 9 insertions(+), 1 deletion(-)
drivers/net/ethernet/qlogic/qed/qed_dev.c +3 -0
@@ -1628,6 +1628,9 @@ static int qed_hw_get_nvm_info(struct qeDP_NOTICE (p_hwfn,"Unknown Speed in 0x%08x\n" , link_temp); } + p_hwfn->mcp_info->link_capabilities.default_speed_autoneg = + link->speed.autoneg; + link_temp &=NVM_CFG1_PORT_DRV_FLOW_CONTROL_MASK ; link_temp >>=NVM_CFG1_PORT_DRV_FLOW_CONTROL_OFFSET ; link->pause.autoneg = !!(link_temp &
drivers/net/ethernet/qlogic/qed/qed_main.c +5 -1
@@ -1240,7 +1240,7 @@ static void qed_fill_link(struct qed_hwf/* TODO - at the moment assume supported and advertised speed equal */ if_link->supported_caps =QED_LM_FIBRE_BIT ; -if (params.speed.autoneg) +if (link_caps.default_speed_autoneg) if_link->supported_caps |= QED_LM_Autoneg_BIT;if (params.pause.autoneg || (params.pause.forced_rx && params.pause.forced_tx))
@@ -1250,6 +1250,10 @@ static void qed_fill_link(struct qed_hwf if_link->supported_caps |= QED_LM_Pause_BIT; if_link->advertised_caps = if_link->supported_caps; +if (params.speed.autoneg) + if_link->advertised_caps |= QED_LM_Autoneg_BIT; +else + if_link->advertised_caps &= ~QED_LM_Autoneg_BIT;if (params.speed.advertised_speeds &NVM_CFG1_PORT_DRV_SPEED_CAPABILITY_MASK_1G ) if_link->advertised_caps |= QED_LM_1000baseT_Half_BIT |
drivers/net/ethernet/qlogic/qed/qed_mcp.h +1 -0
@@ -35,6 +35,7 @@ struct qed_mcp_link_params {struct qed_mcp_link_capabilities {u32 speed_capabilities; +bool default_speed_autoneg; };struct qed_mcp_link_state {
Patches currently in stable-queue which might be from [email protected] are
queue-4.9/qed-fix-overriding-of-supported-autoneg-value.patch