| Age | Commit message (Collapse) | Author | Files | Lines |
|
zcache is obsolete and not used anymore, Bob Liu has rewritten it and is
submitting it for inclusion through the main -mm tree, as it should have
been done in the first place...
Cc: Bob Liu <[email protected]>
Cc: Konrad Rzeszutek Wilk <[email protected]>
Cc: Kyungmin Park <[email protected]>
Cc: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
We want the staging fixes in here as well.
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Free sc->sc_page when releasing a struct o2net_sock_container
object to avoid memory leaks.
This issue has been fixed by Younger Liu for OCFS2, so I sync
that patch to zcache as we share the same network code base.
Cc: Younger Liu <[email protected]>
Cc: Bob Liu <[email protected]>
Cc: Greg Kroah-Hartman <[email protected]>
Cc: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Jie Liu <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Commit 835f2f5 ("staging: zcache: enable zcache to be built/loaded as
a module") introduced an incorrect handling of "zcache=" parameter.
Inside zcache_comp_init() function, zcache_comp_name variable is
checked for being empty. If not empty, the above variable is tested
for being compatible with Crypto API. Unfortunately, after that
function ends unconditionally (by the "goto out" directive) and returns:
- non-zero value if verification succeeded, wrongly indicating an error
- zero value if verification failed, falsely informing that function
zcache_comp_init() ended properly.
A solution to this problem is as following:
1. Move the "goto out" directive inside the "if (!ret)" statement
2. In case that crypto_has_comp() returned 0, change the value of ret
to non-zero before "goto out" to indicate an error.
This patch replaces an earlier one from Michal Hocko (based on report
from Cristian Rodriguez):
http://permalink.gmane.org/gmane.linux.kernel.mm/102484
It also addressed the same issue but didn't fix the zcache_comp_init()
for case when the compressor data passed to "zcache=" option was invalid
or unsupported.
Signed-off-by: Piotr Sarna <[email protected]>
[bzolnier: updated patch description]
Acked-by: Bartlomiej Zolnierkiewicz <[email protected]>
Signed-off-by: Kyungmin Park <[email protected]>
Acked-by: Konrad Rzeszutek Wilk <[email protected]>
Acked-by: Michal Hocko <[email protected]>
Cc: stable <[email protected]> # 3.10
Cc: Cristian Rodriguez <[email protected]>
Cc: Bob Liu <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Fix below compile error:
drivers/built-in.o: In function `zcache_pampd_free':
>> zcache-main.c:(.text+0xb1c8a): undefined reference to `ramster_pampd_free'
>> zcache-main.c:(.text+0xb1cbc): undefined reference to `ramster_count_foreign_pages'
drivers/built-in.o: In function `zcache_pampd_get_data_and_free':
>> zcache-main.c:(.text+0xb1f05): undefined reference to `ramster_count_foreign_pages'
drivers/built-in.o: In function `zcache_cpu_notifier':
>> zcache-main.c:(.text+0xb228d): undefined reference to `ramster_cpu_up'
>> zcache-main.c:(.text+0xb2339): undefined reference to `ramster_cpu_down'
drivers/built-in.o: In function `zcache_pampd_create':
>> (.text+0xb26ce): undefined reference to `ramster_count_foreign_pages'
drivers/built-in.o: In function `zcache_pampd_create':
>> (.text+0xb27ef): undefined reference to `ramster_count_foreign_pages'
drivers/built-in.o: In function `zcache_put_page':
>> (.text+0xb299f): undefined reference to `ramster_do_preload_flnode'
drivers/built-in.o: In function `zcache_flush_page':
>> (.text+0xb2ea3): undefined reference to `ramster_do_preload_flnode'
drivers/built-in.o: In function `zcache_flush_object':
>> (.text+0xb307c): undefined reference to `ramster_do_preload_flnode'
drivers/built-in.o: In function `zcache_init':
>> zcache-main.c:(.text+0xb3629): undefined reference to `ramster_register_pamops'
>> zcache-main.c:(.text+0xb3868): undefined reference to `ramster_init'
>> drivers/built-in.o:(.rodata+0x15058): undefined reference to `ramster_foreign_eph_pages'
>> drivers/built-in.o:(.rodata+0x15078): undefined reference to `ramster_foreign_pers_pages'
Reported-by: Fengguang Wu <[email protected]>
Signed-off-by: Bob Liu <[email protected]>
Acked-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Add how-to documentation that provides a step-by-step guide
for configuring and trying out a ramster cluster.
Signed-off-by: Dan Magenheimer <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
drivers/staging/zcache/zcache-main.c: In function ‘__check_disable_cleancache’:
drivers/staging/zcache/zcache-main.c:1928: warning: return from incompatible pointer type
drivers/staging/zcache/zcache-main.c: In function ‘__check_disable_frontswap’:
drivers/staging/zcache/zcache-main.c:1929: warning: return from incompatible pointer type
drivers/staging/zcache/zcache-main.c: In function ‘__check_disable_frontswap_ignore_nonactive’:
drivers/staging/zcache/zcache-main.c:1933: warning: return from incompatible pointer type
Signed-off-by: Geert Uytterhoeven <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Allow zcache to be built/loaded as a module. Note runtime dependency
disallows loading if cleancache/frontswap lazy initialization patches
are not present. Zsmalloc support has not yet been merged into zcache
but, once merged, could now easily be selected via a module_param.
If built-in (not built as a module), the original mechanism of enabling
via a kernel boot parameter is retained, but this should be considered
deprecated.
Note that module unload is explicitly not yet supported.
Signed-off-by: Dan Magenheimer <[email protected]>
[v1: Rebased with different order of patches]
[v2: Removed [CLEANCACHE|FRONTSWAP]_HAS_LAZY_INIT ifdef]
[v3: Rebased on top of ramster->zcache move]
[v4: Redid the Makefile]
[v5: s/ZCACHE2/ZCACHE/]
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Bob Liu <[email protected]>
Cc: Wanpeng Li <[email protected]>
Cc: Andor Daam <[email protected]>
Cc: Florian Schmaus <[email protected]>
Cc: Minchan Kim <[email protected]>
Cc: Stefan Hengelein <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
|
|
Enable module support for ramster. Note runtime dependency disallows
loading if cleancache/frontswap lazy initialization patches are not
present.
If built-in (not built as a module), the original mechanism of enabling
via a kernel boot parameter is retained, but this should be considered
deprecated.
Note that module unload is explicitly not yet supported.
[v1: Fixed compile issues since ramster_init now has four arguments]
[v2: Fixed rebase on ramster->zcache move]
[[email protected]: use_frontswap_selfshrink cannot be __initdata]
Signed-off-by: Dan Magenheimer <[email protected]>
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Bob Liu <[email protected]>
Cc: Wanpeng Li <[email protected]>
Cc: Andor Daam <[email protected]>
Cc: Florian Schmaus <[email protected]>
Cc: Minchan Kim <[email protected]>
Cc: Stefan Hengelein <[email protected]>
Cc: Wu Fengguang <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
|
|
In the past it either used to be NULL or the "older" backend. Now we
also return -Exx error codes.
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Bob Liu <[email protected]>
Cc: Wanpeng Li <[email protected]>
Cc: Andor Daam <[email protected]>
Cc: Dan Magenheimer <[email protected]>
Cc: Florian Schmaus <[email protected]>
Cc: Minchan Kim <[email protected]>
Cc: Stefan Hengelein <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
|
|
Instead of using a backend_registered to determine whether a backend is
enabled. This allows us to remove the backend_register check and just
do 'if (cleancache_ops)'
[v1: Rebase on top of b97c4b430b0a (ramster->zcache move]
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Bob Liu <[email protected]>
Cc: Wanpeng Li <[email protected]>
Cc: Andor Daam <[email protected]>
Cc: Dan Magenheimer <[email protected]>
Cc: Florian Schmaus <[email protected]>
Cc: Minchan Kim <[email protected]>
Cc: Stefan Hengelein <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
|
|
This simplifies the code in the frontswap - we can get rid of the
'backend_registered' test and instead check against frontswap_ops.
[v1: Rebase on top of 703ba7fe5e0 (ramster->zcache move]
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Bob Liu <[email protected]>
Cc: Wanpeng Li <[email protected]>
Cc: Andor Daam <[email protected]>
Cc: Dan Magenheimer <[email protected]>
Cc: Florian Schmaus <[email protected]>
Cc: Minchan Kim <[email protected]>
Cc: Stefan Hengelein <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
|
|
Fix coding style issue: ERROR: space prohibited before that '++' (ctx:WxO)
and line beyond 8 characters.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Add CONFIG_RAMSTER_DEBUG Kconfig entry.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Add incremental accessory counters that are going to be used for
debug fs entries.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Use an array to initialize/use debugfs attributes, it makes them
neater as zcache/debug.c does.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Note that at this point there is no CONFIG_RAMSTER_DEBUG
option in the Kconfig. So in effect all of the counters
are nop until that option gets introduced in patch:
ramster/debug: Add CONFIG_RAMSTER_DEBUG Kconfig entry
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
commit 9a5c59687ad ("staging: ramster: Provide accessory functions for
counter decrease") forget decrease foregin pers pages, this patch fix
it.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
This patch enables these functions to be wrapped and
can disable/enable this with CONFIG_DEBUG_FS.
Signed-off-by: Wanpeng Li <[email protected]>
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
This patch enables these functions to be wrapped and can disable/enable
this with CONFIG_DEBUG_FS.
Signed-off-by: Wanpeng Li <[email protected]>
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
zero-filled pages won't be compressed and sent to remote system. Monitor
the number ephemeral and persistent pages that Ramster has sent make no
sense. This patch skip account foregin counters against zero-filled pages.
Signed-off-by: Wanpeng Li <[email protected]>
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Cleanup TODO list since support zero-filled pages more efficiently has
already done by this patchset.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Introduce zero-filled page statistics to monitor the number of
zero-filled pages.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Reviewed-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
C files
After commit 95bdaee214 ("zcache: Move debugfs code out of zcache-main.c file")
be merged, most of knods in zcache debugfs just export zero since these variables
are defined in debug.h but are in use in multiple C files zcache-main.c and debug.c,
in this case variables can't be treated as shared variables.
Signed-off-by: Wanpeng Li <[email protected]>
Reviewed-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
commit 9c0ad59ef ("zcache/debug: Use an array to initialize/use debugfs attributes")
use an array to initialize/use debugfs attributes, .name = #x, .val = &zcache_##x.
For zcache writeback, this commit set .name = zcache_outstanding_writeback_pages and
.name = zcache_writtenback_pages seperately, however, corresponding .val =
&zcache_zcache_outstanding_writeback_pages and .val = &zcache_zcache_writtenback_pages,
which are not correct.
Signed-off-by: Wanpeng Li <[email protected]>
Reviewed-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Before commit 9c0ad59ef ("zcache/debug: Use an array to initialize/use
debugfs attributes"), pers_pageframes|_max are exported in debugfs, but
this commit forgot use array export pers_pageframes|_max. This patch add
pers_pageframes|_max back.
Signed-off-by: Wanpeng Li <[email protected]>
Reviewed-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Increment/decrement zcache_[eph|pers]_zpages for zero-filled pages,
the main point of the counters for zpages and pageframes is to be
able to calculate density == zpages/pageframes. A zero-filled page
becomes a zpage that "compresses" to zero bytes and, as a result,
requires zero pageframes for storage. So the zpages counter should
be increased but the pageframes counter should not.
[Dan Magenheimer <[email protected]>: patch description]
Acked-by: Dan Magenheimer <[email protected]>
Reviewed-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Compression of zero-filled pages can unneccessarily cause internal
fragmentation, and thus waste memory. This special case can be
optimized.
This patch captures zero-filled pages, and marks their corresponding
zcache backing page entry as zero-filled. Whenever such zero-filled
page is retrieved, we fill the page frame with zero.
Acked-by: Dan Magenheimer <[email protected]>
Reviewed-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Introduce zero-filled pages handler to capture and handle zero pages.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Fix below compile warning:
staging/zcache/zcache-main.c: In function ‘zcache_autocreate_pool’:
staging/zcache/zcache-main.c:1393:13: warning: ‘cli’ may be used uninitialized
in this function [-Wuninitialized]
Signed-off-by: Bob Liu <[email protected]>
Reviewed-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Because 'ramster_debugfs_init' is not defined if !CONFIG_DEBUG_FS, there is
compile error:
$ make drivers/staging/zcache/
staging/zcache/ramster/ramster.c: In function ‘ramster_init’:
staging/zcache/ramster/ramster.c:981:2: error: implicit declaration of
function ‘ramster_debugfs_init’ [-Werror=implicit-function-declaration]
This patch fix it and reduce some #ifdef CONFIG_DEBUG_FS in .c files the same
way.
Reported-by: Fengguang Wu <[email protected]>
Signed-off-by: Bob Liu <[email protected]>
Reviewed-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
This pulls in all of the good fixes we need here.
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
flush_dcache_page() takes a page*, not a void*. It breaks ia64.
Remove this and another unused function. Warnings remain:
drivers/staging/zcache/zcache-main.c: In function '__check_disable_cleancache':
drivers/staging/zcache/zcache-main.c:1837: warning: return from incompatible pointer type
drivers/staging/zcache/zcache-main.c: In function '__check_disable_frontswap':
drivers/staging/zcache/zcache-main.c:1838: warning: return from incompatible pointer type
drivers/staging/zcache/zcache-main.c: In function '__check_disable_frontswap_ignore_nonactive':
drivers/staging/zcache/zcache-main.c:1842: warning: return from incompatible pointer type
Cc: Dan Magenheimer <[email protected]>
Cc: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Introduce zero-filled pages handler to capture and handle zero pages.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Wanpeng Li <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Two of them (zcache DebugFS cleanup) and the module loading
capability are now in linux-next for v3.10.
Also Bob Liu is full-time going to help on knocking these items
off the list.
CC: [email protected]
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Signed-off-by: Paul Bolle <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
This resolves the merge error due to removing the ccg staging driver,
and picks up the other staging driver fixes that went into 3.9-rc3.
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
idr_get_new*() and friends are about to be deprecated. Convert to the
new idr_alloc() interface.
Only compile tested.
Signed-off-by: Tejun Heo <[email protected]>
Cc: Dan Magenheimer <[email protected]>
Acked-by: Greg Kroah-Hartman <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
|
|
for NUL terminated string, need alway set '\0' in the end.
Signed-off-by: Chen Gang <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
On PPC64 we get this:
In file included from drivers/staging/zcache/debug.c:2:
drivers/staging/zcache/debug.h: In function 'dec_zcache_obj_count':
drivers/staging/zcache/debug.h:16: error: implicit declaration of function 'BUG_ON'
This simple patch adds the appropiate header file to finish
the compile and reverts
"staging: zcache: disable ZCACHE_DEBUG due to build error"
(5db5a20a50cfd078c78b13a988f237cca81aedc5)
Reported-by: Stephen Rothwell <[email protected]>
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
In file included from drivers/staging/zcache/debug.c:2:0:
drivers/staging/zcache/debug.h: In function 'dec_zcache_obj_count':
drivers/staging/zcache/debug.h:16:2: error: implicit declaration of function 'BUG_ON' [-Werror=implicit-function-declaration]
Signed-off-by: Stephen Rothwell <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
and also define this extra attribute in the Kconfig entry.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
The other (same license) is at the end of the file.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
We now have in zcache-main only the counters that are
are not debugfs related.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
It makes it neater and also allows us to piggyback on that
in the zcache_dump function.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
Note that at this point there is no CONFIG_ZCACHE_DEBUG
option in the Kconfig. So in effect all of the counters
are nop until that option gets re-introduced in:
zcache/debug: Coalesce all debug under CONFIG_ZCACHE_DEBUG
Acked-by: Dan Magenheimer <[email protected]>
[v1: Fixed conflicts due to rebase]
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
as if you are debugging this driver you would be using 'debug'
on the command line anyhow - and this would dump the debug
data on the proper loglevel.
While at it also remove the unconditional #define ZCACHE_DEBUG.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
And now we can move the code ([inc|dec]_zcache_[*]) to their own file
with a header to make them nops or feed in debugfs.
Acked-by: Dan Magenheimer <[email protected]>
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
This way we can have all wrapped with these functions and
can disable/enable this with CONFIG_DEBUG_FS.
Acked-by: Dan Magenheimer <[email protected]>
[v2: Rebase on top of staging/zcache: Fix/improve zcache writeback code, tie to a config option]
[v3: Rebase on top of zcache: Fix compile warnings due to usage of debugfs_create_size_t]
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
|
This is the first step in moving the debugfs code out of the
main file in-to another file. And also allow the code to run
without CONFIG_DEBUG_FS defined.
Acked-by: Dan Magenheimer <[email protected]>
[v2: Rebase on top staging/zcache: Fix/improve zcache writeback code, tie to a config option]
[v3: Rebase on top of zcache: Fix compile warnings due to usage of debugfs_create_size_t]
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|