Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2640197pxb; Tue, 19 Jan 2021 02:16:17 -0800 (PST) X-Google-Smtp-Source: ABdhPJzgo0E5SN+9qsDDplTKwsW7gV0BV2pQuNc+xtecaJDMI0XmWH/k1vmrv0zt3KpQ6EyIuKvi X-Received: by 2002:aa7:c3d9:: with SMTP id l25mr2987783edr.188.1611051259064; Tue, 19 Jan 2021 02:14:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611051259; cv=none; d=google.com; s=arc-20160816; b=jePsMBrHAGqo3KL5w26E340L5ONiJOXmJlhfrREYSD24HqBwCVPTNoVutXB9oMWLzn rXfUyui4ztzhnobX8uygbmvHMAouamWIh5q1y6fyWpvbrKGRbB90ghK52VY/cCB0cb75 KSpsk600um9MiU0248Iw4+xAO0HfUfPDZDeDwtvBLVP/u7P9Es/rgUZpGOP8T72YINIU Xo6a4V57i/Ailc3DAclca8P9JnGOFKJ3za+b0DqQTdnELbTt6NTaLC8tbD9gC226rNsQ /9YMpapFD24m02ChwWAvPayk7br7hoieAC6P+th3mhxlE6dFEnUvC0HM7I8Mn2Lz5iNW CcyA== 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:date:cc:to:from:subject:message-id :dkim-signature; bh=giToPo/p/3LJytE3l2ogQIfAO4f4TZp/+5aQlKOr25k=; b=ipMDV9Wod5u+r/IMopLzIilRg+4NY9exi0fXospMwmBgU5UQ8dC4Vl0TkvVA2lmDk/ 4AoI6N/WRHIgJ+89xkbIsKlT6Y3xk7MVoXl/cbkqWjqhZNudTr+BNdzXUWXzoPUS0kBs wqeVd+rVE+NyYLe582oUfht/HbkfW3buAv9c6AkJ8ozuyaMCmbECQ4llqveBtkGWDPI6 CVyscqPi+FFydQ+SiBMPsFK/OmHVTrOv2Yl16Nw2sD/ckvpX+maIH9GBNE5Yk6QXFVsC AO39yyXdFBSaYyPN+uVTlcYFiFLhoJJncYxbGQa2AWO4rzQFrA2XFx4NgC08tWEOawcp LYuA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=Q4PPqmPn; 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 c11si8396350edy.222.2021.01.19.02.13.45; Tue, 19 Jan 2021 02:14:19 -0800 (PST) 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=Q4PPqmPn; 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 S2388385AbhASJrO (ORCPT + 99 others); Tue, 19 Jan 2021 04:47:14 -0500 Received: from mailgw02.mediatek.com ([1.203.163.81]:49137 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1732408AbhASJVO (ORCPT ); Tue, 19 Jan 2021 04:21:14 -0500 X-UUID: 6882229557a9407083bf28f726eeb973-20210119 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:MIME-Version:Content-Type:References:In-Reply-To:Date:CC:To:From:Subject:Message-ID; bh=giToPo/p/3LJytE3l2ogQIfAO4f4TZp/+5aQlKOr25k=; b=Q4PPqmPnYGluQfcENozOFI7ipi/dEF+cpBdSMBJRpT1MvfNM6GQPKN/LpzQwqRQW9w3OPLs3dV02NjDc2kgg1Or0dNjVE9qsA473HidhbMe2i2tS2nBnHwVhhu4oL+CGCUE+saC0SaOQMVgHN3iA8wl6Z4voPXz3JpLXjOfuUPI=; X-UUID: 6882229557a9407083bf28f726eeb973-20210119 Received: from mtkcas35.mediatek.inc [(172.27.4.253)] by mailgw02.mediatek.com (envelope-from ) (mailgw01.mediatek.com ESMTP with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 1959994727; Tue, 19 Jan 2021 17:20:15 +0800 Received: from MTKCAS36.mediatek.inc (172.27.4.186) by MTKMBS31N1.mediatek.inc (172.27.4.69) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 19 Jan 2021 17:20:12 +0800 Received: from [10.17.3.153] (10.17.3.153) by MTKCAS36.mediatek.inc (172.27.4.170) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 19 Jan 2021 17:20:11 +0800 Message-ID: <1611048011.14702.6.camel@mhfsdcap03> Subject: Re: [PATCH v6 06/33] of/device: Move dma_range_map before of_iommu_configure From: Yong Wu To: Robin Murphy , Paul Kocialkowski CC: Rob Herring , , , Nicolas Boichat , , , Will Deacon , Frank Rowand , , Evan Green , "Tomasz Figa" , , , Krzysztof Kozlowski , Matthias Brugger , , Date: Tue, 19 Jan 2021 17:20:11 +0800 In-Reply-To: <1853732d-0efd-171e-9e1f-7ee7ed72a98f@arm.com> References: <20210111111914.22211-1-yong.wu@mediatek.com> <20210111111914.22211-7-yong.wu@mediatek.com> <20210114192732.GA3401278@robh.at.kernel.org> <1610688626.4578.1.camel@mhfsdcap03> <1853732d-0efd-171e-9e1f-7ee7ed72a98f@arm.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.10.4-0ubuntu2 MIME-Version: 1.0 X-TM-SNTS-SMTP: 20BEF15089BCBF56838670AF738616419DD03D4DB65FFC4A7D6595AC154756AB2000:8 X-MTK: N Content-Transfer-Encoding: base64 Precedence: bulk List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