Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 31BDFC64EC4 for ; Tue, 28 Feb 2023 20:44:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229718AbjB1Uov (ORCPT ); Tue, 28 Feb 2023 15:44:51 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33758 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229529AbjB1Uol (ORCPT ); Tue, 28 Feb 2023 15:44:41 -0500 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 17B3272BF; Tue, 28 Feb 2023 12:44:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=yE+EIds/wjormfXL1oIAYTyhaZEiJTiletVx3HkCpnE=; b=f0iRb3/eAKMHpXwMz+AYdp88HL aGAvYvu/cq2dZQcWiHxCNq9TlPGCrxG7uRLtfM9FTbZ9b3lKi5bAmyPWUGk9vVsb4iNqWSASKUFGO UeXFUCXBzWn43HBjMtGPsZlHj/8i3Q6Dm+pekeNYjwWoUUZ5uK41ETZkbOHyhigi0ptzNRslFGSoG 4PF3m6pol12cOd3B5OlzkXEHOwhZ1dNLKMulXCCrpensk9fyOLHTPgRUIoaEgp+E/vGgZbUlspQUD nkzlBxBHh/baTwh5T3wM8W7JyvrKSAqIf0RGdcByaGnBhjpYbAO4HBUqgyFOAWnw3reXh2awMlqpX r+Ate8Cg==; Received: from mcgrof by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1pX6py-00EEEO-7d; Tue, 28 Feb 2023 20:44:38 +0000 Date: Tue, 28 Feb 2023 12:44:38 -0800 From: Luis Chamberlain To: Jason Baron Cc: jim.cromie@gmail.com, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, linux-modules@vger.kernel.org, Peter Zijlstra Subject: Re: [PATCH v2 2/2] dyndbg: use the module notifier callbacks Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: Luis Chamberlain Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 28, 2023 at 02:35:02PM -0500, Jason Baron wrote: > As part of Jim Cromie's new dynamic debug classmap feature, the new code > tries to toggle a jump label from dynamic_debug_setup(). However, > dynamic_debug_setup() is called before the 'module_notify_list' notifier > chain is invoked. And jump labels are initialized via the module notifier > chain. Note this is an issue for a new feature not yet merged and doesn't > affect any existing codepaths. I think we can summarize this to "in preperation for some future work where ordering matters with respect to jump labels" or something like that. Because that is then making it specific to the future use case and creates the current justification. > We could just move dynamic_debug_setup() earlier in load_module(). But > let's instead ensure the ordering via the 'priority' in the module list > notifier. "becuase the notifier for jump labels jump_label_module_nb uses a priority of 1" or something like that would be nice to get added. > This brings dynamic debug more in line with other subsystems and > pulls code out of the core module code. This should be the main reason for this change, as explained in the commit log. A secondary benefit would be it fixes the first future bug mentioned. With those changes I can take this into modules-next to start getting this tested sooner rather than later. Luis