summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c
diff options
context:
space:
mode:
authorNeerav Parikh <neerav.parikh@intel.com>2015-02-24 06:58:47 +0000
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2015-03-03 01:07:27 -0800
commit750fcbcf18cabe0f44aba2f0bcfb39a31150fe10 (patch)
treef81980e162d6cccbcd65ce4e87c1735ab3eb6c6b /drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c
parent025b4a545fc4ef99fb44b32842c6bc30d3690a3f (diff)
i40e: Fix issue with removal of apps from DBCNL app table
This patch fixes an issue where the driver is not flushing out the DCBNL app table for applications that are not present in the local DCBX application configuration TLVs. Change-ID: I1f1ee04c81c145071b2ab15657546eb10b81fadb Signed-off-by: Neerav Parikh <neerav.parikh@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c')
-rw-r--r--drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c b/drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c
index 183dcb63ce98..f4070b5d33d6 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c
@@ -269,22 +269,21 @@ static bool i40e_dcbnl_find_app(struct i40e_dcbx_config *cfg,
/**
* i40e_dcbnl_flush_apps - Delete all removed APPs
* @pf: the corresponding pf
+ * @old_cfg: old DCBX configuration data
* @new_cfg: new DCBX configuration data
*
* Find and delete all APPs that are not present in the passed
* DCB configuration
**/
void i40e_dcbnl_flush_apps(struct i40e_pf *pf,
+ struct i40e_dcbx_config *old_cfg,
struct i40e_dcbx_config *new_cfg)
{
struct i40e_dcb_app_priority_table app;
- struct i40e_dcbx_config *dcbxcfg;
- struct i40e_hw *hw = &pf->hw;
int i;
- dcbxcfg = &hw->local_dcbx_config;
- for (i = 0; i < dcbxcfg->numapps; i++) {
- app = dcbxcfg->app[i];
+ for (i = 0; i < old_cfg->numapps; i++) {
+ app = old_cfg->app[i];
/* The APP is not available anymore delete it */
if (!i40e_dcbnl_find_app(new_cfg, &app))
i40e_dcbnl_del_app(pf, &app);