From mboxrd@z Thu Jan 1 00:00:00 1970 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 3CF8BC38142 for ; Fri, 20 Jan 2023 01:02:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=nU08ceTDHVI5Po0mQJsO3i9UR74O7YFT1+AHwZYmTFM=; b=w+VhxtDycoHNBa dsLCEdVLpyqvMJ7EfZrj9l+xxCoHP5N3q0INHgoa9LmBYL54kSNEV2CiN7KmWzCzuXL0R5iMvW54g 5p3sRj+XZ3XD+kcIb5chJeMBEnY45/XxFeAd5S8EGqTfqpUNocr7+g+QITY8UufMdjDKLrpz0yA03 jmymhRDK1LTHYJOle1o8xqPhvcCI0uroiiI6Nq3LaCiJgnbZn6zy2iAssGPZdrMQAhUaLUCkModid PdxAsmgqyMA+cOHheYNzmRUGBNjIoUQG73+jzfjMyVTfFy56vfmBJtuPSbvaRdyYgXbHxbsostN5z 7UNU3FAWy2s/MAdTizVQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pIfm4-007qp6-Lf; Fri, 20 Jan 2023 01:00:56 +0000 Received: from perceval.ideasonboard.com ([213.167.242.64]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pIfm1-007qnh-D1; Fri, 20 Jan 2023 01:00:54 +0000 Received: from pendragon.ideasonboard.com (213-243-189-158.bb.dnainternet.fi [213.243.189.158]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 09667514; Fri, 20 Jan 2023 02:00:50 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1674176451; bh=tUHR1lm0/GiTPaTojG05os0odntRdSE/TwVOXS1mhn4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=dF+3LpDxK/DyIVL3yWXfMQDpoa2AGbvzYy3oWKEbDRjx+Y2RXq5r9DCxSIu+68QTh 2Vlseywog6UJIKMSkZlADSlYg8pEQu0HIHMV4tKpdmN/ETM1zlH1oKzD63h5pTYBqF VZOt9sWYmFMWVtyLwPO9h24f+2zUmQThHtR12qz0= Date: Fri, 20 Jan 2023 03:00:48 +0200 From: Laurent Pinchart To: Dan Carpenter Cc: Phil Elwell , Greg Kroah-Hartman , Stefan Wahren , Umang Jain , linux-media@vger.kernel.org, linux-staging@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-rpi-kernel@lists.infradead.org, Florian Fainelli , Adrien Thierry , Dave Stevenson , Kieran Bingham , linux-kernel@vger.kernel.org Subject: Re: [RFC PATCH 0/4] Drop custom logging Message-ID: References: <20230118115810.21979-1-umang.jain@ideasonboard.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230119_170053_628030_488FE2B4 X-CRM114-Status: GOOD ( 28.49 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, Jan 20, 2023 at 02:53:17AM +0200, Laurent Pinchart wrote: > On Thu, Jan 19, 2023 at 05:37:48PM +0300, Dan Carpenter wrote: > > On Thu, Jan 19, 2023 at 02:31:50PM +0000, Phil Elwell wrote: > > > On Thu, 19 Jan 2023 at 14:25, Dan Carpenter wrote: > > > > On Thu, Jan 19, 2023 at 01:47:44PM +0000, Phil Elwell wrote: > > > > > > > I understand the desire to remove the custom logging. I don't welcome > > > > > > > the loss of flexibility that comes with such a strategy > > > > > > > > > > > > What "loss of flexibility"? You now have access to the full dynamic > > > > > > debugging facilities that all of the rest of the kernel has. What is > > > > > > lacking? > > > > > > > > > > Perhaps I've missed something, either in this patch set or the kernel > > > > > as a whole, but how is one supposed to set different logging levels on > > > > > different facilities within a driver/module, or even for the module as > > > > > a whole? > > > > > > > > Yeah. You will be still able to do that and more besides after the > > > > transition. Cleaning this up makes the code better in every way. > > > > > > > > Documentation/admin-guide/dynamic-debug-howto.rst > > > > > > Are you saying this patch set gets us to that point? > > > > Yes. The patch has some issues, but yes. > > I think I'm missing something too then. Dynamic debug provides the > ability to easily switch dev_dbg() messages on and off at runtime, but > it doesn't provide, as far as I'm aware, log levels or log categories. > > Log levels are currently used by the vchiq code to suppress messages > below a certain level. Kernel log levels are not an exact replacement, > as the messages still end up in the kernel log (except for debug > messages). > > Log categories are used to group messages in categories and control > their log level per category. As far as I know, dynamic debug doesn't > provide any such feature. After a bit more research (which I should have done before replying, sorry), it looks like dynamic debug has support for classes, which are used by, for instance, the DRM logging infrastructure (see include/drm/drm_print.h). I don't see that being wired up to dev_*() print macros though, am I missing something, or would vchiq need to keep using custom logging macros (with dynamic debug used as a backend, replacing the current custom implementation) to make use of this feature ? -- Regards, Laurent Pinchart _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel