* [PATCH RESEND] mm: Remove false WARN_ON from pagecache_isize_extended()
@ 2014-10-27 9:58 Jan Kara
2014-10-28 21:26 ` Dave Chinner
0 siblings, 1 reply; 2+ messages in thread
From: Jan Kara @ 2014-10-27 9:58 UTC (permalink / raw)
To: Ted Tso; +Cc: Dave Chinner, linux-fsdevel, Jan Kara
The WARN_ON checking whether i_mutex is held in
pagecache_isize_extended() was wrong because some filesystems (e.g.
XFS) use different locks for serialization of truncates / writes. So
just remove the check.
Signed-off-by: Jan Kara <jack@suse.cz>
---
mm/truncate.c | 1 -
1 file changed, 1 deletion(-)
Ted can you please merge this patch? I originally sent this patch in a
reply to Fengguangs report and apparently you missed it. Thanks!
diff --git a/mm/truncate.c b/mm/truncate.c
index 261eaf6e5a19..c646084e5eec 100644
--- a/mm/truncate.c
+++ b/mm/truncate.c
@@ -755,7 +755,6 @@ void pagecache_isize_extended(struct inode *inode, loff_t from, loff_t to)
struct page *page;
pgoff_t index;
- WARN_ON(!mutex_is_locked(&inode->i_mutex));
WARN_ON(to > inode->i_size);
if (from >= to || bsize == PAGE_CACHE_SIZE)
--
1.8.1.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH RESEND] mm: Remove false WARN_ON from pagecache_isize_extended()
2014-10-27 9:58 [PATCH RESEND] mm: Remove false WARN_ON from pagecache_isize_extended() Jan Kara
@ 2014-10-28 21:26 ` Dave Chinner
0 siblings, 0 replies; 2+ messages in thread
From: Dave Chinner @ 2014-10-28 21:26 UTC (permalink / raw)
To: Jan Kara; +Cc: Ted Tso, linux-fsdevel
On Mon, Oct 27, 2014 at 10:58:05AM +0100, Jan Kara wrote:
> The WARN_ON checking whether i_mutex is held in
> pagecache_isize_extended() was wrong because some filesystems (e.g.
> XFS) use different locks for serialization of truncates / writes. So
> just remove the check.
>
> Signed-off-by: Jan Kara <jack@suse.cz>
> ---
> mm/truncate.c | 1 -
> 1 file changed, 1 deletion(-)
>
> Ted can you please merge this patch? I originally sent this patch in a
> reply to Fengguangs report and apparently you missed it. Thanks!
>
> diff --git a/mm/truncate.c b/mm/truncate.c
> index 261eaf6e5a19..c646084e5eec 100644
> --- a/mm/truncate.c
> +++ b/mm/truncate.c
> @@ -755,7 +755,6 @@ void pagecache_isize_extended(struct inode *inode, loff_t from, loff_t to)
> struct page *page;
> pgoff_t index;
>
> - WARN_ON(!mutex_is_locked(&inode->i_mutex));
> WARN_ON(to > inode->i_size);
>
> if (from >= to || bsize == PAGE_CACHE_SIZE)
Jan, I'm going to pull this through the XFS tree seeing as nobody
else seems to care about it. Should be upstream by the end of the
week.
Cheers,
Dave.
--
Dave Chinner
david@fromorbit.com
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-10-28 21:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-27 9:58 [PATCH RESEND] mm: Remove false WARN_ON from pagecache_isize_extended() Jan Kara
2014-10-28 21:26 ` Dave Chinner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).