Skip to content

Commit 349181b

Browse files
ksornekanguy11
authored andcommitted
iavf: Fix static code analysis warning
Change min() to min_t() to fix static code analysis warning of possible overflow. Signed-off-by: Paul Greenwalt <[email protected]> Signed-off-by: Karen Sornek <[email protected]> Tested-by: Konrad Jankowski <[email protected]> Signed-off-by: Tony Nguyen <[email protected]>
1 parent 4d0dbd9 commit 349181b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/intel/iavf/iavf_txrx.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1766,7 +1766,7 @@ int iavf_napi_poll(struct napi_struct *napi, int budget)
17661766
if (likely(napi_complete_done(napi, work_done)))
17671767
iavf_update_enable_itr(vsi, q_vector);
17681768

1769-
return min(work_done, budget - 1);
1769+
return min_t(int, work_done, budget - 1);
17701770
}
17711771

17721772
/**

0 commit comments

Comments
 (0)