From patchwork Mon Oct 28 12:37:07 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thierry Reding X-Patchwork-Id: 11215289 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D92CB112C for ; Mon, 28 Oct 2019 12:37:29 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C188F208C0 for ; Mon, 28 Oct 2019 12:37:29 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C188F208C0 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 8CC9B6E821; Mon, 28 Oct 2019 12:37:28 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wm1-x343.google.com (mail-wm1-x343.google.com [IPv6:2a00:1450:4864:20::343]) by gabe.freedesktop.org (Postfix) with ESMTPS id E0E296E827 for ; Mon, 28 Oct 2019 12:37:24 +0000 (UTC) Received: by mail-wm1-x343.google.com with SMTP id w9so8950729wmm.5 for ; Mon, 28 Oct 2019 05:37:24 -0700 (PDT) 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=Bg9aLkLfUTKxfTeyqBBqYQUC6FBcU6JFCGZpsj7ndqo=; b=DHwuMt3YIlWo3MD3xm4pzyUlZx7nBK1Z+zqtjDquDAW2VcuDsBdWmMRf02CxTz7R3o 3A6ziu5oBd2OWJaOyK89QkC/fQytzY9upac83MxO6GlW0Q0gFIOLwTd6+x2jUBzNntlR nt4yYWDP23jiq71g1wxhmo3ydd8z/eAe/tMDdWucDfcqPUG1ITrjsms4DmNI6CdKBALt RhjcXIvtuX9onYkC1WSIi0li0edYNtUz3fB0ZCGM/7vLaKIvhMRt5XJhE1A4nlK59c6p d7j8ZAWALf8GZe9PIzuaRfbhZyRZXeo3JVEkA+o+8bv/CjW/6qpe/c/WrsMC7jsEvbIk ePJQ== X-Gm-Message-State: APjAAAWXOnxIKunesKlticopLONJf1n5p2zDChzudSWFp/tMqdRG0b0O z60DlZKEOXhXYYP92MS/2xN7H2QT X-Google-Smtp-Source: APXvYqxpcT29LVgI0DeFwPxEVNHmlij5DXWLor/hWFeN/TxAmFIMyCHnv/wteFbMeZzEJoUhBzKEYQ== X-Received: by 2002:a7b:c04c:: with SMTP id u12mr14331126wmc.134.1572266243371; Mon, 28 Oct 2019 05:37:23 -0700 (PDT) Received: from localhost (p2E5BE2CE.dip0.t-ipconnect.de. [46.91.226.206]) by smtp.gmail.com with ESMTPSA id s5sm6636457wmj.37.2019.10.28.05.37.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 28 Oct 2019 05:37:22 -0700 (PDT) From: Thierry Reding To: Thierry Reding Subject: [PATCH 01/12] memory: tegra: Add gr2d and gr3d to DRM IOMMU group Date: Mon, 28 Oct 2019 13:37:07 +0100 Message-Id: <20191028123718.3890217-2-thierry.reding@gmail.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20191028123718.3890217-1-thierry.reding@gmail.com> References: <20191028123718.3890217-1-thierry.reding@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Bg9aLkLfUTKxfTeyqBBqYQUC6FBcU6JFCGZpsj7ndqo=; b=MuwMV2cBGxuqCseG0mrSuo2oEvO+qF05OvTD8L+6lNTugvzPzoiKT+VY9diDTdYKG8 acfPCvEoUa9+cFd0RDm2Lw4lyQCNTAmY/zlOUrU+IbaMfpKN19jayd4th1nY6KvNTAD4 ADRVRtQ21cB6xqaHotOeynOJUsLGOMEQis5E6HOvf69sIbLOPmXgz4V68rl6PZRNTLIy XnfDvtD+YT8iT+c2ABJjzJcgiGpBCUtTwx9Su9y/famXUIvv4sksw7ze1towVxWUHaBF vUukp4WxovOCCi8WVyEM2LLZqADbaFzfaKmYfScJYqba4qlkw5LKfRsz3VKn52kbB7JQ tQcg== X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-tegra@vger.kernel.org, Sachin Nikam , dri-devel@lists.freedesktop.org, Puneet Saxena Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Thierry Reding All of the devices making up the Tegra DRM device want to share a single IOMMU domain. Put them into a single group to allow them to do that. Signed-off-by: Thierry Reding --- drivers/memory/tegra/tegra114.c | 10 ++++++---- drivers/memory/tegra/tegra124.c | 8 +++++--- drivers/memory/tegra/tegra30.c | 11 +++++++---- 3 files changed, 18 insertions(+), 11 deletions(-) diff --git a/drivers/memory/tegra/tegra114.c b/drivers/memory/tegra/tegra114.c index ac8351b5beeb..48ef01c3ff90 100644 --- a/drivers/memory/tegra/tegra114.c +++ b/drivers/memory/tegra/tegra114.c @@ -909,16 +909,18 @@ static const struct tegra_smmu_swgroup tegra114_swgroups[] = { { .name = "tsec", .swgroup = TEGRA_SWGROUP_TSEC, .reg = 0x294 }, }; -static const unsigned int tegra114_group_display[] = { +static const unsigned int tegra114_group_drm[] = { TEGRA_SWGROUP_DC, TEGRA_SWGROUP_DCB, + TEGRA_SWGROUP_G2, + TEGRA_SWGROUP_NV, }; static const struct tegra_smmu_group_soc tegra114_groups[] = { { - .name = "display", - .swgroups = tegra114_group_display, - .num_swgroups = ARRAY_SIZE(tegra114_group_display), + .name = "drm", + .swgroups = tegra114_group_drm, + .num_swgroups = ARRAY_SIZE(tegra114_group_drm), }, }; diff --git a/drivers/memory/tegra/tegra124.c b/drivers/memory/tegra/tegra124.c index 5d0ccb2be206..62b30b1b9677 100644 --- a/drivers/memory/tegra/tegra124.c +++ b/drivers/memory/tegra/tegra124.c @@ -974,16 +974,18 @@ static const struct tegra_smmu_swgroup tegra124_swgroups[] = { { .name = "vi", .swgroup = TEGRA_SWGROUP_VI, .reg = 0x280 }, }; -static const unsigned int tegra124_group_display[] = { +static const unsigned int tegra124_group_drm[] = { TEGRA_SWGROUP_DC, TEGRA_SWGROUP_DCB, + TEGRA_SWGROUP_GPU, + TEGRA_SWGROUP_VIC, }; static const struct tegra_smmu_group_soc tegra124_groups[] = { { .name = "display", - .swgroups = tegra124_group_display, - .num_swgroups = ARRAY_SIZE(tegra124_group_display), + .swgroups = tegra124_group_drm, + .num_swgroups = ARRAY_SIZE(tegra124_group_drm), }, }; diff --git a/drivers/memory/tegra/tegra30.c b/drivers/memory/tegra/tegra30.c index 14788fc2f9e8..8947bee6d032 100644 --- a/drivers/memory/tegra/tegra30.c +++ b/drivers/memory/tegra/tegra30.c @@ -931,16 +931,19 @@ static const struct tegra_smmu_swgroup tegra30_swgroups[] = { { .name = "isp", .swgroup = TEGRA_SWGROUP_ISP, .reg = 0x258 }, }; -static const unsigned int tegra30_group_display[] = { +static const unsigned int tegra30_group_drm[] = { TEGRA_SWGROUP_DC, TEGRA_SWGROUP_DCB, + TEGRA_SWGROUP_G2, + TEGRA_SWGROUP_NV, + TEGRA_SWGROUP_NV2, }; static const struct tegra_smmu_group_soc tegra30_groups[] = { { - .name = "display", - .swgroups = tegra30_group_display, - .num_swgroups = ARRAY_SIZE(tegra30_group_display), + .name = "drm", + .swgroups = tegra30_group_drm, + .num_swgroups = ARRAY_SIZE(tegra30_group_drm), }, };