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

Commit ab76e019 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: kgsl: Fix spinlock corruption in hfi receiver"

parents 96e9d890 ea65e0e6
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -177,6 +177,7 @@ static void receive_ack_msg(struct gmu_device *gmu, struct hfi_msg_rsp *rsp)
{
	struct kgsl_hfi *hfi = &gmu->hfi;
	struct pending_msg *msg = NULL, *next;
	bool in_queue = false;

	trace_kgsl_hfi_receive(rsp->ret_hdr.id,
		rsp->ret_hdr.size,
@@ -185,11 +186,13 @@ static void receive_ack_msg(struct gmu_device *gmu, struct hfi_msg_rsp *rsp)
	spin_lock(&hfi->msglock);
	list_for_each_entry_safe(msg, next, &hfi->msglist, node) {
		if (msg->msg_id == rsp->ret_hdr.id &&
				msg->seqnum == rsp->ret_hdr.seqnum)
				msg->seqnum == rsp->ret_hdr.seqnum) {
			in_queue = true;
			break;
		}
	}

	if (msg == NULL) {
	if (in_queue == false) {
		spin_unlock(&hfi->msglock);
		dev_err(&gmu->pdev->dev,
				"Cannot find receiver of ack msg with id=%d\n",
+1 −1
Original line number Diff line number Diff line
@@ -115,7 +115,7 @@ enum hfi_f2h_qpri {
	HFI_F2H_QPRI_DEBUG = 40,
};

#define HFI_RSP_TIMEOUT 100 /* msec */
#define HFI_RSP_TIMEOUT 500 /* msec */
#define HFI_H2F_CMD_IRQ_MASK BIT(0)

enum hfi_msg_type {