From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.7 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 182FBC47404 for ; Wed, 9 Oct 2019 13:19:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DD8352133F for ; Wed, 9 Oct 2019 13:19:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731413AbfJINTe (ORCPT ); Wed, 9 Oct 2019 09:19:34 -0400 Received: from mailgw01.mediatek.com ([210.61.82.183]:28756 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1729883AbfJINTd (ORCPT ); Wed, 9 Oct 2019 09:19:33 -0400 X-UUID: ac9d234a2a2a49a38a7ead9adfdb39cc-20191009 X-UUID: ac9d234a2a2a49a38a7ead9adfdb39cc-20191009 Received: from mtkcas09.mediatek.inc [(172.21.101.178)] by mailgw01.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 127445755; Wed, 09 Oct 2019 21:19:28 +0800 Received: from mtkcas09.mediatek.inc (172.21.101.178) by mtkmbs07n2.mediatek.inc (172.21.101.141) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Wed, 9 Oct 2019 21:19:24 +0800 Received: from localhost.localdomain (10.17.3.153) by mtkcas09.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1395.4 via Frontend Transport; Wed, 9 Oct 2019 21:19:23 +0800 From: Yong Wu To: Matthias Brugger , Joerg Roedel , Will Deacon CC: Evan Green , Robin Murphy , Tomasz Figa , , , , , , , , Nicolas Boichat , , , Subject: [PATCH v2 4/4] iommu/mediatek: Reduce the tlb flush timeout value Date: Wed, 9 Oct 2019 21:19:03 +0800 Message-ID: <1570627143-29441-4-git-send-email-yong.wu@mediatek.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1570627143-29441-1-git-send-email-yong.wu@mediatek.com> References: <1570627143-29441-1-git-send-email-yong.wu@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain X-MTK: N Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Reduce the tlb timeout value from 100000us to 1000us. the original value is so long that affect the multimedia performance. This is only a minor improvement rather than fixing a issue. Signed-off-by: Yong Wu --- drivers/iommu/mtk_iommu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c index 607f92c..1e9ff25 100644 --- a/drivers/iommu/mtk_iommu.c +++ b/drivers/iommu/mtk_iommu.c @@ -195,7 +195,7 @@ static void mtk_iommu_tlb_add_flush(unsigned long iova, size_t size, * follows tlb_flush to avoid break the sequence. */ ret = readl_poll_timeout_atomic(data->base + REG_MMU_CPE_DONE, - tmp, tmp != 0, 10, 100000); + tmp, tmp != 0, 10, 1000); if (ret) { dev_warn(data->dev, "Partial TLB flush timed out, falling back to full flush\n"); -- 1.9.1