From patchwork Thu Apr 2 15:30:38 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lucas Stach X-Patchwork-Id: 6149631 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 8CFA09F1BE for ; Thu, 2 Apr 2015 15:32:01 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id ACF82203AD for ; Thu, 2 Apr 2015 15:32:00 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id D1B36203AB for ; Thu, 2 Apr 2015 15:31:59 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 64F1D6EA8D; Thu, 2 Apr 2015 08:31:07 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [92.198.50.35]) by gabe.freedesktop.org (Postfix) with ESMTP id D23116EA7C for ; Thu, 2 Apr 2015 08:31:01 -0700 (PDT) Received: from dude.hi.4.pengutronix.de ([10.1.0.7] helo=dude.pengutronix.de.) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1Ydh5B-0005OD-4C; Thu, 02 Apr 2015 17:31:01 +0200 From: Lucas Stach To: dri-devel@lists.freedesktop.org Subject: [PATCH RFC 096/111] staging: etnaviv: don't pretend to have a single MMU Date: Thu, 2 Apr 2015 17:30:38 +0200 Message-Id: <1427988653-754-97-git-send-email-l.stach@pengutronix.de> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1427988653-754-1-git-send-email-l.stach@pengutronix.de> References: <1427988653-754-1-git-send-email-l.stach@pengutronix.de> X-SA-Exim-Connect-IP: 10.1.0.7 X-SA-Exim-Mail-From: l.stach@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: dri-devel@lists.freedesktop.org Cc: Russell King , kernel@pengutronix.de X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Each pipe has it's own MMU, so there is no point in pretending to have a single one at the DRM driver level. All MMU management has to happen on a per-pipe level. Signed-off-by: Lucas Stach --- drivers/staging/etnaviv/etnaviv_drv.c | 7 ------- drivers/staging/etnaviv/etnaviv_drv.h | 5 ----- drivers/staging/etnaviv/etnaviv_gpu.c | 1 - 3 files changed, 13 deletions(-) diff --git a/drivers/staging/etnaviv/etnaviv_drv.c b/drivers/staging/etnaviv/etnaviv_drv.c index 30896f9afa1a..25c64319ab34 100644 --- a/drivers/staging/etnaviv/etnaviv_drv.c +++ b/drivers/staging/etnaviv/etnaviv_drv.c @@ -22,13 +22,6 @@ #include "etnaviv_gpu.h" #include "etnaviv_mmu.h" -void etnaviv_register_mmu(struct drm_device *dev, struct etnaviv_iommu *mmu) -{ - struct etnaviv_drm_private *priv = dev->dev_private; - - priv->mmu = mmu; -} - #ifdef CONFIG_DRM_ETNAVIV_REGISTER_LOGGING static bool reglog; MODULE_PARM_DESC(reglog, "Enable register read/write logging"); diff --git a/drivers/staging/etnaviv/etnaviv_drv.h b/drivers/staging/etnaviv/etnaviv_drv.h index 5c3250b772cc..cf7e6f758dd7 100644 --- a/drivers/staging/etnaviv/etnaviv_drv.h +++ b/drivers/staging/etnaviv/etnaviv_drv.h @@ -61,13 +61,8 @@ struct etnaviv_drm_private { struct list_head inactive_list; struct workqueue_struct *wq; - - /* registered MMUs: */ - struct etnaviv_iommu *mmu; }; -void etnaviv_register_mmu(struct drm_device *dev, struct etnaviv_iommu *mmu); - int etnaviv_wait_fence_interruptable(struct drm_device *dev, struct etnaviv_gpu *gpu, uint32_t fence, struct timespec *timeout); diff --git a/drivers/staging/etnaviv/etnaviv_gpu.c b/drivers/staging/etnaviv/etnaviv_gpu.c index 0a6c702621d8..78955055d2eb 100644 --- a/drivers/staging/etnaviv/etnaviv_gpu.c +++ b/drivers/staging/etnaviv/etnaviv_gpu.c @@ -508,7 +508,6 @@ int etnaviv_gpu_init(struct etnaviv_gpu *gpu) ret = -ENOMEM; goto fail; } - etnaviv_register_mmu(gpu->drm, gpu->mmu); /* Create buffer: */ gpu->buffer = etnaviv_gem_new(gpu->drm, PAGE_SIZE, ETNA_BO_CMDSTREAM);