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

Commit cedc9d93 authored by Jishnu Prakash's avatar Jishnu Prakash
Browse files

qcom: fg-memif: correct timeout condition for memory grant



Correct logic to handle timeout when trying for DMA access.

Change-Id: I10e55e542a96b824db9f7b2abd3fef86286eac6b
Signed-off-by: default avatarJishnu Prakash <jprakash@codeaurora.org>
parent 4556ad23
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1110,7 +1110,7 @@ int fg_dma_mem_req(struct fg_dev *chip, bool request)
				break;
			msleep(20);
		}
		if (!retry_count && !(val & MEM_GNT_BIT)) {
		if ((retry_count < 0) && !(val & MEM_GNT_BIT)) {
			pr_err("failed to get memory access\n");
			rc = -ETIMEDOUT;
			goto release_mem;