From patchwork Tue Dec 3 16:19:14 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thierry Reding X-Patchwork-Id: 11271557 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 D4E5F1805 for ; Tue, 3 Dec 2019 16:19:39 +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 BDD2D2080A for ; Tue, 3 Dec 2019 16:19:39 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org BDD2D2080A 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 DA2DE6E84A; Tue, 3 Dec 2019 16:19:37 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wm1-x341.google.com (mail-wm1-x341.google.com [IPv6:2a00:1450:4864:20::341]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4E75F6E846 for ; Tue, 3 Dec 2019 16:19:36 +0000 (UTC) Received: by mail-wm1-x341.google.com with SMTP id t14so4155824wmi.5 for ; Tue, 03 Dec 2019 08:19:36 -0800 (PST) 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=8PwWQma+5Pqkctg0DzIuMrwRQe9FFZs9mcoeMD+RaeE=; b=QZ31CevArO+xRaMUNJ7ZNAed7yknB9faIw2Oafh5HEDPGuKAlvr5qm408OZjkI5AcD TMsXmZSlm3f5unZFYfiXpPQEafJO9F93sX3vWM/33pBLIGub8z+cjude/oWj4a8XKPrI nHh4wlOTf+xt4TffHFClwNqD7Ni7lj9E6jNTzJ8uARv0mkzSubvHu7mXYt67NGr+Pou1 yUE+A7GccpXDBrzHsNmW5e7f33gOPEz1YZgGu3QqUHPQi/q24TZGuCx5lwhdgJBknCzo jit3Poh+x5+yNbHzu1XYBQsMRsUx/JPHUW1SQAG+SLNzO98GHy4MxVF25DlDFhRkGy8m t2RQ== X-Gm-Message-State: APjAAAWHZn23F+SqHXyTlh+mn4OUOXCKePxDqzhu/kL8CAbeKr1La1s7 7AIyE4sJL/Fb9ZnH09jVoUk= X-Google-Smtp-Source: APXvYqxOisZqSvaS/kGDwfMGxj2Ecv3XXSg0r7See1EWGq29HYu3V+oJdlDy2Gj75UilxKxpChqpdQ== X-Received: by 2002:a1c:6207:: with SMTP id w7mr28616534wmb.16.1575389974756; Tue, 03 Dec 2019 08:19:34 -0800 (PST) Received: from localhost (pD9E518ED.dip0.t-ipconnect.de. [217.229.24.237]) by smtp.gmail.com with ESMTPSA id x11sm4401057wre.68.2019.12.03.08.19.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 Dec 2019 08:19:34 -0800 (PST) From: Thierry Reding To: Thierry Reding Subject: [PATCH v2 9/9] drm/tegra: Run hub cleanup on ->remove() Date: Tue, 3 Dec 2019 17:19:14 +0100 Message-Id: <20191203161914.1312555-9-thierry.reding@gmail.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20191203161914.1312555-1-thierry.reding@gmail.com> References: <20191203161914.1312555-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=8PwWQma+5Pqkctg0DzIuMrwRQe9FFZs9mcoeMD+RaeE=; b=nJrGvRP1wJU1oSWsRp5EnoobaFJ9zhQsNutzeCuPChjvEsRJdyhqa6k27WUpU7Ngeq oipxqLhPj2//BPhuh2AJWL+zxS9rIQ2e34yD4gvHjS47boCH3c1Kr7xAfp/dYM35Ig9l lPCFFSXnzoZz7TtHoGpiHixngXtc7171HVpuOLaZ28CwzMFitI1Ckxwz+QLipCnaHR0y qOwtofLBcgmENMSFPYqgRpARIGsPzG+wrpjvkk3SZNQFyc4o1cWs8SGbUQhYMdJITL+1 KgJ6cXYgVTtwbgTIgeyT871H2iP+ECFMdkm7AMHE4tHOmnUC5gk6oPB99Ae8h8pRbR/e mtrg== 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, dri-devel@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Thierry Reding The call to tegra_display_hub_cleanup() that takes care of disabling the window groups is missing from the driver's ->remove() callback. Call it to make sure the runtime PM reference counts for the display controllers are balanced. Signed-off-by: Thierry Reding --- drivers/gpu/drm/tegra/drm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/tegra/drm.c b/drivers/gpu/drm/tegra/drm.c index 7a16b51eaa2d..f455ce71e85d 100644 --- a/drivers/gpu/drm/tegra/drm.c +++ b/drivers/gpu/drm/tegra/drm.c @@ -1241,6 +1241,9 @@ static int host1x_drm_remove(struct host1x_device *dev) drm_atomic_helper_shutdown(drm); drm_mode_config_cleanup(drm); + if (tegra->hub) + tegra_display_hub_cleanup(tegra->hub); + err = host1x_device_exit(dev); if (err < 0) dev_err(&dev->dev, "host1x device cleanup failed: %d\n", err);