Return-path: Received: from mail.perches.com ([173.55.12.10]:4207 "EHLO mail.perches.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751536Ab1GTWEn (ORCPT ); Wed, 20 Jul 2011 18:04:43 -0400 Subject: Re: [PATCH] rtlwifi: Convert printks to pr_ From: Joe Perches To: Larry Finger Cc: Chaoming Li , "John W. Linville" , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <4E27048F.9090004@lwfinger.net> References: <4E27048F.9090004@lwfinger.net> Content-Type: text/plain; charset="UTF-8" Date: Wed, 20 Jul 2011 15:04:42 -0700 Message-ID: <1311199482.1663.13.camel@Joe-Laptop> (sfid-20110721_000501_419702_5FEB9B9F) Mime-Version: 1.0 Sender: linux-wireless-owner@vger.kernel.org List-ID: On Wed, 2011-07-20 at 11:38 -0500, Larry Finger wrote: > On 07/20/2011 10:51 AM, Joe Perches wrote: > > Use the current logging styles. > > Add pr_fmt where appropriate. > > Remove now unnecessary prefixes from printks. > > Convert hard coded prefix to __func__. > > Add a missing "\n" to a format. [] > In general these look good, but why not define pr_fmt in rtlwifi/wifi.h. That > header is used by every source file, and you only need the define once. Because that's not the first #include in every file. The #define pr_fmt has to be before anything that includes kernel.h so it's safest/best to have it be the first thing in the file. At some point in the next year or so, all of the uses of: #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt should be removed and that should become the default. cheers, Joe