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

Commit f1f2e60e authored by Nilesh Javali's avatar Nilesh Javali Committed by James Bottomley
Browse files

[SCSI] qla4xxx: Break the loop if the sendtargets list was empty

parent c28eaaca
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -4242,6 +4242,9 @@ void qla4xxx_build_ddb_list(struct scsi_qla_host *ha, int is_reset)

	wtime = jiffies + (HZ * tmo);
	do {
		if (list_empty(&list_st))
			break;

		qla4xxx_remove_failed_ddb(ha, &list_st);
		schedule_timeout_uninterruptible(HZ / 10);
	} while (time_after(wtime, jiffies));