[2/3] But why isn't mem_used_max writable? (save tearing down and rebuilding device to reset max) static DEVICE_ATTR(mem_used_max, S_IRUGO, mem_used_max_show, NULL); static DEVICE_ATTR(mem_used_max, S_IRUGO | S_IWUSR, mem_used_max_show, NULL); with a check in the store() that the new value is positive and less than current max? I'm also a little puzzled why there is a new API zs_get_max_size_bytes if the data is accessible through sysfs? Especially if max limit will be (as you propose for [3/3]) through accessed through zsmalloc and hence zram needn't access. [3/3] I concur that the zram limit is best implemented in zsmalloc. I am looking forward to that revised code. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>