Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp264705ybi; Thu, 13 Jun 2019 15:39:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqzy/p/332IWMBsn9hSnGR9trq+EmXH0qeXejUVHDYUawMHQwrEMHCShePTjYGwEQabYtguE X-Received: by 2002:a62:764d:: with SMTP id r74mr73865215pfc.110.1560465581880; Thu, 13 Jun 2019 15:39:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560465581; cv=none; d=google.com; s=arc-20160816; b=0W2OdeUaMe1HGc37SbeSN9iSrwrhfDalOcSSC0Dt6TDJhVrCmDyBBK6+rHxekl0jUF L3RtycKgsHXDXqdH79CEZ60lolLI7fuhlBoBTds90WbDWgAuUcvMCuXas+qFXRaO22FB tArwgk6yiTdG424JieRTILq6xI6NZ5x0dRtfCLRofmy+M8tbrbjx3NPgKZmbcOQu64tb UOCSIttOQxeFSZJ2t5r7ImNR8tANBa7I0ZORI0tLK3GG3Lqj+Sp4vUUbsr/L3EH4Yd4e Sw7neKa2EbHKuDPFSTWbPHoMOfsY1rZVF+e4ciSvk86el5zoGzp9yh4EHc3R28zHF5Ty KdRg== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=EcPKIz/cx9BuSCY4h5Jds9dddvg3WP5b4PjiRQaCMNk=; b=lhuw6KsY8wU0zPz0t33svEu61zNdOGlLu7+hFOlvKUjSH3Wr+YkvLskhZidU9cqB34 ZRWdv/EUUA1dAj5qAvsam1RRNHVyxWC3hiCaEoScuq4vrDY6w7MCM1bLKjq0zpVKP4Gj xNN/Vs4GyPNCIWWxVSGEJY/7tPlPNhollOwZ/RnQK6qnVHojFkYZVOGP/s/65gzkw9B1 G8ftnj0UW49QvvXcuxLfUn4Kj47Z/g2vUpfDov+dfCbTdjB3J0q8vTfntUg9YSzCuSep ZwwBTDZHSggM3ccWz/LMy/7MXLEV3dpfzFKFUlJywFAaX2YLG4yvEpABfczV1m1OqFKw Cuig== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@tcd-ie.20150623.gappssmtp.com header.s=20150623 header.b=Q7YqbkWK; 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 cj16si595331plb.239.2019.06.13.15.39.26; Thu, 13 Jun 2019 15:39:41 -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; dkim=pass header.i=@tcd-ie.20150623.gappssmtp.com header.s=20150623 header.b=Q7YqbkWK; 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 S1726771AbfFMWjS (ORCPT + 99 others); Thu, 13 Jun 2019 18:39:18 -0400 Received: from mail-ed1-f67.google.com ([209.85.208.67]:45572 "EHLO mail-ed1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725809AbfFMWjR (ORCPT ); Thu, 13 Jun 2019 18:39:17 -0400 Received: by mail-ed1-f67.google.com with SMTP id a14so456397edv.12 for ; Thu, 13 Jun 2019 15:39:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd-ie.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=EcPKIz/cx9BuSCY4h5Jds9dddvg3WP5b4PjiRQaCMNk=; b=Q7YqbkWKog9myMLVKuEgSGV/QhFlPY8pqvqD3ElQJa5O+VupGahQ/2KWdmD42UChZU wPmlxSspSryqNb5xCB8JLtGZX6vRCzXM8xY7AmfA6QICBXISxNprKepOzIgPRJ0PmKvq lwOf3L9Aeaw9au+GkaXXU5HxIJQ1vxFfownqyJtqMjhF5SRbY4FdMVVh7ZLQ7hbQYj3Q iidXZkXXf0qlsVYk9WxwAFcMHH4IP3leZkOYhpAmRlGBv4K+6lmx2ZeQRojQOmlcq9FK mitiCFQNPcpZ74hbmAblxvrrqQFu7g6p6HGZuZiNBMXyyAAw52tc7SZA4bY0a5yZBSlR Rxmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=EcPKIz/cx9BuSCY4h5Jds9dddvg3WP5b4PjiRQaCMNk=; b=DvDLmbKEumJZtPrz+BuorhJO/MHoZC6v2IFsloksY/G1ZHtfm1+kF69jJBIdRj1wVM 4Z8HKhQh9/qLMUz8lf6mw0/hG5jN/ih3wEoD3R6eJyRE75QCrTMh0Jux1dDPqN5r1Q1Q 5XK/ZduDUZb6rKEsHRtusj1z+jSpgA7zeOUmyQR0YFqIL3yI8g8lKo5iHH61u1NZD7Tq eJXb9kgA0BfnXUgvm05qdiutyMrFA8oobZqrddQnFOhu89NyVd3cVxRz8pMETe8jJ7sR DI4DwKmeU7btU3WVtfYCjpGVrvZv0DK35++rMEuiFw5HhY/tDrOZXKKui5HXEXyepu8D +vgA== X-Gm-Message-State: APjAAAWRONNNux0Gjqmeq8Ys4RPs9UqjeP0h1efgbYHf6bEcdFfRIXer l7lHt/Za9kwc5rgkwwRHUrVChw== X-Received: by 2002:a50:bdc2:: with SMTP id z2mr97240407edh.245.1560465555952; Thu, 13 Jun 2019 15:39:15 -0700 (PDT) Received: from localhost.localdomain ([2a02:8084:a0:bc00:8042:d435:a754:1f22]) by smtp.googlemail.com with ESMTPSA id s16sm216522eji.27.2019.06.13.15.39.13 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Thu, 13 Jun 2019 15:39:14 -0700 (PDT) From: Tom Murphy To: iommu@lists.linux-foundation.org Cc: Tom Murphy , Joerg Roedel , Will Deacon , Robin Murphy , Marek Szyprowski , Kukjin Kim , Krzysztof Kozlowski , David Woodhouse , Andy Gross , David Brown , Matthias Brugger , Rob Clark , Heiko Stuebner , Gerald Schaefer , Thierry Reding , Jonathan Hunter , Jean-Philippe Brucker , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-s390@vger.kernel.org, linux-tegra@vger.kernel.org, virtualization@lists.linux-foundation.org Subject: [PATCH v4 0/5] iommu/amd: Convert the AMD iommu driver to the dma-iommu api Date: Thu, 13 Jun 2019 23:38:55 +0100 Message-Id: <20190613223901.9523-1-murphyt7@tcd.ie> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Convert the AMD iommu driver to the dma-iommu api. Remove the iova handling and reserve region code from the AMD iommu driver. Change-log: V4: -Rebase on top of linux-next -Split the removing of the unnecessary locking in the amd iommu driver into a seperate patch -refactor the "iommu/dma-iommu: Handle deferred devices" patch and address comments v3: -rename dma_limit to dma_mask -exit handle_deferred_device early if (!is_kdump_kernel()) -remove pointless calls to handle_deferred_device v2: -Rebase on top of this series: http://git.infradead.org/users/hch/misc.git/shortlog/refs/heads/dma-iommu-ops.3 -Add a gfp_t parameter to the iommu_ops::map function. -Made use of the reserve region code inside the dma-iommu api Tom Murphy (5): iommu/amd: Remove unnecessary locking from AMD iommu driver iommu: Add gfp parameter to iommu_ops::map iommu/dma-iommu: Handle deferred devices iommu/dma-iommu: Use the dev->coherent_dma_mask iommu/amd: Convert AMD iommu driver to the dma-iommu api drivers/iommu/Kconfig | 1 + drivers/iommu/amd_iommu.c | 690 ++++---------------------------- drivers/iommu/amd_iommu_types.h | 1 - drivers/iommu/arm-smmu-v3.c | 2 +- drivers/iommu/arm-smmu.c | 2 +- drivers/iommu/dma-iommu.c | 45 ++- drivers/iommu/exynos-iommu.c | 2 +- drivers/iommu/intel-iommu.c | 2 +- drivers/iommu/iommu.c | 43 +- drivers/iommu/ipmmu-vmsa.c | 2 +- drivers/iommu/msm_iommu.c | 2 +- drivers/iommu/mtk_iommu.c | 2 +- drivers/iommu/mtk_iommu_v1.c | 2 +- drivers/iommu/omap-iommu.c | 2 +- drivers/iommu/qcom_iommu.c | 2 +- drivers/iommu/rockchip-iommu.c | 2 +- drivers/iommu/s390-iommu.c | 2 +- drivers/iommu/tegra-gart.c | 2 +- drivers/iommu/tegra-smmu.c | 2 +- drivers/iommu/virtio-iommu.c | 2 +- include/linux/iommu.h | 21 +- 21 files changed, 179 insertions(+), 652 deletions(-) -- 2.20.1