[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1303406280.8857.13.camel@HP1>
Date: Thu, 21 Apr 2011 10:18:00 -0700
From: "Michael Chan" <mchan@...adcom.com>
To: "Joe Perches" <joe@...ches.com>
cc: "Matthew Carlson" <mcarlson@...adcom.com>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] tg3: Convert u32 flag,flg2,flg3 uses to bitmap
On Wed, 2011-04-20 at 23:39 -0700, Joe Perches wrote:
> @@ -4622,7 +4611,7 @@ static void tg3_tx_recover(struct tg3 *tp)
> "and include system chipset information.\n");
>
> spin_lock(&tp->lock);
> - tp->tg3_flags |= TG3_FLAG_TX_RECOVERY_PENDING;
> + tg3_flag_set(tp, TX_RECOVERY_PENDING);
> spin_unlock(&tp->lock);
> }
>
By using set_bit() now, we can eliminate the spin_lock() here. This
flag is checked much later when tg3_reset_task() is scheduled to run in
workqueue, so no memory barrier is needed either.
Thanks.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists