Skip to content

Commit 470efd6

Browse files
d-tatianinkuba-moo
authored andcommitted
qed/qed_mng_tlv: correctly zero out ->min instead of ->hour
This fixes an issue where ->hour would erroneously get zeroed out instead of ->min because of a bad copy paste. Found by Linux Verification Center (linuxtesting.org) with the SVACE static analysis tool. Fixes: f240b68 ("qed: Add support for processing fcoe tlv request.") Signed-off-by: Daniil Tatianin <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 2499451 commit 470efd6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/qlogic/qed/qed_mng_tlv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,7 @@ qed_mfw_get_tlv_time_value(struct qed_mfw_tlv_time *p_time,
422422
if (p_time->hour > 23)
423423
p_time->hour = 0;
424424
if (p_time->min > 59)
425-
p_time->hour = 0;
425+
p_time->min = 0;
426426
if (p_time->msec > 999)
427427
p_time->msec = 0;
428428
if (p_time->usec > 999)

0 commit comments

Comments
 (0)