aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/include/linux/dax.h
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2017-01-24 23:02:09 -0800
committerDan Williams <dan.j.williams@intel.com>2017-04-19 15:14:35 -0700
commitc1d6e828a35df524df2af277eedd1471d05e4f4c (patch)
treee0e22fcca09c7b5bb9d1c74d9e0b48da11bae8a7 /include/linux/dax.h
parentdax: introduce dax_operations (diff)
downloadwireguard-linux-c1d6e828a35df524df2af277eedd1471d05e4f4c.tar.xz
wireguard-linux-c1d6e828a35df524df2af277eedd1471d05e4f4c.zip
pmem: add dax_operations support
Setup a dax_device to have the same lifetime as the pmem block device and add a ->direct_access() method that is equivalent to pmem_direct_access(). Once fs/dax.c has been converted to use dax_operations the old pmem_direct_access() will be removed. Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'include/linux/dax.h')
-rw-r--r--include/linux/dax.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/dax.h b/include/linux/dax.h
index 74ebb92b625a..39a0312c45c3 100644
--- a/include/linux/dax.h
+++ b/include/linux/dax.h
@@ -21,6 +21,12 @@ struct dax_operations {
int dax_read_lock(void);
void dax_read_unlock(int id);
struct dax_device *dax_get_by_host(const char *host);
+struct dax_device *alloc_dax(void *private, const char *host,
+ const struct dax_operations *ops);
+void put_dax(struct dax_device *dax_dev);
+bool dax_alive(struct dax_device *dax_dev);
+void kill_dax(struct dax_device *dax_dev);
+void *dax_get_private(struct dax_device *dax_dev);
/*
* We use lowest available bit in exceptional entry for locking, one bit for