2021-05-06 18:44:50

by Ilya Dryomov

[permalink] [raw]
Subject: [GIT PULL] Ceph updates for 5.13-rc1

Hi Linus,

The following changes since commit 9f4ad9e425a1d3b6a34617b8ea226d56a119a717:

Linux 5.12 (2021-04-25 13:49:08 -0700)

are available in the Git repository at:

https://github.com/ceph/ceph-client.git tags/ceph-for-5.13-rc1

for you to fetch changes up to 3f1c6f2122fc780560f09735b6d1dbf39b44eb0f:

libceph: allow addrvecs with a single NONE/blank address (2021-05-04 16:06:15 +0200)

There is a merge conflict in fs/ceph/dir.c because Jeff's inode
type handling patch went through the vfs tree together with Al's
inode_wrong_type() helper. for-linus-merged has the resolution.

----------------------------------------------------------------
Notable items here are a series to take advantage of David Howells'
netfs helper library from Jeff, three new filesystem client metrics
from Xiubo, ceph.dir.rsnaps vxattr from Yanhu and two auth-related
fixes from myself, marked for stable. Interspersed is a smattering
of assorted fixes and cleanups across the filesystem.

----------------------------------------------------------------
Gustavo A. R. Silva (1):
ceph: fix fall-through warnings for Clang

Ilya Dryomov (4):
Merge remote-tracking branch 'dhowells/netfs-lib'
libceph: bump CephXAuthenticate encoding version
libceph: don't set global_id until we get an auth ticket
libceph: allow addrvecs with a single NONE/blank address

Jeff Layton (16):
ceph: rip out old fscache readpage handling
ceph: rework PageFsCache handling
ceph: fix fscache invalidation
ceph: convert ceph_readpage to netfs_readpage
ceph: convert ceph_write_begin to netfs_write_begin
ceph: convert ceph_readpages to ceph_readahead
ceph: don't clobber i_snap_caps on non-I_NEW inode
ceph: don't use d_add in ceph_handle_snapdir
ceph: use attach/detach_page_private for tracking snap context
ceph: fix kerneldoc copypasta over ceph_start_io_direct
ceph: only check pool permissions for regular files
ceph: fix inode leak on getattr error in __fh_to_dentry
ceph: drop pinned_page parameter from ceph_get_caps
ceph: convert some PAGE_SIZE invocations to thp_size()
ceph: fix up some bare fetches of i_size
ceph: don't allow access to MDS-private inodes

Xiubo Li (3):
ceph: rename the metric helpers
ceph: avoid counting the same request twice or more
ceph: send opened files/pinned caps/opened inodes metrics to MDS daemon

Yanhu Cao (1):
ceph: support getting ceph.dir.rsnaps vxattr

fs/ceph/Kconfig | 1 +
fs/ceph/addr.c | 626 +++++++++++++++++++++------------------------------
fs/ceph/cache.c | 125 ----------
fs/ceph/cache.h | 101 ++-------
fs/ceph/caps.c | 27 +--
fs/ceph/debugfs.c | 12 +-
fs/ceph/dir.c | 32 ++-
fs/ceph/export.c | 12 +-
fs/ceph/file.c | 52 ++---
fs/ceph/inode.c | 36 +--
fs/ceph/io.c | 2 +-
fs/ceph/mds_client.c | 20 +-
fs/ceph/mds_client.h | 1 +
fs/ceph/metric.c | 62 +++--
fs/ceph/metric.h | 56 ++++-
fs/ceph/snap.c | 2 +-
fs/ceph/super.h | 32 ++-
fs/ceph/xattr.c | 7 +
net/ceph/auth.c | 36 +--
net/ceph/auth_x.c | 2 +-
net/ceph/decode.c | 20 +-
21 files changed, 562 insertions(+), 702 deletions(-)


2021-05-06 23:32:41

by Linus Torvalds

[permalink] [raw]
Subject: Re: [GIT PULL] Ceph updates for 5.13-rc1

On Thu, May 6, 2021 at 7:33 AM Ilya Dryomov <[email protected]> wrote:
>
> There is a merge conflict in fs/ceph/dir.c because Jeff's inode
> type handling patch went through the vfs tree together with Al's
> inode_wrong_type() helper. for-linus-merged has the resolution.

Actually, the linux-next resolution looks wrong - or at least
unnecessary - to me.

