diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2010-11-22 19:32:54 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2010-11-22 19:32:54 +0000 |
commit | 3e288e623846fab91d923dd651b263d4696fd814 (patch) | |
tree | ddc86814ee8f35466e619bb63b8f15b41185074e /sys/netgraph | |
parent | 42298a2e4a7825de8a516c970761ac6e6562b0d9 (diff) | |
download | src-3e288e623846fab91d923dd651b263d4696fd814.tar.gz src-3e288e623846fab91d923dd651b263d4696fd814.zip |
After some off-list discussion, revert a number of changes to the
DPCPU_DEFINE and VNET_DEFINE macros, as these cause problems for various
people working on the affected files. A better long-term solution is
still being considered. This reversal may give some modules empty
set_pcpu or set_vnet sections, but these are harmless.
Changes reverted:
------------------------------------------------------------------------
r215318 | dim | 2010-11-14 21:40:55 +0100 (Sun, 14 Nov 2010) | 4 lines
Instead of unconditionally emitting .globl's for the __start_set_xxx and
__stop_set_xxx symbols, only emit them when the set_vnet or set_pcpu
sections are actually defined.
------------------------------------------------------------------------
r215317 | dim | 2010-11-14 21:38:11 +0100 (Sun, 14 Nov 2010) | 3 lines
Apply the STATIC_VNET_DEFINE and STATIC_DPCPU_DEFINE macros throughout
the tree.
------------------------------------------------------------------------
r215316 | dim | 2010-11-14 21:23:02 +0100 (Sun, 14 Nov 2010) | 2 lines
Add macros to define static instances of VNET_DEFINE and DPCPU_DEFINE.
Notes
Notes:
svn path=/head/; revision=215701
Diffstat (limited to 'sys/netgraph')
-rw-r--r-- | sys/netgraph/ng_base.c | 6 | ||||
-rw-r--r-- | sys/netgraph/ng_eiface.c | 2 | ||||
-rw-r--r-- | sys/netgraph/ng_iface.c | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/sys/netgraph/ng_base.c b/sys/netgraph/ng_base.c index a334ccc84b2b..dba6e75aa737 100644 --- a/sys/netgraph/ng_base.c +++ b/sys/netgraph/ng_base.c @@ -171,7 +171,7 @@ static struct mtx ng_typelist_mtx; /* Hash related definitions */ /* XXX Don't need to initialise them because it's a LIST */ -STATIC_VNET_DEFINE(LIST_HEAD(, ng_node), ng_ID_hash[NG_ID_HASH_SIZE]); +static VNET_DEFINE(LIST_HEAD(, ng_node), ng_ID_hash[NG_ID_HASH_SIZE]); #define V_ng_ID_hash VNET(ng_ID_hash) static struct mtx ng_idhash_mtx; @@ -189,7 +189,7 @@ static struct mtx ng_idhash_mtx; } \ } while (0) -STATIC_VNET_DEFINE(LIST_HEAD(, ng_node), ng_name_hash[NG_NAME_HASH_SIZE]); +static VNET_DEFINE(LIST_HEAD(, ng_node), ng_name_hash[NG_NAME_HASH_SIZE]); #define V_ng_name_hash VNET(ng_name_hash) static struct mtx ng_namehash_mtx; @@ -359,7 +359,7 @@ ng_alloc_node(void) #define TRAP_ERROR() #endif -STATIC_VNET_DEFINE(ng_ID_t, nextID) = 1; +static VNET_DEFINE(ng_ID_t, nextID) = 1; #define V_nextID VNET(nextID) #ifdef INVARIANTS diff --git a/sys/netgraph/ng_eiface.c b/sys/netgraph/ng_eiface.c index 263ffc504710..58d3e5d3a4ce 100644 --- a/sys/netgraph/ng_eiface.c +++ b/sys/netgraph/ng_eiface.c @@ -114,7 +114,7 @@ static struct ng_type typestruct = { }; NETGRAPH_INIT(eiface, &typestruct); -STATIC_VNET_DEFINE(struct unrhdr *, ng_eiface_unit); +static VNET_DEFINE(struct unrhdr *, ng_eiface_unit); #define V_ng_eiface_unit VNET(ng_eiface_unit) /************************************************************************ diff --git a/sys/netgraph/ng_iface.c b/sys/netgraph/ng_iface.c index 9ea8e1323087..03ad016c2ab2 100644 --- a/sys/netgraph/ng_iface.c +++ b/sys/netgraph/ng_iface.c @@ -210,7 +210,7 @@ static struct ng_type typestruct = { }; NETGRAPH_INIT(iface, &typestruct); -STATIC_VNET_DEFINE(struct unrhdr *, ng_iface_unit); +static VNET_DEFINE(struct unrhdr *, ng_iface_unit); #define V_ng_iface_unit VNET(ng_iface_unit) /************************************************************************ |