From nobody Thu Apr 2 20:28:14 2026 Received: from mail-oi1-f175.google.com (mail-oi1-f175.google.com [209.85.167.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6304A43C079 for ; Thu, 26 Mar 2026 18:56:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.175 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774551371; cv=none; b=lk/vF/XSy4KDpLs30OIjB6sWHdar4qd/EWrDF13grkgSRaVVeDTzLn/XkZfMp8bDPVPI/W61Z0njkwnhyuMkNIWe6u+vqkmAARqXjO5eAUdlL2CrSB+WQzBwh+MsNJ9ZE7fP2sWn6DVVIl8M8v2BXhc8Kd/JfV0sNKHsnM7pr1w= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774551371; c=relaxed/simple; bh=gdUFxE70EjDSXy6HqpqW0yTGEdO4a1TirfkhznoQiUs=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=X4OHYM//dS+614I1INU2+UxKmuWkfa47YhbIUqQ2OY94E77cyPu37rZ71RvOfnKKrlZXbEBq65k/2QQNrQK1Tk+GIGWPm5dDU+X6gsOtsFs7S6aL/+E6Lsi1RTyvnJ8g8gWOgZ2iYxJz9pocNqaYdyBPQ961ewJzrh1t3ZoskHQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=lE8uwyhM; arc=none smtp.client-ip=209.85.167.175 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="lE8uwyhM" Received: by mail-oi1-f175.google.com with SMTP id 5614622812f47-467161c4ba7so761457b6e.0 for ; Thu, 26 Mar 2026 11:56:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1774551369; x=1775156169; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=S4W3w9+Cd3LB8UtvA4xSE2rspTRatyv6KzC/l1k+Ff0=; b=lE8uwyhMhPjmyeJNXXvDdHbIZA3U4qqg8ZrPTN53lHnWd/wf+yqT5JEw6GjIszy6Fr /SSZIu5mGqCLIccaeXs34OWYQ00johFZUUVQAQIcJ9QtTBlnyeQTaqSkpysDomJE2hw0 coCHtoIRpZvE3/7pOQi6+xRwudmg4+M++VJzFwFVtluMdcLNVH+4LJfi8ink2u7O/NYR cUNrqgpWNXCaO+l4NUXNnv6fPy3fGf3Xo69CfdfItMir83GLJ52ebLxIJKsK5838RS4L Spsk+yeElywca98TsEBayXy6gEkmwlllgnai+yercIZdFdvr+qJJWLLpNoHw1Puirwnm 1WlQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1774551369; x=1775156169; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=S4W3w9+Cd3LB8UtvA4xSE2rspTRatyv6KzC/l1k+Ff0=; b=cGO0NbMnUs0e2Rw7WII7Hlh4mr5X7xLcUvUhUZLEJUopTQ1rXJg0908DTxFyFTlw77 1dZ8DVcdpb/iOI9YHHzqU4Dn5hyLKW1E+Rc+GtB9Q/53zy0rCIjL9hm0hF6dnYSfgNtc +9GY18LgJ359E6qHPw/Bldr1RRd6OiksV/yadWhNyrXvcK///sEZ4/Va1sWl0C+ekDem W1efJoL7d9/khNcQNwTOUjoPJBw6W/YarrafVBmeN0nyVjWy1BIT0+bTFOJiJfFbmt5L bSIdZFemsc5Ja2R2PVVXrcYMA7t3cwJLvIChQ722VdZ5Uz094jT+Qp+7d5jRZBkVzwuG yQXQ== X-Gm-Message-State: AOJu0YwoVj7LFUvjrfjvL/QWj1CbSYKeV+RWcXVG1GFQCN8mf6SfkG/N WNYyYzuvzxXEbzqu+iIVc+5dMYYiM3rDi+ga7UalbVL+eXvdhrCTb+cpa/iylA== X-Gm-Gg: ATEYQzzrAx+f6ITpU7jo7i9MW6XzrRL9HmGqxXjXU5+WEfktZno4Ibg9Gtr/FPBRldK cUel49dWUe9oGgKnIC27gEP19IFXol8Z5JbP4sfMLEbEUXKPSEHQvazHitSLaRbN3eClYpH5YVu wCmCObXGpS0UGLm5zTfVlaOR0tU3fSclQhovqfixtoVNo/F/JJ78IRfHegzWy4twyDveEWBRsjB ki1Z1+KflhWq1yszQ+Dk95gHao8ob5BUvHF+licOlw2P/nTyXzhiaWZvkEqp3Rc+aktAiEYUeO8 S97lViFJrR/sHSVsbMezxYiiXMpfr/QKMmzL+ryBx1YIInWYUO3N9ce2+0PCgwSiyf0oo9ZU9C/ w3iBUueT+PH9YVVre+5ObYw72Mj0R8MxKTCJ374/Wn41FnL+z8+gJxChd5jKDsPDzj57QO/MJJm LezQbIMVgQrs0hkIW9UL9vyUF+kQuv8qZsBN4MTL26a0akfxtA X-Received: by 2002:a05:6808:1807:b0:468:4b3:d12d with SMTP id 5614622812f47-46a7a88ab56mr1246480b6e.11.1774551369095; Thu, 26 Mar 2026 11:56:09 -0700 (PDT) Received: from frodo (c-98-38-17-99.hsd1.co.comcast.net. [98.38.17.99]) by smtp.googlemail.com with ESMTPSA id 586e51a60fabf-41cc7760c08sm3075171fac.4.2026.03.26.11.56.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 Mar 2026 11:56:08 -0700 (PDT) From: Jim Cromie To: linux-kernel@vger.kernel.org, airlied@gmail.com, simona@ffwll.ch, jbaron@akamai.com, gregkh@linuxfoundation.org Cc: jim.cromie@gmail.com, mripard@kernel.org, tzimmermann@suse.de, maarten.lankhorst@linux.intel.com, jani.nikula@intel.com, ville.syrjala@linux.intel.com, christian.koenig@amd.com, matthew.auld@intel.com, arunpravin.paneerselvam@amd.com, louis.chauvet@bootlin.com, skhan@linuxfoundation.org, pmladek@suse.com, ukaszb@chromium.org, dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, amd-gfx@lists.freedesktop.org Subject: [PATCH v12 64/69] drm-dyndbg: restore CONFIG_DRM_USE_DYNAMIC_DEBUG un-BROKEN Date: Thu, 26 Mar 2026 12:54:08 -0600 Message-ID: <20260326185413.1205870-65-jim.cromie@gmail.com> X-Mailer: git-send-email 2.53.0 In-Reply-To: <20260326185413.1205870-1-jim.cromie@gmail.com> References: <20260326185413.1205870-1-jim.cromie@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Time for some thorough CI. NOTE: the previous ~18 1-liner patches adding DRM_CLASSMAP_USE, can be replaced by a single call to DYNAMIC_DEBUG_CLASSMAP_USE, from a source file linked into all drm drivers & helpers. Heres how it works: 1- drm/drm_dyndbg_classmap_user.h calls the macro. This is a weird header, since it declares a record (inside an ifdef). 2. drm/Makefile: ccflags-subdir-$(DRM_USE_DYNAMIC_DEBUG) adds -include $(drm-src)/drm_dyndbg_classmap_user.h This "header" is compiled into every object file in every module 3. the DYNAMIC_DEBUG_CLASSMAP_USE macro is altered to declare the classmap-user records as __weak, and to place them into the .gnu.linkonce.d.__dyndbg_class_user.* section. This allows multiple declarations in a module to collapse to 1 record. 4. dyndbg.lds.h's MOD_DYNDBG_SECTIONS() renames the section, stripping the .gnu.linkonce.d prefix, so kernel/module/main can find the section and dyndbg can process it as before. 5. drm/Makefile: adds several ccflags-$(MODNAME)-DRM_DYNDBG_USER_SKIP definitions, this is one of the ifdefs in [1]. Its needed to break the dependency loop that is created when drm.ko depends upon itself, or when drm-quirks that it depends upon also depend on it. So this works, but it is weird (horrible, hacky, obscure, marvelous), and I dont have asbestos underwear. Signed-off-by: Jim Cromie --- drivers/gpu/drm/Kconfig.debug | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/Kconfig.debug b/drivers/gpu/drm/Kconfig.debug index 05dc43c0b8c5..6c83b1276870 100644 --- a/drivers/gpu/drm/Kconfig.debug +++ b/drivers/gpu/drm/Kconfig.debug @@ -1,7 +1,6 @@ config DRM_USE_DYNAMIC_DEBUG bool "use dynamic debug to implement drm.debug" default n - depends on BROKEN depends on DRM depends on DYNAMIC_DEBUG || DYNAMIC_DEBUG_CORE depends on JUMP_LABEL --=20 2.53.0