The conversion to d_splice_alias() means that the IS_ERR() test is now
pointless, because d_splice_alias() handles an error-pointer natively,
and just returns the error back with ERR_CAST().

So the proper resolution seems to be to just drop the IS_ERR().

Adding Jeff and Al just as a heads-up.

Linus

2021-05-07 05:30:46

by Al Viro

[permalink] [raw]
Subject: Re: [GIT PULL] Ceph updates for 5.13-rc1

On Thu, May 06, 2021 at 10:51:33AM -0700, Linus Torvalds wrote:
> On Thu, May 6, 2021 at 7:33 AM Ilya Dryomov <[email protected]> wrote:
> >
> > There is a merge conflict in fs/ceph/dir.c because Jeff's inode
> > type handling patch went through the vfs tree together with Al's
> > inode_wrong_type() helper. for-linus-merged has the resolution.
>
> Actually, the linux-next resolution looks wrong - or at least
> unnecessary - to me.
>
> The conversion to d_splice_alias() means that the IS_ERR() test is now
> pointless, because d_splice_alias() handles an error-pointer natively,
> and just returns the error back with ERR_CAST().
>
> So the proper resolution seems to be to just drop the IS_ERR().

Agreed; -next resolution is not wrong per se, but it's not needed -
d_splice_alias(ERR_PTR(e), d) == ERR_PTR(e) for any e in -4095..-1,
so the variant of resolution in mainline merge will do the right thing.

2021-05-07 09:53:55

by Ilya Dryomov

[permalink] [raw]
Subject: Re: [GIT PULL] Ceph updates for 5.13-rc1

On Thu, May 6, 2021 at 7:51 PM Linus Torvalds
<[email protected]> wrote:
>
> On Thu, May 6, 2021 at 7:33 AM Ilya Dryomov <[email protected]> wrote:
> >
> > There is a merge conflict in fs/ceph/dir.c because Jeff's inode
> > type handling patch went through the vfs tree together with Al's
> > inode_wrong_type() helper. for-linus-merged has the resolution.
>
> Actually, the linux-next resolution looks wrong - or at least
> unnecessary - to me.
>
> The conversion to d_splice_alias() means that the IS_ERR() test is now
> pointless, because d_splice_alias() handles an error-pointer natively,
> and just returns the error back with ERR_CAST().
>
> So the proper resolution seems to be to just drop the IS_ERR().
>
> Adding Jeff and Al just as a heads-up.

I did it mechanically and then cross-checked against Jeff's patch:

https://lore.kernel.org/ceph-devel/[email protected]/T/#u

I guess neither Jeff nor I noticed that ERR_CAST() is redundant
because previously ceph_get_snapdir() didn't have any error handling
and the explicit check (which Jeff added in another patch that went
through Al's tree) felt "precious".

Thanks,

Ilya

2021-05-07 16:40:43

by Jeff Layton

[permalink] [raw]
Subject: Re: [GIT PULL] Ceph updates for 5.13-rc1

On Fri, 2021-05-07 at 11:03 +0200, Ilya Dryomov wrote:
> On Thu, May 6, 2021 at 7:51 PM Linus Torvalds
> <[email protected]> wrote:
> >
> > On Thu, May 6, 2021 at 7:33 AM Ilya Dryomov <[email protected]> wrote:
> > >
> > > There is a merge conflict in fs/ceph/dir.c because Jeff's inode
> > > type handling patch went through the vfs tree together with Al's
> > > inode_wrong_type() helper. for-linus-merged has the resolution.
> >
> > Actually, the linux-next resolution looks wrong - or at least
> > unnecessary - to me.
> >
> > The conversion to d_splice_alias() means that the IS_ERR() test is now
> > pointless, because d_splice_alias() handles an error-pointer natively,
> > and just returns the error back with ERR_CAST().
> >
> > So the proper resolution seems to be to just drop the IS_ERR().
> >
> > Adding Jeff and Al just as a heads-up.
>
> I did it mechanically and then cross-checked against Jeff's patch:
>
> https://lore.kernel.org/ceph-devel/[email protected]/T/#u
>
> I guess neither Jeff nor I noticed that ERR_CAST() is redundant
> because previously ceph_get_snapdir() didn't have any error handling
> and the explicit check (which Jeff added in another patch that went
> through Al's tree) felt "precious".
>

Yep, I missed that special error handling too. The final fixup looks
fine.

Cheers,
--
Jeff Layton <[email protected]>