mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
- virtio_pmem: The new virtio_pmem facility introduces a paravirtualized
persistent memory device that allows a guest VM to use DAX mechanisms to
access a host-file with host-page-cache. It arranges for MAP_SYNC to
be disabled and instead triggers a host fsync() when a 'write-cache
flush' command is sent to the virtual disk device.
- Miscellaneous small fixups.
-----BEGIN PGP SIGNATURE-----
iQIcBAABAgAGBQJdMHwpAAoJEB7SkWpmfYgCUYoP/3vcgYBAaXNksyALF0iowPoP
z4J0KoaOA1CzRFEQtCWUQa84CWj+XoSewwSeyrIkqKQvx/gghXblK+GVjVzBn0BD
hmmiKr8af4DdxfzYdEXJp65cCpIiVMaJiGr20Aj9ObwvWJb4QZbz9q7hnPt6KgiI
jVND3BpP3OERb4ZFcibdmJT5foKooMcXVG6+luVe+hc1+ZZQxJBsBaqie4brQIFq
j59NX3HfHH2fr1vVwnVH0CO4tgbgYg9wZ2EivGu6wBWvORjrr7KiSSbOYP68EBtd
lUoNps+vQtGnfXGwNzAjp1wuknrQYYh4/KMKjep7hiZD39rgyvBpbHbyynKzQCWV
REe8cXr/nwphsENvBAUBiqY999EWVIxdT2iaVaSA6K/31JQAC5AFyxVK/P2Ke1SK
rvePZ++iLQ1o4phTxQPNlVUqF9jOrFVVICGwMDqaqSkOsD9YKQdFClfOF/1ntlDz
V0bs+Y0Pe8AJCd9ESep4X+vHAWRRIb4EQIuwLaX8RJoY+r1fGye9RPthpYYzvXKp
DI2iJztFO3anzj2i9htNPUFIaiUmIhzEvG32O2If2yc5FL02hMpHPoFx6vHhe6s3
f8OJ+olsJK+/IIrV8+DHqYvhzylOYIhmRTvIxIxaNDPHkhR1i2RDQ6KKK1YZmsr8
MjAZ+Ym0GadDivs+wcM6
=uAMG
-----END PGP SIGNATURE-----
Merge tag 'libnvdimm-for-5.3' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm
Pull libnvdimm updates from Dan Williams:
"Primarily just the virtio_pmem driver:
- virtio_pmem
The new virtio_pmem facility introduces a paravirtualized
persistent memory device that allows a guest VM to use DAX
mechanisms to access a host-file with host-page-cache. It arranges
for MAP_SYNC to be disabled and instead triggers a host fsync()
when a 'write-cache flush' command is sent to the virtual disk
device.
- Miscellaneous small fixups"
* tag 'libnvdimm-for-5.3' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm:
virtio_pmem: fix sparse warning
xfs: disable map_sync for async flush
ext4: disable map_sync for async flush
dax: check synchronous mapping is supported
dm: enable synchronous dax
libnvdimm: add dax_dev sync flag
virtio-pmem: Add virtio pmem driver
libnvdimm: nd_region flush callback support
libnvdimm, namespace: Drop uuid_t implementation detail
This commit is contained in:
commit
f8c3500cd1
23 changed files with 508 additions and 38 deletions
|
|
@ -388,7 +388,7 @@ struct dev_dax *__devm_create_dev_dax(struct dax_region *dax_region, int id,
|
|||
* No 'host' or dax_operations since there is no access to this
|
||||
* device outside of mmap of the resulting character device.
|
||||
*/
|
||||
dax_dev = alloc_dax(dev_dax, NULL, NULL);
|
||||
dax_dev = alloc_dax(dev_dax, NULL, NULL, DAXDEV_F_SYNC);
|
||||
if (!dax_dev)
|
||||
goto err;
|
||||
|
||||
|
|
|
|||
|
|
@ -195,6 +195,8 @@ enum dax_device_flags {
|
|||
DAXDEV_ALIVE,
|
||||
/* gate whether dax_flush() calls the low level flush routine */
|
||||
DAXDEV_WRITE_CACHE,
|
||||
/* flag to check if device supports synchronous flush */
|
||||
DAXDEV_SYNC,
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -372,6 +374,18 @@ bool dax_write_cache_enabled(struct dax_device *dax_dev)
|
|||
}
|
||||
EXPORT_SYMBOL_GPL(dax_write_cache_enabled);
|
||||
|
||||
bool __dax_synchronous(struct dax_device *dax_dev)
|
||||
{
|
||||
return test_bit(DAXDEV_SYNC, &dax_dev->flags);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(__dax_synchronous);
|
||||
|
||||
void __set_dax_synchronous(struct dax_device *dax_dev)
|
||||
{
|
||||
set_bit(DAXDEV_SYNC, &dax_dev->flags);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(__set_dax_synchronous);
|
||||
|
||||
bool dax_alive(struct dax_device *dax_dev)
|
||||
{
|
||||
lockdep_assert_held(&dax_srcu);
|
||||
|
|
@ -526,7 +540,7 @@ static void dax_add_host(struct dax_device *dax_dev, const char *host)
|
|||
}
|
||||
|
||||
struct dax_device *alloc_dax(void *private, const char *__host,
|
||||
const struct dax_operations *ops)
|
||||
const struct dax_operations *ops, unsigned long flags)
|
||||
{
|
||||
struct dax_device *dax_dev;
|
||||
const char *host;
|
||||
|
|
@ -549,6 +563,9 @@ struct dax_device *alloc_dax(void *private, const char *__host,
|
|||
dax_add_host(dax_dev, host);
|
||||
dax_dev->ops = ops;
|
||||
dax_dev->private = private;
|
||||
if (flags & DAXDEV_F_SYNC)
|
||||
set_dax_synchronous(dax_dev);
|
||||
|
||||
return dax_dev;
|
||||
|
||||
err_dev:
|
||||
|
|
|
|||
Loading…
Reference in a new issue