Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp3584020ybi; Sun, 2 Jun 2019 18:25:32 -0700 (PDT) X-Google-Smtp-Source: APXvYqwNPXdGBVrXEBFxaYRZlX+hEsZBya1qIEUjoGyctBlMVgXNc5RSeZCVtULziBYtSELSMXOs X-Received: by 2002:a17:90a:b00c:: with SMTP id x12mr26545368pjq.64.1559525132364; Sun, 02 Jun 2019 18:25:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559525132; cv=none; d=google.com; s=arc-20160816; b=aHzjb64ER1+FjwJT/l82mW7mEmBeCqsDqe6NgP2KGTT8v1XVrq34T6ZH1NdBJhDN1f 0qUgeJzV6MuSgSLJceqyAwE1yv9Vg463roD7BjeYso0gvVO3I4OyL5KTxCv8xRhwddTg sFqe6mKYw1WhG0kzxf1CzIpowJqHMDjizz1m+ypwnUi2WZNsrdv0k8Fzf5P3Z0ZSey3O SXKy7NvW20z82VcxmcdoQZRLFACuMYCupxMA4aze8N1WkDu3qVSh22Z1Z4bW/RS5UIlt Xl5g3zXn076ZVRQk22qPEw9ey1frKNF0CxihCZ5e/9joC/fCfKwYhxoEi5r2kDaHOaXV buTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=RkPBG/1k3TbHRimCN5Rh1oXSRyszQy35GEfOl0C1u4g=; b=ltuciIie8e7n01HgE5hFBYUK2e28KfcXfgl0soaFmoFx4jyNHED2MjOcInx+pTEaIE 9yYxImf34XN32EaScQrQYRn1/zMzL5ToCa91PgiKjgiMcvH/LdLoDhD7x8GQjJpeSYzM fT9Jio9MxGXELbnCjXj8hCxCNEOtfE2VFYZuY/3GlmuvPYmJGLRi4DaIIIX5FFacj72Y p3tDDNn1b/2dqXfBpeSzuFGedkN+uJy0BfN8D2aesFhMaz0HFq0+xSEp3uPq1aD+mOOV u4btN/Xc9R1Ov+zfmfBf+ybyhRperlARTKuQNmXR+U+TuQ2JD2X47V5b8biWdQjYd8zo tw8g== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s129si15835619pgs.436.2019.06.02.18.25.16; Sun, 02 Jun 2019 18:25:32 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727047AbfFCBX6 (ORCPT + 99 others); Sun, 2 Jun 2019 21:23:58 -0400 Received: from mga17.intel.com ([192.55.52.151]:20792 "EHLO mga17.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726270AbfFCBX4 (ORCPT ); Sun, 2 Jun 2019 21:23:56 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 02 Jun 2019 18:23:56 -0700 X-ExtLoop1: 1 Received: from allen-box.sh.intel.com ([10.239.159.136]) by FMSMGA003.fm.intel.com with ESMTP; 02 Jun 2019 18:23:52 -0700 From: Lu Baolu To: David Woodhouse , Joerg Roedel , Bjorn Helgaas , Christoph Hellwig Cc: ashok.raj@intel.com, jacob.jun.pan@intel.com, alan.cox@intel.com, kevin.tian@intel.com, mika.westerberg@linux.intel.com, Ingo Molnar , Greg Kroah-Hartman , pengfei.xu@intel.com, Konrad Rzeszutek Wilk , Marek Szyprowski , Robin Murphy , Jonathan Corbet , Boris Ostrovsky , Juergen Gross , Stefano Stabellini , Steven Rostedt , iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Lu Baolu , Jacob Pan , Mika Westerberg Subject: [PATCH v4 5/9] iommu/vt-d: Don't switch off swiotlb if use direct dma Date: Mon, 3 Jun 2019 09:16:16 +0800 Message-Id: <20190603011620.31999-6-baolu.lu@linux.intel.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190603011620.31999-1-baolu.lu@linux.intel.com> References: <20190603011620.31999-1-baolu.lu@linux.intel.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The direct dma implementation depends on swiotlb. Hence, don't switch of swiotlb since direct dma interfaces are used in this driver. Cc: Ashok Raj Cc: Jacob Pan Cc: Kevin Tian Cc: Mika Westerberg Signed-off-by: Lu Baolu --- drivers/iommu/intel-iommu.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c index d5a6c8064c56..235837c50719 100644 --- a/drivers/iommu/intel-iommu.c +++ b/drivers/iommu/intel-iommu.c @@ -4625,9 +4625,6 @@ static int __init platform_optin_force_iommu(void) iommu_identity_mapping |= IDENTMAP_ALL; dmar_disabled = 0; -#if defined(CONFIG_X86) && defined(CONFIG_SWIOTLB) - swiotlb = 0; -#endif no_iommu = 0; return 1; @@ -4765,9 +4762,6 @@ int __init intel_iommu_init(void) } up_write(&dmar_global_lock); -#if defined(CONFIG_X86) && defined(CONFIG_SWIOTLB) - swiotlb = 0; -#endif dma_ops = &intel_dma_ops; init_iommu_pm_ops(); -- 2.17.1