Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp1507116ybk; Thu, 21 May 2020 08:29:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwkPpX+d0XMjtcoZDReVdR/uo+hJH6VNgKsHx6imkS83LQKv7Upf2XFkLDLmdx1Wg2rSNpz X-Received: by 2002:a17:906:1917:: with SMTP id a23mr3932566eje.506.1590074945055; Thu, 21 May 2020 08:29:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590074945; cv=none; d=google.com; s=arc-20160816; b=XgWirjKBnWnGFLRVicTAHpOJShIJdlcbTOL+kOkgTMi+jORhzY92Ws7F5xScUTDHY5 qfU3IzclCLE35m40ki6EmW5Nuqm53ltMYYGKdKSIZlocAuxjcbU90o8tvcon+oSJc6iG fBvCRWgTZDzTtsadVjMrMaDaSsYpqh/qviPtsG2Ppg7X18MBOVTdrz9nB2bewYWqSn17 CYyhjcvBjVfbUPsatSmxK1RNADeQloSBIQz2kOfLVZLIqUtKNGqGD9xN36RrH9D4Bviv GPXK1OLX3q4M4roRgB1WuKMTDHbzncXXWnXXMj+ZVmXNvNe0fxNXM3iSAfw5auXmGXQD ZTSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=DIBI7ti1+0GUN01/wZN+suGho3XLG3fn1H7FdDc+e6w=; b=Ziq+/KafrbeczT9Eg/HnmXbmfs6Tj/jxE+xEvIxCBxqARcDn6v35MpO3Ck8kDlsLxY HHuZsGT9drhsL3+oO5vIjj/7yiUu9Dy8EwH9effcu+q7/8ra7WsT6kk3XMaAy4jrviE5 zBIPD4z63N3q4wX1JsyFggSn4hI/VEsjZYoggkiVRRuze+zT4xZQOBhddghlClcA0QaO rX5S7Tp5ooN6f59j8EPmIPZUB6G1KW0TSk42qtouMpcaB/n+thLuufXpqRrseHwTajWH pbzMLtHnm70kSr8vF+o0bKhYMZ8RB/4XhGNNkI5QepFUyStrriaLdYE8/JuObDetJJYT yFMQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=rXU8ggtF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f25si3515637ejr.239.2020.05.21.08.28.41; Thu, 21 May 2020 08:29:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=rXU8ggtF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730451AbgEUP0I (ORCPT + 99 others); Thu, 21 May 2020 11:26:08 -0400 Received: from mail.kernel.org ([198.145.29.99]:34156 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730446AbgEUP0F (ORCPT ); Thu, 21 May 2020 11:26:05 -0400 Received: from localhost.localdomain (unknown [157.51.235.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DAEEC20826; Thu, 21 May 2020 15:26:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1590074765; bh=l53+POgG2ztf6peq2FqUJ2xZb2zARBP2r6LUsVpLW9Q=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=rXU8ggtFUsbATpeNUwiRNtRiVd8DHoEB/GJcqIYTHyv8gP3v18u7I/59LWhGjMm3m EOoF/YIp0RaHiqJRkwymxZICADUwHPkr6gazZ50531iUvWu8ktFG6m2kvYFrRB9oGo N2+uEgF70khSokzs2Zko/+653WJDssgdIgOoaTWs= From: mani@kernel.org To: gregkh@linuxfoundation.org Cc: hemantk@codeaurora.org, jhugo@codeaurora.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Bhaumik Bhatt , Manivannan Sadhasivam Subject: [PATCH 02/14] bus: mhi: core: Cache intmod from mhi event to mhi channel Date: Thu, 21 May 2020 20:55:28 +0530 Message-Id: <20200521152540.17335-3-mani@kernel.org> X-Mailer: git-send-email 2.26.GIT In-Reply-To: <20200521152540.17335-1-mani@kernel.org> References: <20200521152540.17335-1-mani@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Hemant Kumar Driver is using zero initialized intmod value from mhi channel when configuring TRE for bei field. This prevents interrupt moderation to take effect in case it is supported by an event ring. Fix this by copying intmod value from associated event ring to mhi channel upon registering mhi controller. Signed-off-by: Hemant Kumar Signed-off-by: Bhaumik Bhatt Reviewed-by: Jeffrey Hugo Reviewed-by: Manivannan Sadhasivam Signed-off-by: Manivannan Sadhasivam --- drivers/bus/mhi/core/init.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/bus/mhi/core/init.c b/drivers/bus/mhi/core/init.c index eb2ab058a01d..1a93d24efffc 100644 --- a/drivers/bus/mhi/core/init.c +++ b/drivers/bus/mhi/core/init.c @@ -863,6 +863,10 @@ int mhi_register_controller(struct mhi_controller *mhi_cntrl, mutex_init(&mhi_chan->mutex); init_completion(&mhi_chan->completion); rwlock_init(&mhi_chan->lock); + + /* used in setting bei field of TRE */ + mhi_event = &mhi_cntrl->mhi_event[mhi_chan->er_index]; + mhi_chan->intmod = mhi_event->intmod; } if (mhi_cntrl->bounce_buf) { -- 2.26.GIT