On Tue, Jul 25, 2017 at 01:43:27PM -0700, Dan Williams wrote:
On Tue, Jul 25, 2017 at 12:43 PM, Vivek Goyal
> Right now, dm_dax_flush() is not being called and I think it is not being
> called becuase DAXDEV_WRITE_CACHE is not set on dm dax device.
> If underlying dax device supports write cache, set DAXDEV_WRITE_CACHE on
> dm dax device. This will get dm_dax_flush() being called.
> Signed-off-by: Vivek Goyal <vgoyal(a)redhat.com>
> drivers/dax/super.c | 5 +++++
> drivers/md/dm-table.c | 33 +++++++++++++++++++++++++++++++++
> include/linux/dax.h | 1 +
> 3 files changed, 39 insertions(+)
> diff --git a/drivers/dax/super.c b/drivers/dax/super.c
> index ce9e563e6e1d..5c5e7b9f6831 100644
> --- a/drivers/dax/super.c
> +++ b/drivers/dax/super.c
> @@ -278,6 +278,11 @@ void dax_write_cache(struct dax_device *dax_dev, bool wc)
> +bool dax_write_cache_enabled(struct dax_device *dax_dev)
> + return test_bit(DAXDEV_WRITE_CACHE, &dax_dev->flags);
We need :
...but other than that, looks good to me.
Aha, missed that. Will fix in next version.
Acked-by: Dan Williams <dan.j.williams(a)intel.com>