Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp318997pxf; Wed, 31 Mar 2021 04:16:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwCHCvtJYyn5PqoCSH1gNAlsG5PdSWXi2nl2oLinwBH/uJsws1FBaFNzHX3/EMiO9pkUg4z X-Received: by 2002:a05:6402:110b:: with SMTP id u11mr3156023edv.356.1617189388773; Wed, 31 Mar 2021 04:16:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1617189388; cv=none; d=google.com; s=arc-20160816; b=erFnXrmK5OUAyHpNdsATOUCNoA2GuwAyH/y1hLrG80RjDaWcn4GQTC3Gd9+kbnzGL9 Y1chCW6RCJb7R5rdii5K8XbzAmRjKyxAzuejZTTiYPfl2vTojyu+yHcX4Gt3Kd6LUfNX ea1UWDFEN6jkDonrU5IH2tvqziDjq8SKo4mnVHFWEnRUBT1STrECUMVS6yH0fpzgQTkh S/PPbTjPMPXHRRwtkmpxIbwpFFo5wzvLFauRzMVP60u37PKmkYH77yBNyFQqM+0rvUDa fLhmmXMJ2hYPpltzt+cWPiNZ2iBM9dyooS5lE2dkxp+sAWLF4ny7RSSwXt3xO3mM1Re0 TnFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=MtMi+4Q4tEVps+udksUJXSth+7hQr3K1e+KtRTBgTDs=; b=gFLqD4JN8IqNgybkWbEVLUTa0RfJQSNy9pkl9G6Po/JjJmrAm/kUvHuXiqJHyPZAv2 IdrpdMCFuZSyPTKeTYdUJgM1iYP0tzh0sHVk11L5WeLsh80G1uMt+TgemL+HeMKVGcBL rpgMUY9OpxWLMzOS7FjblcT+7o9bq/NOHLvLnyYNzdKP7eKekD/P2mv2tB4eCkMlNDtg MNbjwp2gUld1ZBHdDQkn9mXbv0MfkKKVrMCTsmIhhfC0rCjnOLa/w59taT+da3+xi94C +fwBYKX4/gC8djL1EZbQkak56vbCEEK7wY9Lq5ATsKlyLRGW/gKox6ndNMniKFwngrRE 4odA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=KM4P8eU3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id hb37si1356908ejc.81.2021.03.31.04.16.05; Wed, 31 Mar 2021 04:16:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=KM4P8eU3; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234995AbhCaLOh (ORCPT + 99 others); Wed, 31 Mar 2021 07:14:37 -0400 Received: from mail.kernel.org ([198.145.29.99]:50664 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235121AbhCaLOW (ORCPT ); Wed, 31 Mar 2021 07:14:22 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 1131461962; Wed, 31 Mar 2021 11:14:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1617189261; bh=k0yZWqJT03zeDjcD/5nMojYNQZ82/JV3oLUhtiReryQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=KM4P8eU3blcP7lf8z4TwhFLzpoOySAqOM/7J3m9CSsXz1Z4zUBmEdUbNGBcbTdYTH p5fDfpRr/bWkuKfLaRuQWn4nX7N4Yn2iIDpxV9eNQVb/4Ybf3sDEwZjqMPDLMfBu0m KBExnA/zODf/4cgTNF0+X919ktsUHjMKJoNilb8Y= Date: Wed, 31 Mar 2021 13:14:18 +0200 From: Greg KH To: Fabio Aiuto Cc: dan.carpenter@oracle.com, joe@perches.com, linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: Re: [PATCH 03/40] staging: rtl8723bs: replace RT_TRACE with public printk wrappers in core/rtw_eeprom.c Message-ID: References: <39c2cd878bc914a00e71ea988c3cacb651670822.1617183374.git.fabioaiuto83@gmail.com> <20210331105551.GB1450@agape.jhs> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210331105551.GB1450@agape.jhs> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 31, 2021 at 12:55:51PM +0200, Fabio Aiuto wrote: > On Wed, Mar 31, 2021 at 12:27:20PM +0200, Greg KH wrote: > > On Wed, Mar 31, 2021 at 11:39:31AM +0200, Fabio Aiuto wrote: > > > replace private macro RT_TRACE for tracing with in-kernel > > > pr_* printk wrappers > > > > > > Signed-off-by: Fabio Aiuto > > > --- > > > drivers/staging/rtl8723bs/core/rtw_eeprom.c | 26 ++++++++++----------- > > > 1 file changed, 13 insertions(+), 13 deletions(-) > > > > > > diff --git a/drivers/staging/rtl8723bs/core/rtw_eeprom.c b/drivers/staging/rtl8723bs/core/rtw_eeprom.c > > > index 3cbd65dee741..6176d741d60e 100644 > > > --- a/drivers/staging/rtl8723bs/core/rtw_eeprom.c > > > +++ b/drivers/staging/rtl8723bs/core/rtw_eeprom.c > > > @@ -36,7 +36,7 @@ void shift_out_bits(_adapter *padapter, u16 data, u16 count) > > > _func_enter_; > > > > > > if (padapter->bSurpriseRemoved == true) { > > > - RT_TRACE(_module_rtl871x_eeprom_c_, _drv_err_, ("padapter->bSurpriseRemoved==true")); > > > + pr_err("%s padapter->bSurpriseRemoved==true", DRIVER_PREFIX); > > > > As Dan said, this is not the same thing. You are now always printing > > out this mess, when before you were not unless you explicitly enabled > > "tracing". > > RT_TRACE is enabled if is defined the symbol DEBUG_RTL871X. It doesn't seem to be related > to tracing. DEBUG_RTL871X is never declared, is commented out in rtl8723bs/include/autoconf.h That's a good sign this is never used and should just all be removed. > that's why RT_TRACE is never printed. If we try to uncomment the symbol definition we have some > comiling errors.. What errors do you get? > > And you are sending it to the error log? > > > > And finally, drivers should never be using pr_*() for messages, they > > should be using dev_*() instead as they are a driver and have access to > > a device pointer. > > > > thanks, > > > > greg k-h > > I still wonder what's best... Just delete them all please, they are obviously not used as no one rebuilds the source just for this type of thing. thanks, greg k-h