Source
x
static void tmem_cleancache_flush_inode(int pool, struct cleancache_filekey key)
// SPDX-License-Identifier: GPL-2.0-only
/*
* Xen implementation for transcendent memory (tmem)
*
* Copyright (C) 2009-2011 Oracle Corp. All rights reserved.
* Author: Dan Magenheimer
*/
bool __read_mostly tmem_enabled = false;
static int __init enable_tmem(char *s)
{
tmem_enabled = true;
return 1;
}
__setup("tmem", enable_tmem);
static bool cleancache __read_mostly = true;
module_param(cleancache, bool, S_IRUGO);
static bool selfballooning __read_mostly = true;
module_param(selfballooning, bool, S_IRUGO);
/* CONFIG_CLEANCACHE */
static bool frontswap __read_mostly = true;
module_param(frontswap, bool, S_IRUGO);
/* CONFIG_FRONTSWAP */
/* CONFIG_FRONTSWAP */
static bool selfshrinking __read_mostly = true;
module_param(selfshrinking, bool, S_IRUGO);
/* CONFIG_XEN_SELFBALLOONING */
/* Bits for HYPERVISOR_tmem_op(TMEM_NEW_POOL) */
struct tmem_pool_uuid {
u64 uuid_lo;
u64 uuid_hi;
};
struct tmem_oid {
u64 oid[3];
};
/* flags for tmem_ops.new_pool */
/* xen tmem foundation ops/hypercalls */
static inline int xen_tmem_op(u32 tmem_cmd, u32 tmem_pool, struct tmem_oid oid,