Commit 370e6a87 authored by Michal Miroslaw's avatar Michal Miroslaw Committed by David S. Miller

[NETFILTER]: nfnetlink_log: micro-optimization: inst->skb != NULL in __nfulnl_send()

No other function calls __nfulnl_send() with inst->skb == NULL than
nfulnl_timer().
Signed-off-by: default avatarMichal Miroslaw <mirq-linux@rere.qmqm.pl>
Signed-off-by: default avatarPatrick McHardy <kaber@trash.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent f76cdcee
......@@ -360,9 +360,6 @@ __nfulnl_send(struct nfulnl_instance *inst)
{
int status;
if (!inst->skb)
return 0;
if (inst->qlen > 1)
inst->lastnlh->nlmsg_type = NLMSG_DONE;
......@@ -386,7 +383,8 @@ static void nfulnl_timer(unsigned long data)
UDEBUG("timer function called, flushing buffer\n");
spin_lock_bh(&inst->lock);
__nfulnl_send(inst);
if (inst->skb)
__nfulnl_send(inst);
spin_unlock_bh(&inst->lock);
instance_put(inst);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment