Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp872581ybi; Fri, 31 May 2019 10:05:35 -0700 (PDT) X-Google-Smtp-Source: APXvYqxfsXZQ+g6swBRj9i/NnmQ9p44DhrsVgLx4NWH+WjBKZe1d5LiNken1FOPWJAbYpHCFnzGm X-Received: by 2002:a17:902:8a83:: with SMTP id p3mr11049939plo.88.1559322334976; Fri, 31 May 2019 10:05:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559322334; cv=none; d=google.com; s=arc-20160816; b=jU1KGBUtY5vcju5d3SoADaGHxbQZzuxHEO/FIu/MsAWRMM1M4SKJuQUE8/gvsbWZi2 uxW7kyBCEiYFbCB+ARxnjbxGyKYXUM1/Wsd8Sa9EdFGWpNJyyoKLSz1ITQgB0r6AVKHc kkw3xDZgJ9BSwzZLVZe81FE4JbUn5YFfGKaTEoFZJ5uwnRajjJNd4y+JBLgsqR8Ef6yt d0BxgiXENbdsSWSGpzHq3vvGHYARV78mCYCHT7OTsrAxhxwEY5pHemGdMyk7jnr0Hsml 6PmijSvo+sMunYoc7x4mEgO0h/WQBCyCkE/5QQTw74WMt2+YIAc/XoFbOlxzBUw26q0p atXQ== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=h+M9syy6WSkyGoqQgjhwE8nq1YAhflFyMTQGmx/XBzA=; b=A1jIXZN1b+NuVyIEeBHfcIkPSX/EQM90iZhTmCFT7nyJy2Rug+mmHZQ9m031QQ3i62 uQRmItg1HiDdt01g58e1ZjZUiM966QFtaNHAazX8Ag5y5y7zovoZROGOvNcqFRKB9uzQ xYJlxGfBeF3nRpDcDd3bl2sn6La6GMOpU4wjikl8BEiB1poPrV4/uYxpBRG2Cw71zpQp Y1Qly9Ip6hgmWuTJtz25Y3gDKcnzW/4DGpHeHhnqcHMvjbR654u0xHWVng6N9QQmvJ8n FveOX77KaySfCSuxDRVBC//MZOpQg49phNvICwlM4TkB6JHUn/M9maxYbn+XQ83kspx0 Mk0g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 68si6705212ple.89.2019.05.31.10.05.16; Fri, 31 May 2019 10:05:34 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726941AbfEaRDh (ORCPT + 99 others); Fri, 31 May 2019 13:03:37 -0400 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70]:54924 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726531AbfEaRDh (ORCPT ); Fri, 31 May 2019 13:03:37 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 00600A78; Fri, 31 May 2019 10:03:37 -0700 (PDT) Received: from [10.1.196.75] (e110467-lin.cambridge.arm.com [10.1.196.75]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 7B94C3F59C; Fri, 31 May 2019 10:03:32 -0700 (PDT) Subject: Re: [PATCH v3 0/6] Prerequisites for NXP LS104xA SMMU enablement To: Christoph Hellwig , David Miller Cc: madalin.bucur@nxp.com, netdev@vger.kernel.org, roy.pledge@nxp.com, linux-kernel@vger.kernel.org, leoyang.li@nxp.com, Joakim.Tjernlund@infinera.com, iommu@lists.linux-foundation.org, camelia.groza@nxp.com, linuxppc-dev@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org References: <20190530141951.6704-1-laurentiu.tudor@nxp.com> <20190530.150844.1826796344374758568.davem@davemloft.net> <20190531163350.GB8708@infradead.org> From: Robin Murphy Message-ID: <37406608-df48-c7a0-6975-4b4ad408ba36@arm.com> Date: Fri, 31 May 2019 18:03:30 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <20190531163350.GB8708@infradead.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 31/05/2019 17:33, Christoph Hellwig wrote: > On Thu, May 30, 2019 at 03:08:44PM -0700, David Miller wrote: >> From: laurentiu.tudor@nxp.com >> Date: Thu, 30 May 2019 17:19:45 +0300 >> >>> Depends on this pull request: >>> >>> http://lists.infradead.org/pipermail/linux-arm-kernel/2019-May/653554.html >> >> I'm not sure how you want me to handle this. > > The thing needs to be completely redone as it abuses parts of the > iommu API in a completely unacceptable way. `git grep iommu_iova_to_phys drivers/{crypto,gpu,net}` :( I guess one alternative is for the offending drivers to maintain their own lookup tables of mapped DMA addresses - I think at least some of these things allow storing some kind of token in a descriptor, which even if it's not big enough for a virtual address might be sufficient for an index. Robin.