Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp4354554pxk; Wed, 30 Sep 2020 00:14:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxsIZjaEH7/Cm1HF2jp/tlPN3Spy7p5Dl8/h7lGdWTJJJ3cBAtay9g01178OG5yztQaXUdB X-Received: by 2002:a05:6402:346:: with SMTP id r6mr1234791edw.301.1601450092526; Wed, 30 Sep 2020 00:14:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601450092; cv=none; d=google.com; s=arc-20160816; b=kBHp3Cy2i+6oyQvWcuRY6G+xVpzEBC3KbfedbXINZBMh/MTw9IaZ//W6IpVwk/noiz TgBlqGHoi2Ky+PrDAc08XmAufvxOPWPBSFczQr6T0J87/XzFIG/ltrNzRO2J5UFkWZK6 Uqh896AquEP5/5eU4Bge/eH7k6vok/7QvGG7deGGxa0dD74/PAEonuLB5/oTI+DDaWtT cJC58YkWPK6uRRvKh4kZsPBuA3XnKn5Xf2/y3sx1nVmtB7RLbWB/UpUhHQy7rgXRfwVM Yy0ogAXsWreD0o9hF0S9lxgeJNSuVWP8J8am164mgohA33qfclWubdFlCxsS6CLlQh+D CorQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=MWKBOCPWVmAmkC+xaTr91BxSyAv1FiKQPsekbK1C30E=; b=aBInI63MWM4YhdupGWXI8Qi6SSUv7cXgIh2iuSwBd1phPZ2VuoCEbDp9VfVF3bT7zA 9OI+Ha8qkXl23Ke/UX/IPgSnftAxktcJ5P8A9WuPtygx4zkWIhNTtU2RKVaxa4KDqBFx EmuwThTouuXp0NOQAAL/RzsHmLmo0ah5VttRhe26EA2HmxYaNfj9l5cYvxtjTUfuTpA2 D07RV1AUFfB3jCimG6c4U99kcITmK89O3MjshmRnI3rnRbLYQmEbvQNuXk7mFrT/Ufge QysU9NEx4vcFGb8LdY7MIKqYvvNj+Yqh60zB/EgvAgIOxAa/AVIoWjBdjknJjHc7zjKG V4lA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=DyEjjW6Z; 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=mediatek.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cb13si516209edb.153.2020.09.30.00.14.30; Wed, 30 Sep 2020 00:14:52 -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=@mediatek.com header.s=dk header.b=DyEjjW6Z; 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=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728310AbgI3HLI (ORCPT + 99 others); Wed, 30 Sep 2020 03:11:08 -0400 Received: from mailgw02.mediatek.com ([210.61.82.184]:41980 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1728149AbgI3HLI (ORCPT ); Wed, 30 Sep 2020 03:11:08 -0400 X-UUID: eac529d346754bcd98961c7f20d9c6ac-20200930 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=MWKBOCPWVmAmkC+xaTr91BxSyAv1FiKQPsekbK1C30E=; b=DyEjjW6ZLxmBNyzVjL/9wWQOZaCVbjdn3Z8V6+qEm2zNZA1682yITGbRq1wvL7ITG0I0OO/MgWnZ8ZYR8yD0Z0UqX8iIYe7pzBj5BoGSFwc4FMup2k5E5flCjL/KcouxPl+LeOPLuSMtZcLH4uKylnn7J4cySXPQR1hAYUnnHvk=; X-UUID: eac529d346754bcd98961c7f20d9c6ac-20200930 Received: from mtkcas10.mediatek.inc [(172.21.101.39)] by mailgw02.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.14 Build 0819 with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 1380419118; Wed, 30 Sep 2020 15:11:02 +0800 Received: from mtkcas08.mediatek.inc (172.21.101.126) by mtkmbs08n1.mediatek.inc (172.21.101.55) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 30 Sep 2020 15:10:59 +0800 Received: from localhost.localdomain (10.17.3.153) by mtkcas08.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Wed, 30 Sep 2020 15:11:00 +0800 From: Yong Wu To: Joerg Roedel , Matthias Brugger , Rob Herring , Robin Murphy , Krzysztof Kozlowski , Will Deacon CC: Evan Green , Tomasz Figa , , , , , , , , , Nicolas Boichat , , , , Greg Kroah-Hartman , Subject: [PATCH v3 20/24] iommu/mediatek: Support report iova 34bit translation fault in ISR Date: Wed, 30 Sep 2020 15:06:43 +0800 Message-ID: <20200930070647.10188-21-yong.wu@mediatek.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20200930070647.10188-1-yong.wu@mediatek.com> References: <20200930070647.10188-1-yong.wu@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain X-MTK: N Content-Transfer-Encoding: base64 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org SWYgdGhlIGlvdmEgaXMgb3ZlciAzMmJpdCwgdGhlIGZhdWx0IHN0YXR1cyByZWdpc3RlciBiaXQg aXMgYSBsaXR0bGUNCmRpZmZlcmVudC4gQWRkIGEgZmxhZyBmb3IgdGhlI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