From patchwork Thu Dec 7 14:14:00 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 120982 Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp8409729qgn; Thu, 7 Dec 2017 06:14:33 -0800 (PST) X-Google-Smtp-Source: AGs4zMZvoN3gIXu18EHV59NDMK35SMOFHo8G93S8ZRCxBUrNMO8hx57gJ83ZgNo8hj0okDwE+lO9 X-Received: by 10.159.252.10 with SMTP id n10mr2122520pls.90.1512656073374; Thu, 07 Dec 2017 06:14:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1512656073; cv=none; d=google.com; s=arc-20160816; b=pZFT5poz9ZII5heykd6Q3xyIEZxSDT8gTUL8B9Gt/MAl//VHnDL1RMU71x77NwDb7Y RRaXabgdoFRF1jeiZ7tu5It2bBpeUrGPtW9Ny26Dz0OlCmrcEqmjJoyX2AvPDA7E5+ch nUUd7bijUHZ5qf6n95l17rVtih7Q74e7bLJrzdKKEWSQ+GhFFQ66cIa4exOUktRern2r U7Y0TVlVFqkLeCrqST3h7shD2vQYVgeKn+yXIT5sFYClrbSX4Dg27mFrfGiIrIf5p5WD qJ/n+kktTAltyfiVARPg1HMTMd/cEcyHzDtDDqSlwAsRdIQgJMaJ4tBtXmhY/GcjgSJ8 MPxQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=EzcEbvsbMGqeZ9gMAY0ruw8QKwuQwn0S4KghUyw4AnM=; b=XbyM/sNcFC8ixaJk2ZfM5T4P1UGWtfgG1phgGbg0PGRIZ7OdeEb6NGhWV5BgNj99kB DprJgjoC5nbxyfgydGe7vJyj6yo15KuWoZGgoQU/h9SRuyOkq8JqEfiB+4FYUm/mopIb MZ7P/EROfnHQFjiuY+ov6ABbf5mRQHiFAovF4xDIsa+XarDaUrepb1HBVie7xTQuIqnn EHmJ2YGWWXCa0H3dj5oB1pBqOjkO4MNIXN4Vl9s0t7ZSDqvIp4YR11oelc7vseJOH+61 2Nmz6xJ0HcQFaaYi7/V4L4UekpCmCMYxQYxpGJk2GtTsu95mI5io9Dkyz6t4cVW1VBsx ZZbg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b3si3796759plb.293.2017.12.07.06.14.33; Thu, 07 Dec 2017 06:14:33 -0800 (PST) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753479AbdLGOOb (ORCPT + 22 others); Thu, 7 Dec 2017 09:14:31 -0500 Received: from mout.kundenserver.de ([212.227.17.24]:56390 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753058AbdLGOO3 (ORCPT ); Thu, 7 Dec 2017 09:14:29 -0500 Received: from wuerfel.lan ([149.172.96.106]) by mrelayeu.kundenserver.de (mreue102 [212.227.15.145]) with ESMTPA (Nemesis) id 0M4ZiO-1fH7QL0FVU-00yfOE; Thu, 07 Dec 2017 15:14:17 +0100 From: Arnd Bergmann To: Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , David Airlie Cc: Arnd Bergmann , Chris Wilson , Tvrtko Ursulin , Mika Kuoppala , =?utf-8?q?Ville_Syrj=C3=A4l?= =?utf-8?b?w6Q=?= , intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH] drm/i915: add FTRACE dependency for DRM_I915_TRACE_GEM Date: Thu, 7 Dec 2017 15:14:00 +0100 Message-Id: <20171207141413.2008240-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:t24B+QiT6GOsOiHtavM5D7g0UhPZxpzFJCzxko+qYIJ02B0ngM1 KfR8CVAwIc0zhDbwR2VVUfL4Aw3l/OM/GuYss/cTWPv0LWFAxDC0oZuswre+fU8rinWeTiM 2J3fnJdfgeHFdyCGmnnzErBGgC1fRJZRo+BKjBwuYGa+MXt36iNfCg3lRN8vAim97YBpRQo 7qLdkd2qa+8oRlgGk3fRw== X-UI-Out-Filterresults: notjunk:1; V01:K0:dy5C7oJSo9g=:u5nj6ZUWM+SgaHZnbBlzC2 h7JP/UnPQzzbmD6bKPh7zbYuDOPfIt5MyZZ/xl7zbA3PYxA7NHSHvaTRdtOue0zr93Ggu+hKj XfxWhChQqPn8mr8rrYTXDE9/w5Z1wgORMi+aJCrsMphxeP8W/aNxK/NS27UwXZuZcNnyRVih7 MGRRNSkeJ5vw9yxYRj29/V9xEcWcTDO6FP3LrEz8MS3nHGNRWgmkABLd2oQSh/N+GAojU19DB TI6OFLMvJGPasZ/EAe1b6ZeEVZYPxKwXHbDF28HFoTt1k2lcmxug247xRFQmAuzhgFGwfDeZ9 V7kRNA7nq2drDoUqTfRoNcKfFSe6DDKZguY43FmGfj9/wnnCWNxcqpdkehgEs4dLc5huWk98W bb/aB1nCGbp9loNWOndb5KppOMuVIO3NqT7jBhs/OTZ5Bsj9JDHxCH9jY3MVpODLm9+RVcBG3 EG8mgbez8yIq4GOaDneX/cyA5U1MjSs2OWlh8e6B123aVyB8ihNONiPIOahUTKQVhd8Q8mWhl YhYcGWvyEaJmqoT6Cqu/hSgJuPbGo48u6DSBIZWStUiyHi21iQ4peg5pa8uuAzqh+hBt6IoXy OlfcVQ2TsBfK3803Gjsnbs/s9pCUGx8TdXMxOEjoS9pZb4wxd5lhOyR+HH9EZGUw0wqPfF7eK SXqi7wxPd576NMl8lwcpbBGeU9/TaSLquv2bH+20oGn4BsUJK7N9gUXeCuQqifPU6XFur7Yse 3bpni4TKiKwCDmVxbqKAfRoHfiXaKxFro4RTfg== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The new trace option gratuitously added a 'select TRACING' statement, which now causes build failures in other code that assumed tracepoints were only available with FTRACE: ERROR: "__tracepoint_ucsi_command" [drivers/usb/typec/ucsi/typec_ucsi.ko] undefined! ERROR: "__tracepoint_ucsi_register_port" [drivers/usb/typec/ucsi/typec_ucsi.ko] undefined! ERROR: "__tracepoint_ucsi_notify" [drivers/usb/typec/ucsi/typec_ucsi.ko] undefined! ERROR: "__tracepoint_ucsi_reset_ppm" [drivers/usb/typec/ucsi/typec_ucsi.ko] undefined! ERROR: "__tracepoint_ucsi_run_command" [drivers/usb/typec/ucsi/typec_ucsi.ko] undefined! drivers/usb/dwc3/gadget.o: In function `__dwc3_prepare_one_trb': gadget.c:(.text+0x1c5): undefined reference to `__tracepoint_dwc3_prepare_trb' drivers/usb/dwc3/gadget.o: In function `__dwc3_cleanup_done_trbs': gadget.c:(.text+0x3f0): undefined reference to `__tracepoint_dwc3_complete_trb' drivers/usb/dwc3/gadget.o: In function `dwc3_gadget_ep_free_request': gadget.c:(.text+0x666): undefined reference to `__tracepoint_dwc3_free_request' This adds an explicit FTRACE dependency here, to ensure this is already the case. This matches what the other drivers have that select TRACING. Generally speaking, there is a bigger problem with CONFIG_DRM_I915_DEBUG though, it selects several other partially related symbols (DEBUGFS, I2C_CHARDEV, PREEMPT_COUNT, X86_MSR, etc that are each user-visible and that other symbols in turn depend on. This can easily lead to circular dependencies and should be avoided. I tried turning those all into 'depends on', which is normally a good strategy, but that seems to completely defeat the intention of CONFIG_DRM_I915_DEBUG. It might be better to just remove this completely, possibly replace it with a Kconfig fragment. Fixes: bccd3b831185 ("drm/i915: Use trace_printk to provide a death rattle for GEM") Signed-off-by: Arnd Bergmann --- drivers/gpu/drm/i915/Kconfig.debug | 2 ++ 1 file changed, 2 insertions(+) -- 2.9.0 diff --git a/drivers/gpu/drm/i915/Kconfig.debug b/drivers/gpu/drm/i915/Kconfig.debug index fa36491495b1..1a1b9732f657 100644 --- a/drivers/gpu/drm/i915/Kconfig.debug +++ b/drivers/gpu/drm/i915/Kconfig.debug @@ -18,6 +18,7 @@ config DRM_I915_WERROR config DRM_I915_DEBUG bool "Enable additional driver debugging" depends on DRM_I915 + depends on FTRACE # for DRM_I915_TRACE_GEM select DEBUG_FS select PREEMPT_COUNT select I2C_CHARDEV @@ -53,6 +54,7 @@ config DRM_I915_DEBUG_GEM config DRM_I915_TRACE_GEM bool "Insert extra ftrace output from the GEM internals" + depends on FTRACE select TRACING default n help