Re: [Xen-devel] [PATCH] cleancache: constify cleancache_ops structure
From: Julia Lawall <hidden>
Date: 2016-01-21 11:06:53
Also in:
kernel-janitors, lkml
On Thu, 21 Jan 2016, David Vrabel wrote:
On 23/12/15 21:06, Julia Lawall wrote:quoted
The cleancache_ops structure is never modified, so declare it as const. This also removes the __read_mostly declaration on the cleancache_ops variable declaration, since it seems redundant with const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <redacted> --- Not sure that the __read_mostly change is correct. Does it apply to the variable, or to what the variable points to?The variable, so...
Thanks. I'll update the patch, unless you have already fixed it. julia
quoted
--- a/mm/cleancache.c +++ b/mm/cleancache.c@@ -22,7 +22,7 @@ * cleancache_ops is set by cleancache_register_ops to contain the pointers * to the cleancache "backend" implementation functions. */ -static struct cleancache_ops *cleancache_ops __read_mostly; +static const struct cleancache_ops *cleancache_ops;...you want to retain the __read_mostly here. David -- To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
-- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>