From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takashi Iwai Subject: Re: [PATCH] ALSA: get rid of CONFIG_SND_VERBOSE_PRINTK Date: Wed, 05 Jun 2013 08:32:52 +0200 Message-ID: References: <1370375134.2385.64.camel@joe-AO722> <1370412921.2385.111.camel@joe-AO722> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 90F0F26529C for ; Wed, 5 Jun 2013 08:32:20 +0200 (CEST) In-Reply-To: <1370412921.2385.111.camel@joe-AO722> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org To: Joe Perches Cc: alsa-devel@alsa-project.org, Alan Stern List-Id: alsa-devel@alsa-project.org At Tue, 04 Jun 2013 23:15:21 -0700, Joe Perches wrote: > > On Wed, 2013-06-05 at 08:04 +0200, Takashi Iwai wrote: > > At Tue, 4 Jun 2013 16:54:12 -0400 (EDT), Alan Stern wrote: > > > On Tue, 4 Jun 2013, Joe Perches wrote: > [] > > > You didn't respond to the first point I raised. Since these messages > > > are all meant for debugging, there's no point allowing them to have > > > prefixes like KERN_ERR or KERN_INFO. They should always be printed at > > > the KERN_DEBUG level. Or did you think this was so obviously true that > > > it didn't require any comment? > > > > Unfortunately, it's not so straightforward. Many messages are better > > with KERN_INFO indeed. In such places, snd_printd() is used rather as > > snd_chattier_printk_with_prefix(). > > In those cases, it's likely true that most of those > should not be snd_printd but promoted to pr_ Yes. These are snd_printd() just to be conditionally built in. But in most cases it's rather useful to print them (as most distros set CONFIG_SND_DEBUG=y). Hence practically they can be pr_info() nowadays. > > Instead, we tended to put such informational messages as snd_printd(), > > while keeping the driver itself reticent as much as possible for > > "productive" systems. This style was kept for a while even after > > merged to 2.5 kernels until recently. > > > > Also, some places use KERN_WARNING or KERN_ERR with snd_printd(), > > mostly because they are in the context with CONFIG_SND_DEBUG. > > They can be well pr_warning() or pr_err(). > > I thought the idea was to rationalize all that with > the new printing styles. So on the whole, it seems > we are agreeing strongly. Yep, we can convert almost all snd_printk() with pr_*(), and usual snd_printd() with pr_debug(). There must be some exceptions, and they need care manually. Takashi