Skip to content

Commit

Permalink
VSOCK: Drop bogus __init annotation from vsock_init_tables()
Browse files Browse the repository at this point in the history
If gcc (e.g. 4.1.2) decides not to inline vsock_init_tables(), this will
cause a section mismatch:

WARNING: net/vmw_vsock/vsock.o(.text+0x1bc): Section mismatch in reference from the function __vsock_core_init() to the function .init.text:vsock_init_tables()
The function __vsock_core_init() references
the function __init vsock_init_tables().
This is often because __vsock_core_init lacks a __init
annotation or the annotation of vsock_init_tables is wrong.

This may cause crashes if VSOCKETS=y and VMWARE_VMCI_VSOCKETS=m.

Signed-off-by: Geert Uytterhoeven <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
geertu authored and davem330 committed Apr 25, 2013
1 parent 6ad0b2f commit 22ee3b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/vmw_vsock/af_vsock.c
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ static struct list_head vsock_bind_table[VSOCK_HASH_SIZE + 1];
static struct list_head vsock_connected_table[VSOCK_HASH_SIZE];
static DEFINE_SPINLOCK(vsock_table_lock);

static __init void vsock_init_tables(void)
static void vsock_init_tables(void)
{
int i;

Expand Down

0 comments on commit 22ee3b5

Please sign in to comment.