Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp3461882pxb; Mon, 24 Jan 2022 10:03:11 -0800 (PST) X-Google-Smtp-Source: ABdhPJxXDlrGb2GO8kXv/Z7VFGEHeLjEwsWG/xNvg1/WW9spNSQUDafSX7+LfmATQP0fo+JwvzO0 X-Received: by 2002:a17:902:9893:b0:14b:4d5e:de0c with SMTP id s19-20020a170902989300b0014b4d5ede0cmr5853511plp.117.1643047391059; Mon, 24 Jan 2022 10:03:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1643047391; cv=none; d=google.com; s=arc-20160816; b=TRgRKyb7hmxj+/zSlfvS8/wYJfX1EoKEmcSyUhIcOwb7fwxu8yPqzcaxRyEe+jQihM p3UHV6CjwwzT8HHa3EotIn5QbkyO+jhiYDl4L8H9vbikUSipYq+ncPXyo/pTc8sokEmD q78IED9PyyZzOB0eSq/GY6Qf8vA4qZ1nZVbGxncvMCSCun4JUmHF4pKdUgd1imQPWOvX Q3BOxD6WGnU6LzlbLhNF9rh/lPOaf4yiyzkhDDNh4oJYmtLPkspXd9g61wkxpYzi6vIT Lb37LSsiWLzR0SSmL7bV0DbvFlYnELfy7J+HJXfrmroTMYtR1mMx/f6/BMiwlLxnj1JP 0pAQ== 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=8kvQAexJnq01uXrZ8zP5VCZMgCWL1uV47m7LULPbxjo=; b=oeuP9dDoaS4aYH7xPvcWg+lp1hSfgSYgcHbJoKW2Z4Sxpw6wK4EDMQtzlH9Zgh7G2O dXplDKwyXHUBCCIwYfTK8RsAfSxwVRHa/pCprKSyiqybr/aUS7EYuz1KmWm8ikXPnki7 fBDu0usFj8f4W3IrleQvTM9Oc7zfizux6vnOlsdQXqe65KOOc2wfLSEZr/3qdEj3pp/X CLzyFJ7gUZN7uZJ/FXYASpXuSVMk5bq+ED42Y8enl24RwuhA+YHe91ZA1cxWVWt66UY0 v+J7a+rB6TRTAxqHkR3DXxFumC3uuvAJuFH1VbL21oV0HIP6faXMkBsDXna7VjTON5F3 bN3w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=gjezBRg7; 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=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id np1si50744pjb.84.2022.01.24.10.02.58; Mon, 24 Jan 2022 10:03:11 -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=@intel.com header.s=Intel header.b=gjezBRg7; 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=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241731AbiAXHMz (ORCPT + 99 others); Mon, 24 Jan 2022 02:12:55 -0500 Received: from mga04.intel.com ([192.55.52.120]:53043 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241712AbiAXHMw (ORCPT ); Mon, 24 Jan 2022 02:12:52 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1643008372; x=1674544372; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=5TBZFsenuHwIPheekH0b3CEaehnEyJPuQXeOFXtZL/A=; b=gjezBRg7+MwXko5z8nOG9kd+YmHFfkYR5vRLaoVC4Dgdsot9+oUFpyEI STu0yQQuomLVSb4A6wlr6TIde7sQTp5BVuFNtB7AzwsbYu3GAjeu6DdCk U1fcXzcVaE88N4qhP/Ks+ZakkOgVKxeSPBmi6E+VSfa8nSFXSeKySQaxz +e1GE4BeGihpQAquFJryua7KpMGR/gv+sKA1otj5slrafzr1NjAwflV16 aXYSe+JwloJffh6b9Z8VZM0ZY+mF7PdezDcGa6f2IpjWv8gXqWv62TojV jB6dcVsDQuAfAIqWJI5+iradhZrJZLlfvk437jmL41Yed90gGv1ZWeEL6 w==; X-IronPort-AV: E=McAfee;i="6200,9189,10236"; a="244814249" X-IronPort-AV: E=Sophos;i="5.88,311,1635231600"; d="scan'208";a="244814249" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Jan 2022 23:12:47 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,311,1635231600"; d="scan'208";a="627387804" Received: from allen-box.sh.intel.com ([10.239.159.118]) by orsmga004.jf.intel.com with ESMTP; 23 Jan 2022 23:12:43 -0800 From: Lu Baolu To: Joerg Roedel , Jason Gunthorpe , Christoph Hellwig , Ben Skeggs , Kevin Tian , Ashok Raj , Will Deacon , Robin Murphy Cc: Alex Williamson , Eric Auger , Liu Yi L , Jacob jun Pan , David Airlie , Daniel Vetter , Thierry Reding , Jonathan Hunter , iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Lu Baolu Subject: [PATCH 5/7] drm/nouveau/device: Get right pgsize_bitmap of iommu_domain Date: Mon, 24 Jan 2022 15:11:00 +0800 Message-Id: <20220124071103.2097118-6-baolu.lu@linux.intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220124071103.2097118-1-baolu.lu@linux.intel.com> References: <20220124071103.2097118-1-baolu.lu@linux.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The supported page sizes of an iommu_domain are saved in the pgsize_bitmap field. Retrieve the value from the right place. Signed-off-by: Lu Baolu Reviewed-by: Robin Murphy Link: https://lore.kernel.org/r/20211218074546.1772553-1-baolu.lu@linux.intel.com --- drivers/gpu/drm/nouveau/nvkm/engine/device/tegra.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/device/tegra.c b/drivers/gpu/drm/nouveau/nvkm/engine/device/tegra.c index d0d52c1d4aee..992cc285f2fe 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/device/tegra.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/device/tegra.c @@ -133,7 +133,7 @@ nvkm_device_tegra_probe_iommu(struct nvkm_device_tegra *tdev) * or equal to the system's PAGE_SIZE, with a preference if * both are equal. */ - pgsize_bitmap = tdev->iommu.domain->ops->pgsize_bitmap; + pgsize_bitmap = tdev->iommu.domain->pgsize_bitmap; if (pgsize_bitmap & PAGE_SIZE) { tdev->iommu.pgshift = PAGE_SHIFT; } else { -- 2.25.1