On Tue, Oct 10, 2023 at 06:04:48PM -0400, Alexander Aring wrote:
> If there is a burst of message the receive worker will filling up the
> processing queue but where are too slow to process dlm messages. This
> patch will slow down the receiver worker to keep the buffer on the
> socket layer to
On Tue, Oct 10, 2023 at 06:04:42PM -0400, Alexander Aring wrote:
> From: Christophe JAILLET
>
> 8 is not the maximum size of the suffix used when creating debugfs files.
>
> Let the compiler compute the correct size, and only give a hint about the
> longest possible string that is used.
>
>
On Tue, Oct 10, 2023 at 06:04:41PM -0400, Alexander Aring wrote:
> From: Christophe JAILLET
>
> Use sizeof(name) instead of the equivalent, but hard coded,
> DLM_LOCKSPACE_LEN + 8.
>
> This is less verbose and more future proof.
>
> Signed-off-by: Christophe JAILLET
> Signed-off-by: Alexander
On Tue, Oct 10, 2023 at 06:04:44PM -0400, Alexander Aring wrote:
> This patch will lookup existing nodes instead of always creating them
> when dlm_midcomms_addr() is called. The idea is here to create midcomms
> nodes when user space getting informed that nodes joins the cluster. This
> is the
On Tue, Oct 10, 2023 at 06:04:43PM -0400, Alexander Aring wrote:
> From: Christophe JAILLET
>
> There is no need to clear the buffer used to build the file name.
>
> snprintf() already guarantees that it is NULL terminated and such a
> (useless) precaution was not done for the first string (i.e
In case we running in a force shutdown in either midcomms or lowcomms
implementation we will make sure we reset all per midcomms node
information.
Cc: sta...@vger.kernel.org
Fixes: 63e711b08160 ("fs: dlm: create midcomms nodes when configure")
Signed-off-by: Alexander Aring
---
The idea of commit 63e711b08160 ("fs: dlm: create midcomms nodes when
configure") is to set the midcomms node lifetime when a node joins or
leaves the cluster. Currently we can hit the following warning:
[10844.611495] [ cut here ]
[10844.615913] WARNING: CPU: 4 PID: 84304
In case of an final DLM message we can't should not send an ack out
after the final message. This patch moves the ack message before the
messages will be transmitted. If it's the final message and the
receiving node turns into DLM_CLOSED state another ack messages will
being received and turning
If there is a burst of message the receive worker will filling up the
processing queue but where are too slow to process dlm messages. This
patch will slow down the receiver worker to keep the buffer on the
socket layer to tell the sender to backoff. This is done by a threshold
to get the next
From: Christophe JAILLET
Use sizeof(name) instead of the equivalent, but hard coded,
DLM_LOCKSPACE_LEN + 8.
This is less verbose and more future proof.
Signed-off-by: Christophe JAILLET
Signed-off-by: Alexander Aring
---
fs/dlm/debug_fs.c | 10 +-
1 file changed, 5 insertions(+), 5
From: Christophe JAILLET
There is no need to clear the buffer used to build the file name.
snprintf() already guarantees that it is NULL terminated and such a
(useless) precaution was not done for the first string (i.e
ls_debug_rsb_dentry)
So, save a few LoC.
Signed-off-by: Christophe JAILLET
This patch will lookup existing nodes instead of always creating them
when dlm_midcomms_addr() is called. The idea is here to create midcomms
nodes when user space getting informed that nodes joins the cluster. This
is the case when dlm_midcomms_addr() is called, however it can be called
multiple
From: Christophe JAILLET
8 is not the maximum size of the suffix used when creating debugfs files.
Let the compiler compute the correct size, and only give a hint about the
longest possible string that is used.
When building with W=1, this fixes the following warnings:
fs/dlm/debug_fs.c: In
From: Wedson Almeida Filho
This makes it harder for accidental or malicious changes to
gfs2_xattr_handlers_max at runtime.
Cc: Bob Peterson
Cc: Andreas Gruenbacher
Cc: cluster-devel@redhat.com
Signed-off-by: Wedson Almeida Filho
---
fs/gfs2/super.h | 4 ++--
fs/gfs2/xattr.c | 4 ++--
2
On Wed 20-09-23 10:12:03, Jeff Layton wrote:
> On Wed, 2023-09-20 at 14:48 +0200, Jan Kara wrote:
> > On Wed 20-09-23 06:35:18, Jeff Layton wrote:
> > > On Wed, 2023-09-20 at 12:17 +0200, Jan Kara wrote:
> > > > If I were a sysadmin, I'd rather opt for something like
> > > > finegrained timestamps
On Wed, 2023-09-20 at 16:53 +0200, Christian Brauner wrote:
> > You could put it behind an EXPERIMENTAL Kconfig option so that the
> > code stays in and can be used by the brave or foolish while it is
> > still being refined.
>
> Given that the discussion has now fully gone back to the drawing
On Wed 20-09-23 16:53:26, Christian Brauner wrote:
> > You could put it behind an EXPERIMENTAL Kconfig option so that the
> > code stays in and can be used by the brave or foolish while it is
> > still being refined.
>
> Given that the discussion has now fully gone back to the drawing board
> and
> You could put it behind an EXPERIMENTAL Kconfig option so that the
> code stays in and can be used by the brave or foolish while it is
> still being refined.
Given that the discussion has now fully gone back to the drawing board
and this is a regression the honest thing to do is to revert the
On Wed, 2023-09-20 at 14:48 +0200, Jan Kara wrote:
> On Wed 20-09-23 06:35:18, Jeff Layton wrote:
> > On Wed, 2023-09-20 at 12:17 +0200, Jan Kara wrote:
> > > If I were a sysadmin, I'd rather opt for something like
> > > finegrained timestamps + lazytime (if I needed the finegrained timestamps
> >
> On Sep 20, 2023, at 7:48 AM, Christian Brauner wrote:
>
While we initially thought we can do this unconditionally it turns out
that this might break existing workloads that rely on timestamps in very
specific ways and we always knew this was a possibility. Move
Jeff Layton wrote:
> > Surely this is a safe choice as it moves the responsibility to the sysadmin
> > and the cases where finegrained timestamps are required. But I kind of
> > wonder how is the sysadmin going to decide whether mgtime is safe for his
> > system or not? Because the possible
> I don't, actually. I'm just mentioning that it's possible if we find the
> mount option to be unpalatable.
Ok.
>
> > @Jan, what do you think?
> >
> > > My plan was to take a stab at doing this for a later kernel release.
> >
> > Ok.
>
> If it works out, then we may be able to eventually
On Wed 20-09-23 12:30:52, Christian Brauner wrote:
> On Wed, Sep 20, 2023 at 12:17:31PM +0200, Jan Kara wrote:
> > On Wed 20-09-23 10:41:30, Christian Brauner wrote:
> > > > > f1 was last written to *after* f2 was last written to. If the
> > > > > timestamp of f1
> > > > > is then lower than the
On Wed 20-09-23 06:35:18, Jeff Layton wrote:
> On Wed, 2023-09-20 at 12:17 +0200, Jan Kara wrote:
> > If I were a sysadmin, I'd rather opt for something like
> > finegrained timestamps + lazytime (if I needed the finegrained timestamps
> > functionality). That should avoid the IO overhead of
On Wed, 2023-09-20 at 14:08 +0200, Christian Brauner wrote:
> > I wasn't proposing to do that work for v6.6. For that, we absolutely
> > either need the mount option or to just revert the mgtime conversions.
>
> This sounds like you want me to do a full-on revert of your series but
> why? The
> I wasn't proposing to do that work for v6.6. For that, we absolutely
> either need the mount option or to just revert the mgtime conversions.
This sounds like you want me to do a full-on revert of your series but
why? The conversion and changes support an actual use-case and are fine.
It's a
> > > While we initially thought we can do this unconditionally it turns out
> > > that this might break existing workloads that rely on timestamps in very
> > > specific ways and we always knew this was a possibility. Move
> > > multi-grain timestamps behind a vfs mount option.
> >
> > Surely
On Wed, 2023-09-20 at 13:48 +0200, Christian Brauner wrote:
> > > > While we initially thought we can do this unconditionally it turns out
> > > > that this might break existing workloads that rely on timestamps in very
> > > > specific ways and we always knew this was a possibility. Move
> > > >
On Wed, Sep 20, 2023 at 12:17:31PM +0200, Jan Kara wrote:
> On Wed 20-09-23 10:41:30, Christian Brauner wrote:
> > > > f1 was last written to *after* f2 was last written to. If the timestamp
> > > > of f1
> > > > is then lower than the timestamp of f2, timestamps are fundamentally
> > > >
On Wed 20-09-23 10:41:30, Christian Brauner wrote:
> > > f1 was last written to *after* f2 was last written to. If the timestamp
> > > of f1
> > > is then lower than the timestamp of f2, timestamps are fundamentally
> > > broken.
> > >
> > > Many things in user-space depend on timestamps, such
On Tue 19-09-23 12:31:08, Jeff Layton wrote:
> On Tue, 2023-09-19 at 16:52 +0200, Bruno Haible wrote:
> > Jeff Layton wrote:
> > > I'm not sure what we can do for this test. The nap() function is making
> > > an assumption that the timestamp granularity will be constant, and that
> > > isn't
On Wed, 2023-09-20 at 12:17 +0200, Jan Kara wrote:
> On Wed 20-09-23 10:41:30, Christian Brauner wrote:
> > > > f1 was last written to *after* f2 was last written to. If the timestamp
> > > > of f1
> > > > is then lower than the timestamp of f2, timestamps are fundamentally
> > > > broken.
> > >
On Wed, 2023-09-20 at 10:41 +0200, Christian Brauner wrote:
> > > f1 was last written to *after* f2 was last written to. If the timestamp
> > > of f1
> > > is then lower than the timestamp of f2, timestamps are fundamentally
> > > broken.
> > >
> > > Many things in user-space depend on
On 2023-09-19 09:31, Jeff Layton wrote:
The typical case for make
timestamp comparisons is comparing source files vs. a build target. If
those are being written nearly simultaneously, then that could be an
issue, but is that a typical behavior?
I vaguely remember running into problems with
> > f1 was last written to *after* f2 was last written to. If the timestamp of
> > f1
> > is then lower than the timestamp of f2, timestamps are fundamentally broken.
> >
> > Many things in user-space depend on timestamps, such as build system
> > centered around 'make', but also 'find ...
On Wed, 2023-09-20 at 10:41 +0200, Christian Brauner wrote:
> > > f1 was last written to *after* f2 was last written to. If the timestamp
> > > of f1
> > > is then lower than the timestamp of f2, timestamps are fundamentally
> > > broken.
> > >
> > > Many things in user-space depend on
On Tue, 2023-09-19 at 13:10 -0700, Paul Eggert wrote:
> On 2023-09-19 09:31, Jeff Layton wrote:
> > The typical case for make
> > timestamp comparisons is comparing source files vs. a build target. If
> > those are being written nearly simultaneously, then that could be an
> > issue, but is that a
On Tue, 2023-09-19 at 16:52 +0200, Bruno Haible wrote:
> Jeff Layton wrote:
> > I'm not sure what we can do for this test. The nap() function is making
> > an assumption that the timestamp granularity will be constant, and that
> > isn't necessarily the case now.
>
> This is only of secondary
Jeff Layton wrote:
> I'm not sure what we can do for this test. The nap() function is making
> an assumption that the timestamp granularity will be constant, and that
> isn't necessarily the case now.
This is only of secondary importance, because the scenario by Jan Kara
shows a much more
On Tue, 2023-09-19 at 13:04 +0200, Jan Kara wrote:
> On Tue 19-09-23 15:05:24, Xi Ruoyao wrote:
> > On Mon, 2023-08-07 at 15:38 -0400, Jeff Layton wrote:
> > > Enable multigrain timestamps, which should ensure that there is an
> > > apparent change to the timestamp whenever it has been written
On Tue 19-09-23 15:05:24, Xi Ruoyao wrote:
> On Mon, 2023-08-07 at 15:38 -0400, Jeff Layton wrote:
> > Enable multigrain timestamps, which should ensure that there is an
> > apparent change to the timestamp whenever it has been written after
> > being actively observed via getattr.
> >
> > For
On Mon, 2023-08-07 at 15:38 -0400, Jeff Layton wrote:
> Enable multigrain timestamps, which should ensure that there is an
> apparent change to the timestamp whenever it has been written after
> being actively observed via getattr.
>
> For ext4, we only need to enable the FS_MGTIME flag.
Hi
On Wed, Sep 13, 2023 at 01:00:10PM +0200, Christoph Hellwig wrote:
> > direct_write_fallback(): on error revert the ->ki_pos update from buffered
> > write
>
> Al, Christian: can you send this fix on top Linus?
Wasn't aware of this, sorry. I've picked it up and placed it with
another set of
> direct_write_fallback(): on error revert the ->ki_pos update from buffered
> write
Al, Christian: can you send this fix on top Linus?
Use new APIs to dynamically allocate the gfs2-qd shrinker.
Signed-off-by: Qi Zheng
Reviewed-by: Muchun Song
CC: Bob Peterson
CC: Andreas Gruenbacher
CC: cluster-devel@redhat.com
---
fs/gfs2/main.c | 6 +++---
fs/gfs2/quota.c | 25 +++--
fs/gfs2/quota.h | 3 ++-
3 files
Use new APIs to dynamically allocate the gfs2-glock shrinker.
Signed-off-by: Qi Zheng
Reviewed-by: Muchun Song
CC: Bob Peterson
CC: Andreas Gruenbacher
CC: cluster-devel@redhat.com
---
fs/gfs2/glock.c | 19 ++-
1 file changed, 10 insertions(+), 9 deletions(-)
diff --git
On Fri, Sep 08, 2023 at 01:29:55AM +0100, Pavel Begunkov wrote:
> On 9/3/23 23:30, Dave Chinner wrote:
> > On Wed, Aug 30, 2023 at 02:11:31PM +0800, Hao Xu wrote:
> > > On 8/29/23 19:53, Matthew Wilcox wrote:
> > > > On Tue, Aug 29, 2023 at 03:46:13PM +0800, Hao Xu wrote:
> > > > > On 8/28/23
On 9/3/23 23:30, Dave Chinner wrote:
On Wed, Aug 30, 2023 at 02:11:31PM +0800, Hao Xu wrote:
On 8/29/23 19:53, Matthew Wilcox wrote:
On Tue, Aug 29, 2023 at 03:46:13PM +0800, Hao Xu wrote:
On 8/28/23 05:32, Matthew Wilcox wrote:
On Sun, Aug 27, 2023 at 09:28:31PM +0800, Hao Xu wrote:
From:
In case we running in a force shutdown in either midcomms or lowcomms
implementation we will make sure we reset all per midcomms node
information.
Cc: sta...@vger.kernel.org
Fixes: 63e711b08160 ("fs: dlm: create midcomms nodes when configure")
Signed-off-by: Alexander Aring
---
This patch is fixing the following compiler warning when compiling with
-Wformat-truncation:
fs/dlm/debug_fs.c:1031:50: warning: '_queued_asts' directive output may
be truncated writing 12 bytes into a region of size between 8 and 72
We simple increase the additional amount of bytes to 13
The idea of commit 63e711b08160 ("fs: dlm: create midcomms nodes when
configure") is to set the midcomms node lifetime when a node joins or
leaves the cluster. Currently we can hit the following warning:
[10844.611495] [ cut here ]
[10844.615913] WARNING: CPU: 4 PID: 84304
If there is a burst of message the receive worker will filling up the
processing queue but where are too slow to process dlm messages. This
patch will slow down the receiver worker to keep the buffer on the
socket layer to tell the sender to backoff. This is done by a threshold
to get the next
This patch will lookup existing nodes instead of always creating them
when dlm_midcomms_addr() is called. The idea is here to create midcomms
nodes when user space getting informed that nodes joins the cluster. This
is the case when dlm_midcomms_addr() is called, however it can be called
multiple
In case of an final DLM message we can't should not send an ack out
after the final message. This patch moves the ack message before the
messages will be transmitted. If it's the final message and the
receiving node turns into DLM_CLOSED state another ack messages will
being received and turning
On Thu, Aug 31, 2023 at 10:57:49AM +0100, Andrew Price wrote:
> The new gfs2@ list will also be used for dlm development.
>
> Signed-off-by: Andrew Price
Ack, thanks.
> ---
> MAINTAINERS | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/MAINTAINERS b/MAINTAINERS
>
On Sun, Aug 27, 2023 at 09:28:31PM +0800, Hao Xu wrote:
> From: Hao Xu
>
> Add a boolean parameter for file_accessed() to support nowait semantics.
> Currently it is true only with io_uring as its initial caller.
>
> Signed-off-by: Hao Xu
> ---
> arch/s390/hypfs/inode.c | 2 +-
> block/fops.c
On Sun, Aug 27, 2023 at 09:28:24PM +0800, Hao Xu wrote:
For the future it would be helpful to hold of on sending larger series
that like this until a stable tag is out.
Right now this series is generating a bunch of merge conflicts because
of all the changes to relevant codepaths that got
On Sun, Aug 27, 2023 at 09:28:34PM +0800, Hao Xu wrote:
> From: Hao Xu
>
> Trylock inode->i_rwsem in iterate_dir() to support nowait semantics and
> error out -EAGAIN when there is contention.
>
> Signed-off-by: Hao Xu
> ---
Unreviewable until you rebased on -rc1 as far as I'm concerned
On Sun, Aug 27, 2023 at 09:28:26PM +0800, Hao Xu wrote:
> From: Hao Xu
>
> Implement NOWAIT semantics for readdir. Return EAGAIN error to the
> caller if it would block, like failing to get locks, or going to
> do IO.
>
> Co-developed-by: Dave Chinner
Not really.
"Co-developed" implies equal
On Wed, Aug 30, 2023 at 02:11:31PM +0800, Hao Xu wrote:
> On 8/29/23 19:53, Matthew Wilcox wrote:
> > On Tue, Aug 29, 2023 at 03:46:13PM +0800, Hao Xu wrote:
> > > On 8/28/23 05:32, Matthew Wilcox wrote:
> > > > On Sun, Aug 27, 2023 at 09:28:31PM +0800, Hao Xu wrote:
> > > > > From: Hao Xu
> > >
Signed-off-by: Andrew Price
---
MAINTAINERS | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/MAINTAINERS b/MAINTAINERS
index 4b8d634f3a4e..caae31fb9741 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -8725,7 +8725,7 @@ F:scripts/get_maintainer.pl
GFS2 FILE SYSTEM
M:
The new gfs2@ list will also be used for dlm development.
Signed-off-by: Andrew Price
---
MAINTAINERS | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/MAINTAINERS b/MAINTAINERS
index caae31fb9741..946fcf6c8d77 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -6093,7 +6093,7 @@
On Wed, 2023-08-30 at 08:38 -0400, Alexander Aring wrote:
> Hi,
>
> On Fri, Aug 25, 2023 at 2:18 PM Jeff Layton wrote:
> >
> > On Wed, 2023-08-23 at 17:33 -0400, Alexander Aring wrote:
> > > This patch uses the FL_SLEEP flag in struct file_lock to determine if
> > > the lock request is a
On Wed, Aug 30, 2023 at 08:32:43AM -0400, Alexander Aring wrote:
> Hi,
>
> On Fri, Aug 25, 2023 at 1:21 PM Chuck Lever wrote:
> >
> > On Wed, Aug 23, 2023 at 05:33:46PM -0400, Alexander Aring wrote:
> > > This patch reverts mostly commit 40595cdc93ed ("nfs: block notification
> > > on fs with
Hi,
On Fri, Aug 25, 2023 at 2:18 PM Jeff Layton wrote:
>
> On Wed, 2023-08-23 at 17:33 -0400, Alexander Aring wrote:
> > This patch uses the FL_SLEEP flag in struct file_lock to determine if
> > the lock request is a blocking or non-blocking request. Before dlm was
> > using IS_SETLKW() was
Hi,
On Fri, Aug 25, 2023 at 1:21 PM Chuck Lever wrote:
>
> On Wed, Aug 23, 2023 at 05:33:46PM -0400, Alexander Aring wrote:
> > This patch reverts mostly commit 40595cdc93ed ("nfs: block notification
> > on fs with its own ->lock") and introduces an EXPORT_OP_SAFE_ASYNC_LOCK
> > export flag to
Hi,
On Fri, Aug 25, 2023 at 2:10 PM Jeff Layton wrote:
>
> On Wed, 2023-08-23 at 17:33 -0400, Alexander Aring wrote:
> > This patch returns nlm_lck_blocked in nlmsvc_lock() when an asynchronous
> > lock request is pending. During testing I ran into the case with the
> > side-effects that lockd
On 8/29/23 19:53, Matthew Wilcox wrote:
On Tue, Aug 29, 2023 at 03:46:13PM +0800, Hao Xu wrote:
On 8/28/23 05:32, Matthew Wilcox wrote:
On Sun, Aug 27, 2023 at 09:28:31PM +0800, Hao Xu wrote:
From: Hao Xu
Add a boolean parameter for file_accessed() to support nowait semantics.
Currently it
On Tue, Aug 29, 2023 at 08:43:31PM -0400, Jeff Layton wrote:
> On Wed, 2023-08-30 at 01:02 +0100, Al Viro wrote:
> > On Tue, Aug 29, 2023 at 06:58:47PM -0400, Jeff Layton wrote:
> > > On Tue, 2023-08-29 at 23:44 +0100, Al Viro wrote:
> > > > On Tue, Jul 25, 2023 at 10:58:14AM -0400, Jeff Layton
On Wed, 2023-08-30 at 01:19 +0100, Al Viro wrote:
> On Wed, Jul 05, 2023 at 02:58:11PM -0400, Jeff Layton wrote:
>
> > + * POSIX mandates that the old and new parent directories have their ctime
> > and
> > + * mtime updated, and that inodes of @old_dentry and @new_dentry (if any),
> > have
> >
On Wed, 2023-08-30 at 01:02 +0100, Al Viro wrote:
> On Tue, Aug 29, 2023 at 06:58:47PM -0400, Jeff Layton wrote:
> > On Tue, 2023-08-29 at 23:44 +0100, Al Viro wrote:
> > > On Tue, Jul 25, 2023 at 10:58:14AM -0400, Jeff Layton wrote:
> > > > generic_fillattr just fills in the entire stat struct
On Wed, Jul 05, 2023 at 02:58:11PM -0400, Jeff Layton wrote:
> + * POSIX mandates that the old and new parent directories have their ctime
> and
> + * mtime updated, and that inodes of @old_dentry and @new_dentry (if any),
> have
> + * their ctime updated.
APPLICATION USAGE
Some
On Tue, Aug 29, 2023 at 06:58:47PM -0400, Jeff Layton wrote:
> On Tue, 2023-08-29 at 23:44 +0100, Al Viro wrote:
> > On Tue, Jul 25, 2023 at 10:58:14AM -0400, Jeff Layton wrote:
> > > generic_fillattr just fills in the entire stat struct indiscriminately
> > > today, copying data from the inode.
On Tue, 2023-08-29 at 23:44 +0100, Al Viro wrote:
> On Tue, Jul 25, 2023 at 10:58:14AM -0400, Jeff Layton wrote:
> > generic_fillattr just fills in the entire stat struct indiscriminately
> > today, copying data from the inode. There is at least one attribute
> > (STATX_CHANGE_COOKIE) that can
On Tue, Jul 25, 2023 at 10:58:14AM -0400, Jeff Layton wrote:
> generic_fillattr just fills in the entire stat struct indiscriminately
> today, copying data from the inode. There is at least one attribute
> (STATX_CHANGE_COOKIE) that can have side effects when it is reported,
> and we're looking at
Hi,
On Tue, Aug 29, 2023 at 12:43 AM Zorro Lang wrote:
>
> On Wed, Aug 23, 2023 at 05:08:14PM -0400, Alexander Aring wrote:
> > This patch adds generic 730 testcase. It will test on various fcntl()
>
> The generic/730 has been taken. The case number might be changed when I merge
> a patch, so
On Tue, Aug 29, 2023 at 03:41:43PM +0800, Hao Xu wrote:
> On 8/28/23 04:44, Matthew Wilcox wrote:
> > > @@ -391,10 +401,17 @@ xfs_dir2_leaf_getdents(
> > > bp = NULL;
> > > }
> > > - if (*lock_mode == 0)
> > > -
On Tue, Aug 29, 2023 at 03:46:13PM +0800, Hao Xu wrote:
> On 8/28/23 05:32, Matthew Wilcox wrote:
> > On Sun, Aug 27, 2023 at 09:28:31PM +0800, Hao Xu wrote:
> > > From: Hao Xu
> > >
> > > Add a boolean parameter for file_accessed() to support nowait semantics.
> > > Currently it is true only
From: Hao Xu
Add a boolean parameter for file_accessed() to support nowait semantics.
Currently it is true only with io_uring as its initial caller.
Signed-off-by: Hao Xu
---
arch/s390/hypfs/inode.c | 2 +-
block/fops.c| 2 +-
fs/btrfs/file.c | 2 +-
fs/btrfs/inode.c
From: Hao Xu
Choose different gfp flags to support nowait memory allocation in
_xfs_buf_alloc().
Signed-off-by: Hao Xu
---
fs/xfs/xfs_buf.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/fs/xfs/xfs_buf.c b/fs/xfs/xfs_buf.c
index 9f84bc3b802c..8b800ce28996 100644
---
From: Hao Xu
Add a nowait boolean parameter for touch_atime() to support nowait
semantics. It is true only when io_uring is the initial caller.
Signed-off-by: Hao Xu
---
fs/cachefiles/namei.c | 2 +-
fs/ecryptfs/file.c| 4 ++--
fs/inode.c| 7 ---
fs/namei.c| 4
From: Hao Xu
This causes xfstests generic/232 hung in umount process, waiting for ail
push, so I comment it for now, need some hints from xfs folks.
Not a real patch.
Signed-off-by: Hao Xu
---
fs/xfs/xfs_buf.c | 7 +++
1 file changed, 7 insertions(+)
diff --git a/fs/xfs/xfs_buf.c
From: Hao Xu
vmalloc() always succeed in 64 bit system?
Not a real patch.
Signed-off-by: Hao Xu
---
fs/xfs/xfs_log_cil.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/fs/xfs/xfs_log_cil.c b/fs/xfs/xfs_log_cil.c
index f17c1799b3c4..b31830ee36dd 100644
--- a/fs/xfs/xfs_log_cil.c
+++
From: Hao Xu
Apply trylock logic for xc_ctx_lock in xlog_cil_commit() in nowait
case and error out -EAGAIN for xlog_cil_commit().
Signed-off-by: Hao Xu
---
fs/xfs/xfs_log_cil.c | 12 ++--
fs/xfs/xfs_log_priv.h | 2 +-
fs/xfs/xfs_trans.c| 4 +++-
3 files changed, 14
From: Hao Xu
Add nowait parameter for xfs_inode_item_init() to support nowait
semantics.
Signed-off-by: Hao Xu
---
fs/xfs/libxfs/xfs_trans_inode.c | 3 ++-
fs/xfs/xfs_inode_item.c | 12
fs/xfs/xfs_inode_item.h | 3 ++-
3 files changed, 12 insertions(+), 6
On 8/28/23 04:44, Matthew Wilcox wrote:
On Sun, Aug 27, 2023 at 09:28:26PM +0800, Hao Xu wrote:
+++ b/fs/xfs/libxfs/xfs_da_btree.c
@@ -2643,16 +2643,32 @@ xfs_da_read_buf(
struct xfs_buf_map map, *mapp =
int nmap = 1;
int
From: Hao Xu
Don't sleep and wait for more space for a log ticket in
xlog_grant_head_check() when it is in nowait case.
Signed-off-by: Hao Xu
---
fs/xfs/xfs_log.c | 15 +--
1 file changed, 9 insertions(+), 6 deletions(-)
diff --git a/fs/xfs/xfs_log.c b/fs/xfs/xfs_log.c
index
From: Hao Xu
Move file_accessed() to the beginning of iterate_dir() so that we don't
need to rollback all the work done when file_accessed() returns -EAGAIN
at the end of getdents.
Signed-off-by: Hao Xu
---
fs/readdir.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git
From: Hao Xu
Implement NOWAIT semantics for readdir. Return EAGAIN error to the
caller if it would block, like failing to get locks, or going to
do IO.
Co-developed-by: Dave Chinner
Signed-off-by: Dave Chinner
Signed-off-by: Hao Xu
[fixes deadlock issue, tweak code style]
---
From: Hao Xu
Implement NOWAIT semantics for readdir. Return EAGAIN error to the
caller if it would block, like failing to get locks, or going to
do IO.
Co-developed-by: Dave Chinner
Signed-off-by: Dave Chinner
Signed-off-by: Hao Xu
[fixes deadlock issue, tweak code style]
---
From: Hao Xu
Add a vfs helper file_pos_lock_nowait() for io_uring usage. The function
have conditional nowait logic, i.e. if nowait is needed, return -EAGAIN
when trylock fails.
Signed-off-by: Hao Xu
---
fs/file.c| 13 +
include/linux/file.h | 2 ++
2 files changed,
From: Hao Xu
There are locks in xfs_trans_alloc(), spot them and apply trylock logic.
Make them return -EAGAIN when it would block. To achieve this, add
nowait parameter for those functions in the path. Besides, add a generic
transaction flag XFS_TRANS_NOWAIT to deliver nowait info.
From: Hao Xu
Move file_accessed() to the beginning of iterate_dir() so that we don't
need to rollback all the work done when file_accessed() returns -EAGAIN
at the end of getdents.
Signed-off-by: Hao Xu
---
fs/readdir.c | 7 ++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git
From: Hao Xu
XBF_TRYLOCK means we need lock but don't block on it, we can use it to
stand for not waiting for memory allcation. Rename XBF_TRYLOCK to
XBF_NOWAIT, which is more generic.
Signed-off-by: Hao Xu
---
fs/xfs/libxfs/xfs_alloc.c | 2 +-
fs/xfs/libxfs/xfs_attr_remote.c | 2 +-
On 8/28/23 05:32, Matthew Wilcox wrote:
On Sun, Aug 27, 2023 at 09:28:31PM +0800, Hao Xu wrote:
From: Hao Xu
Add a boolean parameter for file_accessed() to support nowait semantics.
Currently it is true only with io_uring as its initial caller.
So why do we need to do this as part of this
From: Hao Xu
Add comments for page allocation in nowait case in xfs_buf_find_insert()
Signed-off-by: Hao Xu
---
fs/xfs/xfs_buf.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/fs/xfs/xfs_buf.c b/fs/xfs/xfs_buf.c
index eb3cd7702545..57bdc4c5dde1 100644
--- a/fs/xfs/xfs_buf.c
+++
From: Hao Xu
Set XBF_NOWAIT for xfs_buf_read_map() if necessary.
Signed-off-by: Hao Xu
---
fs/xfs/xfs_trans_buf.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/fs/xfs/xfs_trans_buf.c b/fs/xfs/xfs_trans_buf.c
index 6549e50d852c..016371f58f26 100644
--- a/fs/xfs/xfs_trans_buf.c
+++
From: Hao Xu
support nowait for xfs_buf_item_init() and error out -EAGAIN to
_xfs_trans_bjoin() when it would block.
Signed-off-by: Hao Xu
---
fs/xfs/xfs_buf_item.c | 9 +++--
fs/xfs/xfs_buf_item.h | 2 +-
fs/xfs/xfs_buf_item_recover.c | 2 +-
fs/xfs/xfs_trans_buf.c
From: Hao Xu
Change return value of xfs_trans_ijoin() to error out -EAGAIN.
Signed-off-by: Hao Xu
---
fs/xfs/libxfs/xfs_trans_inode.c | 13 +
fs/xfs/xfs_iops.c | 4 +++-
fs/xfs/xfs_trans.h | 2 +-
3 files changed, 13 insertions(+), 6 deletions(-)
diff
From: Hao Xu
Trylock inode->i_rwsem in iterate_dir() to support nowait semantics and
error out -EAGAIN when there is contention.
Signed-off-by: Hao Xu
---
fs/readdir.c | 20 ++--
1 file changed, 14 insertions(+), 6 deletions(-)
diff --git a/fs/readdir.c b/fs/readdir.c
index
1 - 100 of 10477 matches
Mail list logo