From patchwork Tue Jun 5 13:54:07 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Benjamin Gaignard X-Patchwork-Id: 137746 Delivered-To: patch@linaro.org Received: by 2002:a2e:970d:0:0:0:0:0 with SMTP id r13-v6csp990458lji; Tue, 5 Jun 2018 06:54:42 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKwg+H0VSSCrSu1VLcTyu2elNjl/vKCnXwFCMfhuEa5KPDa0zLxOfyZjxofA3kbKRQc9y1l X-Received: by 2002:a17:902:7883:: with SMTP id q3-v6mr26842209pll.71.1528206882508; Tue, 05 Jun 2018 06:54:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528206882; cv=none; d=google.com; s=arc-20160816; b=nfKm8ybITSGTuIAX8a//yrOij6AIbmmLaJ+mtbpNtMM7K2m3SC4LheC8Ln1NKXGP0g Ig/ua8QFUm7063GQHKruEFC7bSviFMRTYxUXEwtrYAf+YiY9Flo+dwX2OVNWHNGlD6pf JuBgJvJOAczfvGZ/T5CL7tDJz8MNDbRaSykL+81w+92CTIeuWJAQrXLnAzewtTYnkUdX 0WjdE5i6BQnWO9hffhifjFIyZewWPAoRAYuPrrJq6tdpa6PMK5shO+zR1lsFihF9rbEc LT+w8MUGxgygetSZGp1Giryq9InIFWB2bfZ6171Lk6tWkbAVjnWTeQ1T1S+796PPGhFO txuA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=LX5Ax/A7QrfEjVy8tdEiGXI2NPjRkDiNrXaHP/an6n8=; b=v+ronZkkugjpDUjMPXywN1fjxyP59fA8NeY4v3DqIKXtVHEDZ+30Ge2F28e0n9///f Y5ZwA2iD6KGJ5VZluYwWTfIseMkmE32QI+yezGC+xgffysTvFnJXHUZlC99jlEAYtZH9 As/fR1RDP6N33h9wEIhjNT7IFgJLENqc4NxBOJOGNE4rmvLjAXkZP2Ez8Wuv7bzXCR6m YFmbVPLYtCDplqCcYvYvW53+UbZM0m3u5bkJDJrNTEJrPnAACrjfUZaH4D/PCTRRY8gQ RkRnhjdZy7aT8jJXNu71iPPzzWbkpLfSJ5qNG82Jh42JdV2nVRzkLkKtsX0S/FIC8RUB rw6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=iBOGIHTT; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f6-v6si24914145plm.448.2018.06.05.06.54.42; Tue, 05 Jun 2018 06:54:42 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=iBOGIHTT; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752156AbeFENyj (ORCPT + 30 others); Tue, 5 Jun 2018 09:54:39 -0400 Received: from mail-wr0-f193.google.com ([209.85.128.193]:36055 "EHLO mail-wr0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751889AbeFENyf (ORCPT ); Tue, 5 Jun 2018 09:54:35 -0400 Received: by mail-wr0-f193.google.com with SMTP id f16-v6so2546832wrm.3 for ; Tue, 05 Jun 2018 06:54:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=LX5Ax/A7QrfEjVy8tdEiGXI2NPjRkDiNrXaHP/an6n8=; b=iBOGIHTTj4MzOzLWzwSOUhvYBiWYuD2dkSMsLDmTY1iXdzVHFoPUDydFkrTqwMbHtc U8a3sEo1eEdC5XoLL7/VYMij3eXUtBFtTih9a8yrkd/UldbvnGGLVyisULf01l0yAtoh YmBNT/1PPyZGKqafFxswTxkwJYowRAdeBBx0Q= 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; bh=LX5Ax/A7QrfEjVy8tdEiGXI2NPjRkDiNrXaHP/an6n8=; b=O4EcGD8ems9K/Ajcbj1JT+VALep0iqU3Sk0DZ1I2FCfEiUr/nRGmLq/raRvVo8juGn a8SS/bGRU8VlLlmxBjP9f/ZL4Qdr6hMJlL3ix+E98JYUfuQjGsXZ1nsqJegKrQdu/zr6 xija79A7pi/FKcj4GxT9n/+uxKav0FPeH+L0yT3XxIEcNkUKSF2JEKrWcTDXNtkmKfcJ n0sjDhYBS25E1+coXG4p6fpqiJwb+o687UYv7HwUrSyQHMPjZe+ExcS0/jqBk8VWsW0w xO/nCmWplOD1S/FxX8gnc1uQfFbVAh4aF+Vu9iRsho2UKTgJ0F55Dmtm5sN9V90PtCeM Ym2w== X-Gm-Message-State: APt69E1ORT+TU15sTUt+Rum0VldZOqzun7Xk8jvXw3kPGP6NNolNVuDl Vg7I/ZMcIlNPkt9My6Wo7R7vEQ== X-Received: by 2002:adf:d08b:: with SMTP id y11-v6mr2317032wrh.152.1528206874331; Tue, 05 Jun 2018 06:54:34 -0700 (PDT) Received: from lmecxl0911.lme.st.com (bol62-h02-176-179-166-238.dsl.sta.abo.bbox.fr. [176.179.166.238]) by smtp.gmail.com with ESMTPSA id o53-v6sm76797785wrc.96.2018.06.05.06.54.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 05 Jun 2018 06:54:33 -0700 (PDT) From: Benjamin Gaignard To: gustavo@padovan.org, maarten.lankhorst@linux.intel.com, seanpaul@chromium.org, airlied@linux.ie, vincent.abriou@st.com Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Benjamin Gaignard Subject: [PATCH v1 7/7] drm: sti: remove the last call to debugfs Date: Tue, 5 Jun 2018 15:54:07 +0200 Message-Id: <20180605135407.20214-8-benjamin.gaignard@linaro.org> X-Mailer: git-send-email 2.15.0 In-Reply-To: <20180605135407.20214-1-benjamin.gaignard@linaro.org> References: <20180605135407.20214-1-benjamin.gaignard@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Thanks to all the hooks in drm structure, custom debugfs could be removed of sti driver. Signed-off-by: Benjamin Gaignard --- drivers/gpu/drm/sti/sti_drv.c | 50 ------------------------------------------- 1 file changed, 50 deletions(-) -- 2.15.0 diff --git a/drivers/gpu/drm/sti/sti_drv.c b/drivers/gpu/drm/sti/sti_drv.c index 90c46b49c931..95b0ac4d819c 100644 --- a/drivers/gpu/drm/sti/sti_drv.c +++ b/drivers/gpu/drm/sti/sti_drv.c @@ -7,7 +7,6 @@ #include #include -#include #include #include #include @@ -72,53 +71,6 @@ static int sti_drm_fps_set(void *data, u64 val) DEFINE_SIMPLE_ATTRIBUTE(sti_drm_fps_fops, sti_drm_fps_get, sti_drm_fps_set, "%llu\n"); -static int sti_drm_fps_dbg_show(struct seq_file *s, void *data) -{ - struct drm_info_node *node = s->private; - struct drm_device *dev = node->minor->dev; - struct drm_plane *p; - - list_for_each_entry(p, &dev->mode_config.plane_list, head) { - struct sti_plane *plane = to_sti_plane(p); - - seq_printf(s, "%s%s\n", - plane->fps_info.fps_str, - plane->fps_info.fips_str); - } - - return 0; -} - -static struct drm_info_list sti_drm_dbg_list[] = { - {"fps_get", sti_drm_fps_dbg_show, 0}, -}; - -static int sti_drm_dbg_init(struct drm_minor *minor) -{ - struct dentry *dentry; - int ret; - - ret = drm_debugfs_create_files(sti_drm_dbg_list, - ARRAY_SIZE(sti_drm_dbg_list), - minor->debugfs_root, minor); - if (ret) - goto err; - - dentry = debugfs_create_file("fps_show", S_IRUGO | S_IWUSR, - minor->debugfs_root, minor->dev, - &sti_drm_fps_fops); - if (!dentry) { - ret = -ENOMEM; - goto err; - } - - DRM_INFO("%s: debugfs installed\n", DRIVER_NAME); - return 0; -err: - DRM_ERROR("%s: cannot install debugfs\n", DRIVER_NAME); - return ret; -} - static const struct drm_mode_config_funcs sti_mode_config_funcs = { .fb_create = drm_gem_fb_create, .output_poll_changed = drm_fb_helper_output_poll_changed, @@ -167,8 +119,6 @@ static struct drm_driver sti_driver = { .gem_prime_vunmap = drm_gem_cma_prime_vunmap, .gem_prime_mmap = drm_gem_cma_prime_mmap, - .debugfs_init = sti_drm_dbg_init, - .name = DRIVER_NAME, .desc = DRIVER_DESC, .date = DRIVER_DATE,