i40e: Fix static analysis tool warning
authorDave Ertman <david.m.ertman@intel.com>
Wed, 27 Jul 2016 19:02:34 +0000 (12:02 -0700)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Thu, 18 Aug 2016 18:43:11 +0000 (11:43 -0700)
commit52a08caa0cd5b9b37020c96f2b59ce1160def8fa
treed622bfe575eb75361a5bc3ffc80f1a3eb651f9ef
parent62fe2a865e6ddc92f574bafacf8376613d8c08f2
i40e: Fix static analysis tool warning

This patch fixes a problem where a static analysis tool generates
a warning for "INVARIANT_CONDITION: Expression 'enabled_tc' used
in the condition always yields the same result."

Without this patch, the driver will not pass the static analysis
tool checks without generating warnings.

This patch fixes the problem by eliminating the irrelevant check
and redundant assignment for the value of enabled_tc.

Change-ID: Ia7d44cb050f507df7de333e96369d322e08bf408
Signed-off-by: Dave Ertman <david.m.ertman@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/i40e/i40e_main.c