Skip to content

Commit

Permalink
alloc_percpu: fix UP build
Browse files Browse the repository at this point in the history
Impact: build fix

the !SMP branch had a 'gfp' leftover:

 include/linux/percpu.h: In function '__alloc_percpu':
 include/linux/percpu.h:160: error: 'gfp' undeclared (first use in this function)
 include/linux/percpu.h:160: error: (Each undeclared identifier is reported only once
 include/linux/percpu.h:160: error: for each function it appears in.)

Use GFP_KERNEL like the SMP version does.

Cc: Rusty Russell <rusty@rustcorp.com.au>
Cc: Tejun Heo <tj@kernel.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Ingo Molnar committed Feb 25, 2009
1 parent 0dcec8c commit d2b0261
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/linux/percpu.h
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ static inline void *__alloc_percpu(size_t size, size_t align)
* percpu sections on SMP for which this path isn't used.
*/
WARN_ON_ONCE(align > __alignof__(unsigned long long));
return kzalloc(size, gfp);
return kzalloc(size, GFP_KERNEL);
}

static inline void free_percpu(void *p)
Expand Down

0 comments on commit d2b0261

Please sign in to comment.