From: David Miller <davem@davemloft.net>
To: sonic.adi@gmail.com
Cc: netdev@vger.kernel.org, uclinux-dist-devel@blackfin.uclinux.org
Subject: Re: [PATCH v3] netdev:bfin_mac: reclaim and free tx skb as soon as possible after transfer
Date: Mon, 07 Jun 2010 21:22:38 -0700 (PDT) [thread overview]
Message-ID: <20100607.212238.209978119.davem@davemloft.net> (raw)
In-Reply-To: <1275907104.9082.1.camel@eight.analog.com>
From: sonic zhang <sonic.adi@gmail.com>
Date: Mon, 7 Jun 2010 18:38:24 +0800
>
> + if (timer_pending(&lp->tx_reclaim_timer))
> + del_timer(&(lp->tx_reclaim_timer));
> +
Please remove the excess parenthesis around lp->tx_reclaim_timer being
passed to del_timer().
Also, you can unconditionally call del_timer(). If the timer isn't running
the call won't do anything.
But you have to do something to make sure you don't race with the code that
enables the timer, f.e. what keeps the timer from being scheduled right
after you make this del_timer() call?
next prev parent reply other threads:[~2010-06-08 4:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-07 10:38 [PATCH v3] netdev:bfin_mac: reclaim and free tx skb as soon as possible after transfer sonic zhang
2010-06-08 4:22 ` David Miller [this message]
[not found] ` <20100607.212238.209978119.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
2010-06-10 9:44 ` Sonic Zhang
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=20100607.212238.209978119.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=sonic.adi@gmail.com \
--cc=uclinux-dist-devel@blackfin.uclinux.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).