diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2010-11-14 20:40:55 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2010-11-14 20:40:55 +0000 |
commit | c3adda9fc308b06cabf2e70534905052cedb6417 (patch) | |
tree | 76a6c820ce8838f6029104fb889ee1dbd0ea6d9b /sys/sys/pcpu.h | |
parent | 31c6a0037e1a075e397e396a53a3a0822c234122 (diff) | |
download | src-c3adda9fc308b06cabf2e70534905052cedb6417.tar.gz src-c3adda9fc308b06cabf2e70534905052cedb6417.zip |
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.
Notes
Notes:
svn path=/head/; revision=215318
Diffstat (limited to 'sys/sys/pcpu.h')
-rw-r--r-- | sys/sys/pcpu.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/sys/pcpu.h b/sys/sys/pcpu.h index d18a1509dd12..81fd7833a5b3 100644 --- a/sys/sys/pcpu.h +++ b/sys/sys/pcpu.h @@ -51,9 +51,7 @@ * Define a set for pcpu data. */ extern uintptr_t *__start_set_pcpu; -__GLOBL(__start_set_pcpu); extern uintptr_t *__stop_set_pcpu; -__GLOBL(__stop_set_pcpu); /* * Array of dynamic pcpu base offsets. Indexed by id. @@ -75,7 +73,10 @@ extern uintptr_t dpcpu_off[]; */ #define DPCPU_NAME(n) pcpu_entry_##n #define DPCPU_DECLARE(t, n) extern t DPCPU_NAME(n) -#define DPCPU_DEFINE(t, n) t DPCPU_NAME(n) __section(DPCPU_SETNAME) __used +#define DPCPU_DEFINE(t, n) \ + __GLOBL("__start_" DPCPU_SETNAME); \ + __GLOBL("__stop_" DPCPU_SETNAME); \ + t DPCPU_NAME(n) __section(DPCPU_SETNAME) __used #define STATIC_DPCPU_DEFINE(t, n) \ DPCPU_DEFINE(static t, n) |