Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 611e2267 authored by Andy Grover's avatar Andy Grover Committed by Nicholas Bellinger
Browse files

target/user: Fix time calc in expired cmd processing



Reversed arguments meant that we were doing nothing for cmds whose deadline
had passed.

Signed-off-by: default avatarAndy Grover <agrover@redhat.com>
Signed-off-by: default avatarNicholas Bellinger <nab@linux-iscsi.org>
parent 1ec21837
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -638,7 +638,7 @@ static int tcmu_check_expired_cmd(int id, void *p, void *data)
	if (test_bit(TCMU_CMD_BIT_EXPIRED, &cmd->flags))
		return 0;

	if (!time_after(cmd->deadline, jiffies))
	if (!time_after(jiffies, cmd->deadline))
		return 0;

	set_bit(TCMU_CMD_BIT_EXPIRED, &cmd->flags);