Re: [PATCH] trivial, memory hotplug: add kswapd_is_running() forbetter readability

From: Jiang Liu
Date: Wed Jun 20 2012 - 05:06:25 EST


> This isn't better, there's no functional change and you've just added a
> second conditional for no reason and an unnecessary kswapd_is_running()
> function.
>
> More concerning is that online_pages() doesn't check the return value of
> kswapd_run(). We should probably fail the memory hotplug operation that
> onlines a new node and doesn't have a kswapd running and cleanup after
> ourselves in online_pages() with some sane error handling.

Hi David,
Good points! Is it feasible to use schedule_delayed_work_on() to
retry kswapd_run() instead of ralling back the online operation in case
kswapd_run() failed to create the work thread?
Thank!
Gerry


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/