From patchwork Wed Feb 5 15:39:50 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Alex Deucher X-Patchwork-Id: 11366469 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 C8646139A for ; Wed, 5 Feb 2020 15:40:31 +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 A79D020730 for ; Wed, 5 Feb 2020 15:40:31 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="U4a/P5Pa" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A79D020730 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 D4A9789E0E; Wed, 5 Feb 2020 15:40:15 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-yw1-xc43.google.com (mail-yw1-xc43.google.com [IPv6:2607:f8b0:4864:20::c43]) by gabe.freedesktop.org (Postfix) with ESMTPS id 9FEB789C88; Wed, 5 Feb 2020 15:40:14 +0000 (UTC) Received: by mail-yw1-xc43.google.com with SMTP id t141so2671571ywc.11; Wed, 05 Feb 2020 07:40:14 -0800 (PST) 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=vuO2RgQIhRHrPoIOS6P9hpIDp5H+sQisyjrPWS+rotU=; b=U4a/P5Pa+vBXftLpzlpSMwczedmOpU2J/TfhGqQ1o18IplsEQp8TumrzOqL0BJ/Q6k PROfFdEiYBiWWGHJV21kYp+fZYNnYZTvyxis9lZnxvoXX+7nz1a8/JEfDzj2n7H9bIGl DC9eYYA2Jq6mNx6K6z1JmPVl25OqYPa/xUyVDOacM82XGfJwhS310Mg8drttx+PnR0tN 4lhCETTxkLolgf7yIKRZyXrxenVQrigWgWrvtFxNZhGh8kKRJx5wGJqSQLaspnApyLIc 9eXJ9bm173oJTfErF1lmqFoxciCQ5VznTJW040pGNB5EOu4B/j5hSHV5vKIVDzZ603y3 2/rg== 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=vuO2RgQIhRHrPoIOS6P9hpIDp5H+sQisyjrPWS+rotU=; b=aOguDcU44L4KfppA4TDyakyNhBN1R2a+TA4eUpzB9GBCx/bp1fNTTc42uWBwupLv54 4zm7qQXHnnCDbGOaC3La8QpiGnB8TlR4WkcnYlNEbN/jJYtr2KGvlUQEpWjQA6y3OF3B XLo8HGYvWvJ5oX3nwpPXIGyBynpakhwI/6Zrp4ehi2sXPjX2y1lID6OyfwT3n5CPoiQQ u/uDZxXWD3hOfaS9tfFnFgNaGQpqvgFGWmtHaEafd21BJZY/QjgsZxUswHtfkeUUSPvR Umei2nIXcZCUefsd8yqz4sLxz/oLrRpMM98x6NOiTBOtiwUf8/SpRDbH+APiWJawRDNV lJ/w== X-Gm-Message-State: APjAAAUtsMtWSKNST2kL4ay9LxBqeSZMWEed3xN+X3WSyU2rjanQ1W3i 7riR9c6mU5GxBy2mEjpHAu2FVRRJ X-Google-Smtp-Source: APXvYqxQ6fDoTlN4Q2Re3os87V+GSEV6xqD2QUXsfB2wD3xB2t65GKjWMEIHyR0Cog7cXpoZvMvzBw== X-Received: by 2002:a5b:144:: with SMTP id c4mr31744112ybp.371.1580917213687; Wed, 05 Feb 2020 07:40:13 -0800 (PST) Received: from tr4.amd.com (atlvpn.amd.com. [165.204.84.11]) by smtp.gmail.com with ESMTPSA id q185sm61256ywh.61.2020.02.05.07.40.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 05 Feb 2020 07:40:13 -0800 (PST) From: Alex Deucher X-Google-Original-From: Alex Deucher To: amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org Subject: [PATCH 05/15] drm/amdgpu/fence: move debugfs init into core amdgpu debugfs Date: Wed, 5 Feb 2020 10:39:50 -0500 Message-Id: <20200205154000.536145-6-alexander.deucher@amd.com> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20200205154000.536145-1-alexander.deucher@amd.com> References: <20200205154000.536145-1-alexander.deucher@amd.com> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Alex Deucher , =?utf-8?q?Christian_K=C3=B6nig?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" In order to remove the load and unload drm callbacks, we need to reorder the init sequence to move all the drm debugfs file handling. Do this for fence handling. Acked-by: Christian König Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c | 3 +++ drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c | 3 --- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c index 84c5e9f23c76..bcd10daa6e39 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c @@ -1245,6 +1245,9 @@ int amdgpu_debugfs_init(struct amdgpu_device *adev) dev_err(adev->dev, "failed to register debugfs file for SA\n"); } + if (amdgpu_debugfs_fence_init(adev)) + dev_err(adev->dev, "fence debugfs file creation failed\n"); + return amdgpu_debugfs_add_files(adev, amdgpu_debugfs_list, ARRAY_SIZE(amdgpu_debugfs_list)); } diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c index 3c01252b1e0e..7531527067df 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c @@ -503,9 +503,6 @@ int amdgpu_fence_driver_init_ring(struct amdgpu_ring *ring, */ int amdgpu_fence_driver_init(struct amdgpu_device *adev) { - if (amdgpu_debugfs_fence_init(adev)) - dev_err(adev->dev, "fence debugfs file creation failed\n"); - return 0; }