Skip to content

zram/xvmalloc: 64K page fixes and optimizations

Robert Jennings lkml 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest7 patches 10 repliesIn review
  2. v17 patches 18 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7zram/vmalloc: Correct tunings to enable use with 64K pagesdrivers/staging/zram/xvmalloc_int.h+14 -21 reply
2/7zram: Prevent overflow in logical block sizedrivers/staging/zram/zram_drv.c drivers/staging/zram/zram_drv.h+3 -11 reply
3/7zram/xvmalloc: free bit block insertion optimizationdrivers/staging/zram/xvmalloc.c+2 -01 reply
4/7zram/xvmalloc: create CONFIG_ZRAM_DEBUG for debug codedrivers/staging/zram/Kconfig drivers/staging/zram/xvmalloc.c drivers/staging/zram/zram_drv.c+16 -01 reply
5/7zram/xvmalloc: Close 32byte hole on 64bit CPUsdrivers/staging/zram/xvmalloc_int.h+2 -51 reply
6/7zram: Return zero'd pages on new readsdrivers/staging/zram/zram_drv.c+1 -11 reply
7/7zram/xvmalloc: combine duplicate block delete codedrivers/staging/zram/xvmalloc.c+31 -422 replies

Reviews trailers per patch

All 7 patches have a Reviewed-by or Acked-by.

PatchPekka EnbergNitin Gupta
1/7R-b
2/7R-b
3/7R-b
4/7R-b
5/7R-b
6/7R-b
7/7R-b A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH 0/7][v2] zram/xvmalloc: 64K page fixes and optimizations

Based on feedback this is version 2 of my patches to fix zram and the xvmalloc allocator for 64K page size kernels along with a few small zram optimizations.

I have dropped the patch to mark the device as non-rotational media as this was duplicated elsewhere. I also dropped the patch regarding caching the indices for page size allocations because gcc is quite smart.

There are two new patches at the end of this patch set. The first changes zram to return zero'd pages for reads of pages which have not been written to, this eliminates passing uninitialized pages back to user-space. The second new patch cleans up freelist pointer management and combines the two delete node functions into one common function.

The xvmalloc allocator is non-functional when running with a 64K page size. The first two patches fix 64K page related issues. [1/7] [v2] zram/vmalloc: Correct tunings to enable use with 64K pages [2/7] [v2] zram: Prevent overflow in logical block size

The next 3 patches provide some small optimizations for zram and xvmalloc.
[3/7] [v2] zram/xvmalloc: free bit block insertion optimization [4/7] [v2] zram/xvmalloc: create CONFIG_ZRAM_DEBUG for debug code [5/7] [v2] zram/xvmalloc: Close 32byte hole on 64bit CPUs

These last 2 patches are new, see the description above. [6/7] zram: Return zero'd pages on new reads [7/7] zram/xvmalloc: combine duplicate block delete code

Thanks for the helpful reviews.

Regards,
Robert Jennings