提交 6b982fcf 编写于 作者: S Seth Jennings 提交者: Konrad Rzeszutek Wilk

mm/frontswap: fix uninit'ed variable warning

Fixes uninitialized variable warning on 'type' in frontswap_shrink().
type is set before use by __frontswap_unuse_pages() called by
__frontswap_shrink() called by frontswap_shrink() before use by
try_to_unuse().
Signed-off-by: NSeth Jennings <sjenning@linux.vnet.ibm.com>
Signed-off-by: NKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
上级 1d00015e
...@@ -292,7 +292,7 @@ static int __frontswap_shrink(unsigned long target_pages, ...@@ -292,7 +292,7 @@ static int __frontswap_shrink(unsigned long target_pages,
void frontswap_shrink(unsigned long target_pages) void frontswap_shrink(unsigned long target_pages)
{ {
unsigned long pages_to_unuse = 0; unsigned long pages_to_unuse = 0;
int type, ret; int uninitialized_var(type), ret;
/* /*
* we don't want to hold swap_lock while doing a very * we don't want to hold swap_lock while doing a very
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册