Message ID | 20211018085154.853744-1-luo.penghao@zte.com.cn (mailing list archive) |
---|---|
State | Accepted |
Commit | 1bd297988b75c0768e34e983b2a61a6d3dcda999 |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | [linux-next] e1000e: Remove redundant statement | expand |
On 10/18/2021 1:51 AM, luo penghao wrote: > This assignment statement is meaningless, because the statement > will execute to the tag "set_itr_now". > > The clang_analyzer complains as follows: > > drivers/net/ethernet/intel/e1000e/netdev.c:2552:3 warning: > > Value stored to 'current_itr' is never read. > > Reported-by: Zeal Robot <zealci@zte.com.cn> > Signed-off-by: luo penghao <luo.penghao@zte.com.cn> Reviewed-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Hello: This patch was applied to netdev/net-next.git (master) by David S. Miller <davem@davemloft.net>: On Mon, 18 Oct 2021 08:51:54 +0000 you wrote: > This assignment statement is meaningless, because the statement > will execute to the tag "set_itr_now". > > The clang_analyzer complains as follows: > > drivers/net/ethernet/intel/e1000e/netdev.c:2552:3 warning: > > [...] Here is the summary with links: - [linux-next] e1000e: Remove redundant statement https://git.kernel.org/netdev/net-next/c/1bd297988b75 You are awesome, thank you! -- Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html
diff --git a/drivers/net/ethernet/intel/e1000e/netdev.c b/drivers/net/ethernet/intel/e1000e/netdev.c index ff8672a..21ec716 100644 --- a/drivers/net/ethernet/intel/e1000e/netdev.c +++ b/drivers/net/ethernet/intel/e1000e/netdev.c @@ -2549,7 +2549,6 @@ static void e1000_set_itr(struct e1000_adapter *adapter) /* for non-gigabit speeds, just fix the interrupt rate at 4000 */ if (adapter->link_speed != SPEED_1000) { - current_itr = 0; new_itr = 4000; goto set_itr_now; }
This assignment statement is meaningless, because the statement will execute to the tag "set_itr_now". The clang_analyzer complains as follows: drivers/net/ethernet/intel/e1000e/netdev.c:2552:3 warning: Value stored to 'current_itr' is never read. Reported-by: Zeal Robot <zealci@zte.com.cn> Signed-off-by: luo penghao <luo.penghao@zte.com.cn> --- drivers/net/ethernet/intel/e1000e/netdev.c | 1 - 1 file changed, 1 deletion(-)