Skip to content

Commit

Permalink
Init the cpu_id of dynamic allocate fsocket_alloc when the preallocat…
Browse files Browse the repository at this point in the history
…ed mem pool is exhausted.
  • Loading branch information
gfreewind committed Jan 12, 2015
1 parent a667e4e commit a3a7b47
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions kernel/net/fastsocket/fastsocket_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ static struct socket_alloc *fsocket_alloc_socket_mem(void)

fsock_alloc = kmem_cache_alloc(fsocket_pool_cachep, GFP_KERNEL);
if (likely(fsock_alloc)) {
fsock_alloc->cpu_id = smp_processor_id();
FSOCKET_INC_STATS(FSOCKET_STATS_SOCK_ALLOC);
return &fsock_alloc->sock_alloc;
}
Expand Down

0 comments on commit a3a7b47

Please sign in to comment.