Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

staging: zcache: fix cleancache crash

After commit c5f5c4db3938 ("staging: zcache: fix crash on high memory
swap") cleancache crashes on the first successful get. This was caused
by a remaining virt_to_page() call in zcache_pampd_get_data_and_free()
that only gets run in the cleancache path.

The patch converts the virt_to_page() to struct page casting like was
done for other instances in c5f5c4db3938.

Signed-off-by: Seth Jennings <sjenning@linux.vnet.ibm.com>
Tested-By: Valdis Kletnieks <valdis.kletnieks@vt.edu>
Acked-by: Dan Magenheimer <dan.magenheimer@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Seth Jennings and committed by
Linus Torvalds
80976804 2838888f

+1 -1
+1 -1
drivers/staging/zcache/zcache-main.c
··· 1242 1242 int ret = 0; 1243 1243 1244 1244 BUG_ON(!is_ephemeral(pool)); 1245 - zbud_decompress(virt_to_page(data), pampd); 1245 + zbud_decompress((struct page *)(data), pampd); 1246 1246 zbud_free_and_delist((struct zbud_hdr *)pampd); 1247 1247 atomic_dec(&zcache_curr_eph_pampd_count); 1248 1248 return ret;