* [PATCH v2] overlayfs: improve ovl_get_acl
@ 2022-07-28 2:49 Yang Xu
2022-07-28 13:06 ` Miklos Szeredi
0 siblings, 1 reply; 5+ messages in thread
From: Yang Xu @ 2022-07-28 2:49 UTC (permalink / raw)
To: miklos; +Cc: linux-unionfs, brauner, Yang Xu
Provide a proper stub for the !CONFIG_FS_POSIX_ACL case.
Signed-off-by: Yang Xu <xuyang2018.jy@fujitsu.com>
---
fs/overlayfs/inode.c | 4 +++-
fs/overlayfs/overlayfs.h | 6 ++++++
2 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/fs/overlayfs/inode.c b/fs/overlayfs/inode.c
index 492eddeb481f..beef5e2ff563 100644
--- a/fs/overlayfs/inode.c
+++ b/fs/overlayfs/inode.c
@@ -454,13 +454,14 @@ ssize_t ovl_listxattr(struct dentry *dentry, char *list, size_t size)
return res;
}
+#ifdef CONFIG_FS_POSIX_ACL
struct posix_acl *ovl_get_acl(struct inode *inode, int type, bool rcu)
{
struct inode *realinode = ovl_inode_real(inode);
const struct cred *old_cred;
struct posix_acl *acl;
- if (!IS_ENABLED(CONFIG_FS_POSIX_ACL) || !IS_POSIXACL(realinode))
+ if (!IS_POSIXACL(realinode))
return NULL;
if (rcu)
@@ -472,6 +473,7 @@ struct posix_acl *ovl_get_acl(struct inode *inode, int type, bool rcu)
return acl;
}
+#endif
int ovl_update_time(struct inode *inode, struct timespec64 *ts, int flags)
{
diff --git a/fs/overlayfs/overlayfs.h b/fs/overlayfs/overlayfs.h
index 4f34b7e02eee..3d8de16a76e9 100644
--- a/fs/overlayfs/overlayfs.h
+++ b/fs/overlayfs/overlayfs.h
@@ -599,7 +599,13 @@ int ovl_xattr_set(struct dentry *dentry, struct inode *inode, const char *name,
int ovl_xattr_get(struct dentry *dentry, struct inode *inode, const char *name,
void *value, size_t size);
ssize_t ovl_listxattr(struct dentry *dentry, char *list, size_t size);
+
+#ifdef CONFIG_FS_POSIX_ACL
struct posix_acl *ovl_get_acl(struct inode *inode, int type, bool rcu);
+#else
+#define ovl_get_acl NULL
+#endif
+
int ovl_update_time(struct inode *inode, struct timespec64 *ts, int flags);
bool ovl_is_private_xattr(struct super_block *sb, const char *name);
--
2.27.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v2] overlayfs: improve ovl_get_acl
2022-07-28 2:49 [PATCH v2] overlayfs: improve ovl_get_acl Yang Xu
@ 2022-07-28 13:06 ` Miklos Szeredi
2022-07-28 14:23 ` Christian Brauner
0 siblings, 1 reply; 5+ messages in thread
From: Miklos Szeredi @ 2022-07-28 13:06 UTC (permalink / raw)
To: Yang Xu; +Cc: overlayfs, Christian Brauner
On Thu, 28 Jul 2022 at 03:48, Yang Xu <xuyang2018.jy@fujitsu.com> wrote:
>
> Provide a proper stub for the !CONFIG_FS_POSIX_ACL case.
Applied, thanks.
Miklos
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] overlayfs: improve ovl_get_acl
2022-07-28 13:06 ` Miklos Szeredi
@ 2022-07-28 14:23 ` Christian Brauner
2022-08-02 13:46 ` Miklos Szeredi
0 siblings, 1 reply; 5+ messages in thread
From: Christian Brauner @ 2022-07-28 14:23 UTC (permalink / raw)
To: Miklos Szeredi; +Cc: Yang Xu, overlayfs, Seth Forshee
On Thu, Jul 28, 2022 at 03:06:21PM +0200, Miklos Szeredi wrote:
> On Thu, 28 Jul 2022 at 03:48, Yang Xu <xuyang2018.jy@fujitsu.com> wrote:
> >
> > Provide a proper stub for the !CONFIG_FS_POSIX_ACL case.
>
> Applied, thanks.
Hey Miklos,
Just an fyi that this will likely introduce a (somewhat minor) merge
conflict with the series to fix POSIX ACLs with overlayfs on top of
idmapped layers that I mentioned to you a few weeks ago in [1].
The series is - as announced in the mail above - in [2] and been in next
for quite a while now.
It's right before the mw so ideally I wouldn't want to rebase. Let me
know if I you want me to do anything. Ideally you could probably just
wait until I sent the PR next week.
Thanks!
Christian
[1]: https://lore.kernel.org/linux-unionfs/20220713101814.d5vg3qcc2qk46vqs@wittgenstein/raw
[2]: https://git.kernel.org/pub/scm/linux/kernel/git/brauner/linux.git/log/?h=fs.idmapped.overlay.acl
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] overlayfs: improve ovl_get_acl
2022-07-28 14:23 ` Christian Brauner
@ 2022-08-02 13:46 ` Miklos Szeredi
2022-08-03 7:43 ` Christian Brauner
0 siblings, 1 reply; 5+ messages in thread
From: Miklos Szeredi @ 2022-08-02 13:46 UTC (permalink / raw)
To: Christian Brauner; +Cc: Yang Xu, overlayfs, Seth Forshee
On Thu, 28 Jul 2022 at 16:23, Christian Brauner <brauner@kernel.org> wrote:
>
> On Thu, Jul 28, 2022 at 03:06:21PM +0200, Miklos Szeredi wrote:
> > On Thu, 28 Jul 2022 at 03:48, Yang Xu <xuyang2018.jy@fujitsu.com> wrote:
> > >
> > > Provide a proper stub for the !CONFIG_FS_POSIX_ACL case.
> >
> > Applied, thanks.
>
> Hey Miklos,
>
> Just an fyi that this will likely introduce a (somewhat minor) merge
> conflict with the series to fix POSIX ACLs with overlayfs on top of
> idmapped layers that I mentioned to you a few weeks ago in [1].
>
> The series is - as announced in the mail above - in [2] and been in next
> for quite a while now.
>
> It's right before the mw so ideally I wouldn't want to rebase. Let me
> know if I you want me to do anything. Ideally you could probably just
> wait until I sent the PR next week.
Okay, thanks for the heads up.
Miklos
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] overlayfs: improve ovl_get_acl
2022-08-02 13:46 ` Miklos Szeredi
@ 2022-08-03 7:43 ` Christian Brauner
0 siblings, 0 replies; 5+ messages in thread
From: Christian Brauner @ 2022-08-03 7:43 UTC (permalink / raw)
To: Miklos Szeredi; +Cc: Yang Xu, overlayfs, Seth Forshee
On Tue, Aug 02, 2022 at 03:46:00PM +0200, Miklos Szeredi wrote:
> On Thu, 28 Jul 2022 at 16:23, Christian Brauner <brauner@kernel.org> wrote:
> >
> > On Thu, Jul 28, 2022 at 03:06:21PM +0200, Miklos Szeredi wrote:
> > > On Thu, 28 Jul 2022 at 03:48, Yang Xu <xuyang2018.jy@fujitsu.com> wrote:
> > > >
> > > > Provide a proper stub for the !CONFIG_FS_POSIX_ACL case.
> > >
> > > Applied, thanks.
> >
> > Hey Miklos,
> >
> > Just an fyi that this will likely introduce a (somewhat minor) merge
> > conflict with the series to fix POSIX ACLs with overlayfs on top of
> > idmapped layers that I mentioned to you a few weeks ago in [1].
> >
> > The series is - as announced in the mail above - in [2] and been in next
> > for quite a while now.
> >
> > It's right before the mw so ideally I wouldn't want to rebase. Let me
> > know if I you want me to do anything. Ideally you could probably just
> > wait until I sent the PR next week.
>
> Okay, thanks for the heads up.
Fyi, this has now been merged into mainline!
Thanks!
Christian
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-08-03 7:44 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-28 2:49 [PATCH v2] overlayfs: improve ovl_get_acl Yang Xu
2022-07-28 13:06 ` Miklos Szeredi
2022-07-28 14:23 ` Christian Brauner
2022-08-02 13:46 ` Miklos Szeredi
2022-08-03 7:43 ` Christian Brauner
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.