| To: | kiran@xxxxxxxxxx |
|---|---|
| Subject: | Re: [patch] Convert sockets_in_use to use per_cpu areas |
| From: | "David S. Miller" <davem@xxxxxxxxxx> |
| Date: | Mon, 23 Dec 2002 12:16:32 -0800 (PST) |
| Cc: | netdev@xxxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx |
| In-reply-to: | <20021223190847.G23413@in.ibm.com> |
| References: | <20021223190847.G23413@in.ibm.com> |
| Sender: | netdev-bounce@xxxxxxxxxxx |
From: Ravikiran G Thirumalai <kiran@xxxxxxxxxx>
Date: Mon, 23 Dec 2002 19:08:48 +0530
-static union {
- int counter;
- char __pad[SMP_CACHE_BYTES];
-} sockets_in_use[NR_CPUS] __cacheline_aligned = {{0}};
+static DEFINE_PER_CPU(int, sockets_in_use);
You have to provide an explicit initializer for DEFINE_PER_CPU
declarations or you break some platforms with older GCC's which
otherwise won't put it into the proper section.
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Unlock Every Channel on Your New DSS Satellite System, dawn hellam |
|---|---|
| Next by Date: | Re: [patch] Convert sockets_in_use to use per_cpu areas, Chris Wedgwood |
| Previous by Thread: | [patch] Convert sockets_in_use to use per_cpu areas, Ravikiran G Thirumalai |
| Next by Thread: | Re: [patch] Convert sockets_in_use to use per_cpu areas, Chris Wedgwood |
| Indexes: | [Date] [Thread] [Top] [All Lists] |