Skip to content

Commit

Permalink
mm: fix drain_local_pages function type
Browse files Browse the repository at this point in the history
Bug: 67506682
Change-Id: I6ca80f521c880589efe45dc467d494051daae015
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
  • Loading branch information
samitolvanen committed Feb 28, 2018
1 parent 0467626 commit 97d5fd2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion include/linux/gfp.h
Original file line number Diff line number Diff line change
Expand Up @@ -516,7 +516,7 @@ extern void __free_page_frag(void *addr);
void page_alloc_init(void);
void drain_zone_pages(struct zone *zone, struct per_cpu_pages *pcp);
void drain_all_pages(struct zone *zone);
void drain_local_pages(struct zone *zone);
void drain_local_pages(void *zone);

void page_alloc_init_late(void);

Expand Down
6 changes: 3 additions & 3 deletions mm/page_alloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -2341,8 +2341,9 @@ static void drain_pages(unsigned int cpu)
* The CPU has to be pinned. When zone parameter is non-NULL, spill just
* the single zone's pages.
*/
void drain_local_pages(struct zone *zone)
void drain_local_pages(void *z)
{
struct zone *zone = (struct zone *)z;
int cpu = smp_processor_id();

if (zone)
Expand Down Expand Up @@ -2402,8 +2403,7 @@ void drain_all_pages(struct zone *zone)
else
cpumask_clear_cpu(cpu, &cpus_with_pcps);
}
on_each_cpu_mask(&cpus_with_pcps, (smp_call_func_t) drain_local_pages,
zone, 1);
on_each_cpu_mask(&cpus_with_pcps, drain_local_pages, zone, 1);
}

#ifdef CONFIG_HIBERNATION
Expand Down

0 comments on commit 97d5fd2

Please sign in to comment.