Linux-XFS Archive on lore.kernel.org
 help / color / Atom feed
* Can we change the S_DAX flag immediately on XFS without dropping caches?
@ 2020-07-28  2:00 Li, Hao
  2020-07-28  2:20 ` Dave Chinner
  0 siblings, 1 reply; 14+ messages in thread
From: Li, Hao @ 2020-07-28  2:00 UTC (permalink / raw)
  To: linux-xfs, linux-nvdimm; +Cc: ira.weiny, Gotou, Yasunori

Hi,

I have noticed that we have to drop caches to make the changing of S_DAX
flag take effect after using chattr +x to turn on DAX for a existing
regular file. The related function is xfs_diflags_to_iflags, whose
second parameter determines whether we should set S_DAX immediately.

I can't figure out why we do this. Is this because the page caches in
address_space->i_pages are hard to deal with? I also wonder what will
happen if we set S_DAX unconditionally. Thanks!

Regards,
Hao Li



^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, back to index

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-28  2:00 Can we change the S_DAX flag immediately on XFS without dropping caches? Li, Hao
2020-07-28  2:20 ` Dave Chinner
2020-07-29  2:23   ` Yasunori Goto
2020-07-29 16:10     ` Ira Weiny
2020-07-31  9:12       ` Li, Hao
2020-08-05  8:10         ` Li, Hao
2020-08-05 15:44           ` Darrick J. Wong
2020-08-07 16:57             ` Ira Weiny
2020-07-31 10:04       ` Yasunori Goto
2020-07-29 23:21     ` Dave Chinner
2020-07-31  9:15       ` Li, Hao
2020-07-31  9:59       ` Yasunori Goto
2020-08-07 17:09         ` Ira Weiny
2020-08-18  9:16           ` Li, Hao

Linux-XFS Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-xfs/0 linux-xfs/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-xfs linux-xfs/ https://lore.kernel.org/linux-xfs \
		linux-xfs@vger.kernel.org
	public-inbox-index linux-xfs

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-xfs


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git