From: "Henry Ptasinski" <henryp@broadcom.com>
To: "Joe Perches" <joe@perches.com>
Cc: "Brett Rudley" <brudley@broadcom.com>,
"Greg Kroah-Hartman" <gregkh@suse.de>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"devel@driverdev.osuosl.org" <devel@driverdev.osuosl.org>,
"Dowan Kim" <dowan@broadcom.com>,
"Roland Vossen" <rvossen@broadcom.com>,
"Arend Van Spriel" <arend@broadcom.com>,
"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
"Franky (Zhenhui) Lin" <frankyl@broadcom.com>,
"Henry Ptasinski" <henryp@broadcom.com>
Subject: Re: [PATCH] staging: brcm80211: brcmfmac: Add and use dhd_dbg
Date: Wed, 18 May 2011 17:46:29 -0700 [thread overview]
Message-ID: <4DD46865.9010708@broadcom.com> (raw)
In-Reply-To: <1305765163.1745.4.camel@Joe-Laptop>
On 05/18/2011 05:32 PM, Joe Perches wrote:
> On Wed, 2011-05-18 at 15:45 -0700, Henry Ptasinski wrote:
>> On 05/18/2011 11:23 AM, Joe Perches wrote:
>>> All uses of DHD_<TYPE> macros are for debugging only.
>>> Change the multiple uses of DHD_<TYPE>((...)) to dhd_dbg(TYPE, ...)
>>> for a more consistent style.
>> I generally like this approach, but in brcmsmac we've been switching to
>> wiphy_err() and related instead. Any strong argument for one over the
>> other?
>
> These aren't described as errors but are debugging messages.
Yes, so wiphy_debug(), wiphy_info(), wiphy_notice(), etc could be used.
It's not as fine grained as the current logging mechanism, so that
would be one argument against using wiphy_*. I don't have a strong
opinion either way, just looking to see which is the generally preferred
approach in the kernel (if there is any preference).
>>> - DHD_TRACE(("%s: Enter\n", __func__));
>>> + dhd_dbg(TRACE, "%s: Enter\n", __func__);
>> I'd propose moving __func__ into the macro definition itself, which
>> would help ensure consistency (and shorten all the debug lines a bit).
>
> I think TRACE is unnecessary and can be eliminated
> and replaced by the function tracer.
>
> Not all uses use __func__.
That's just sloppiness on our part. They should all be consistent.
> I think __func__ unnecessary and it should be avoided.
If it's moved into the macro, then there's only one place to change if
you want to delete "__func__"/add it back/include it conditionally.
> Other than that, I've no objections.
>
>> Also, perhaps rename to "brcm_dbg()", "bcm_dbg()" or something like that
>> and move it into include/bcmutils.h, so brcmsmac can use it as well.
>
> Your choice.
"brcm_dbg()" seems fine to me.
- Henry
next prev parent reply other threads:[~2011-05-19 0:46 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-18 18:23 [PATCH] staging: brcm80211: brcmfmac: Add and use dhd_dbg Joe Perches
2011-05-18 21:29 ` Greg KH
2011-05-18 22:45 ` Henry Ptasinski
2011-05-19 0:32 ` Joe Perches
2011-05-19 0:46 ` Henry Ptasinski [this message]
2011-05-19 1:09 ` Joe Perches
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4DD46865.9010708@broadcom.com \
--to=henryp@broadcom.com \
--cc=arend@broadcom.com \
--cc=brudley@broadcom.com \
--cc=devel@driverdev.osuosl.org \
--cc=dowan@broadcom.com \
--cc=frankyl@broadcom.com \
--cc=gregkh@suse.de \
--cc=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=rvossen@broadcom.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.