Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933636AbbELUUb (ORCPT ); Tue, 12 May 2015 16:20:31 -0400 Received: from mail-la0-f51.google.com ([209.85.215.51]:32995 "EHLO mail-la0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752614AbbELUUa (ORCPT ); Tue, 12 May 2015 16:20:30 -0400 Message-ID: <5552608A.9020100@gmail.com> Date: Tue, 12 May 2015 22:20:26 +0200 From: Mateusz Kulikowski User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 MIME-Version: 1.0 To: Joe Perches CC: gregkh@linuxfoundation.org, dan.carpenter@oracle.com, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 20/33] staging: rtl8192e: Fix PREFER_PR_LEVEL warnings References: <1431206361-13736-1-git-send-email-mateusz.kulikowski@gmail.com> <1431206361-13736-21-git-send-email-mateusz.kulikowski@gmail.com> <1431211075.22450.83.camel@perches.com> In-Reply-To: <1431211075.22450.83.camel@perches.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1692 Lines: 43 On 10.05.2015 00:37, Joe Perches wrote: > On Sat, 2015-05-09 at 23:19 +0200, Mateusz Kulikowski wrote: >> Fix most of remaining PREFER_PR_LEVEL warnings in rtllib. >> Replace printk() with netdev_* if possible, pr_* in other cases. >> All pr_* use __func__ to easily trace message back to rtllib > > It's more common to use %s: and not %s(): > but it's generally even better not to use these > at all and use dynamic_debug to add the function > name when desired. I wasn't aware of that - thanks for the tip. In that case I'll throw away function names in all _dbg messages for v4. >> diff --git a/drivers/staging/rtl8192e/rtllib_crypt_ccmp.c b/drivers/staging/rtl8192e/rtllib_crypt_ccmp.c (...) >> hdr = (struct rtllib_hdr_4addr *) skb->data; >> - printk(KERN_DEBUG >> - "%s: Michael MIC verification failed for MSDU from %pM keyidx=%d\n", >> - skb->dev ? skb->dev->name : "N/A", hdr->addr2, >> - keyidx); >> - printk(KERN_DEBUG "%d\n", >> - memcmp(mic, skb->data + skb->len - 8, 8) != 0); >> + pr_debug("%s: Michael MIC verification failed for MSDU from %pM keyidx=%d\n", >> + skb->dev ? skb->dev->name : "N/A", hdr->addr2, >> + keyidx); > > Not that it's necessary, but are this and below > missing __func__? It prints device name in an awkward way - I must missed this one during review as it is the place where netdev_dbg() should be used. Will do it the right way in v4. Regards, Mateusz -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/