[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1381837514-50660-2-git-send-email-wangkefeng.wang@huawei.com>
Date: Tue, 15 Oct 2013 19:44:57 +0800
From: Kefeng Wang <wangkefeng.wang@...wei.com>
To: <linux-kernel@...r.kernel.org>
CC: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
"David S. Miller" <davem@...emloft.net>,
Pablo Neira Ayuso <pablo@...filter.org>,
"Stephen Hemminger" <stephen@...workplumber.org>,
Johannes Berg <johannes@...solutions.net>,
"John W. Linville" <linville@...driver.com>,
Stanislaw Gruszka <sgruszka@...hat.com>,
Johannes Berg <johannes.berg@...el.com>,
Francois Romieu <romieu@...zoreil.com>,
"Ben Hutchings" <bhutchings@...arflare.com>,
Chas Williams <chas@....nrl.navy.mil>,
Marc Kleine-Budde <mkl@...gutronix.de>,
Samuel Ortiz <samuel@...tiz.org>,
Paul Mackerras <paulus@...ba.org>,
Oliver Neukum <oneukum@...e.de>,
Konrad Rzeszutek Wilk <konrad.wilk@...cle.com>,
"Boris Ostrovsky" <boris.ostrovsky@...cle.com>,
David Vrabel <david.vrabel@...rix.com>,
Rusty Russell <rusty@...tcorp.com.au>,
"Michael S. Tsirkin" <mst@...hat.com>, <netfilter@...r.kernel.org>,
<netdev@...r.kernel.org>, <linux-wireless@...r.kernel.org>,
<guohanjun@...wei.com>
Subject: [PATCH 01/18] netfilter: cleanup: delete Macro PRINTR
Macro PRINTR is only used once in nfnetlink_log.c, so it can be
replaced by helper function net_err_ratelimited().
Signed-off-by: Kefeng Wang <wangkefeng.wang@...wei.com>
---
net/netfilter/nfnetlink_log.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/net/netfilter/nfnetlink_log.c b/net/netfilter/nfnetlink_log.c
index d92cc31..8713111 100644
--- a/net/netfilter/nfnetlink_log.c
+++ b/net/netfilter/nfnetlink_log.c
@@ -47,9 +47,6 @@
#define NFULNL_QTHRESH_DEFAULT 100 /* 100 packets */
#define NFULNL_COPY_RANGE_MAX 0xFFFF /* max packet size is limited by 16-bit struct nfattr nfa_len field */
-#define PRINTR(x, args...) do { if (net_ratelimit()) \
- printk(x, ## args); } while (0);
-
struct nfulnl_instance {
struct hlist_node hlist; /* global list of instances */
spinlock_t lock;
@@ -587,7 +584,7 @@ __build_packet_message(struct nfnl_log_net *log,
return 0;
nla_put_failure:
- PRINTR(KERN_ERR "nfnetlink_log: error creating log nlmsg\n");
+ net_err_ratelimited("nfnetlink_log: error creating log nlmsg\n");
return -1;
}
--
1.8.2.1
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists