[PATCH][SRU][DISCO][EOAN] UBUNTU: SAUCE: shiftfs: setup correct s_maxbytes limit

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[PATCH][SRU][DISCO][EOAN] UBUNTU: SAUCE: shiftfs: setup correct s_maxbytes limit

Christian Brauner-3
BugLink: https://bugs.launchpad.net/bugs/1849482

Set the s_maxbytes limit to MAX_LFS_FILESIZE.
Currently shiftfs limits the maximum size for fallocate() needlessly
causing calls such as fallocate --length 2GB ./file to fail. This
limitation is arbitrary since it's not caused by the underlay but
rather by shiftfs itself capping the s_maxbytes. This causes bugs such
as the one reported in [1].

[1]: https://github.com/lxc/lxd/issues/6333
Signed-off-by: Christian Brauner <[hidden email]>
---
 fs/shiftfs.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/fs/shiftfs.c b/fs/shiftfs.c
index 55bb32b611f2..ac22a5bf5b1f 100644
--- a/fs/shiftfs.c
+++ b/fs/shiftfs.c
@@ -2057,6 +2057,7 @@ static int shiftfs_fill_super(struct super_block *sb, void *raw_data,
  inode->i_private = dentry->d_inode;
 
  sb->s_magic = SHIFTFS_MAGIC;
+ sb->s_maxbytes = MAX_LFS_FILESIZE;
  sb->s_op = &shiftfs_super_ops;
  sb->s_xattr = shiftfs_xattr_handlers;
  sb->s_d_op = &shiftfs_dentry_ops;
--
2.23.0


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

ACK: [PATCH][SRU][DISCO][EOAN] UBUNTU: SAUCE: shiftfs: setup correct s_maxbytes limit

Connor Kuehl
On 10/23/19 5:22 AM, Christian Brauner wrote:

> BugLink: https://bugs.launchpad.net/bugs/1849482
>
> Set the s_maxbytes limit to MAX_LFS_FILESIZE.
> Currently shiftfs limits the maximum size for fallocate() needlessly
> causing calls such as fallocate --length 2GB ./file to fail. This
> limitation is arbitrary since it's not caused by the underlay but
> rather by shiftfs itself capping the s_maxbytes. This causes bugs such
> as the one reported in [1].
>
> [1]: https://github.com/lxc/lxd/issues/6333
> Signed-off-by: Christian Brauner <[hidden email]>

Acked-by: Connor Kuehl <[hidden email]>

> ---
>   fs/shiftfs.c | 1 +
>   1 file changed, 1 insertion(+)
>
> diff --git a/fs/shiftfs.c b/fs/shiftfs.c
> index 55bb32b611f2..ac22a5bf5b1f 100644
> --- a/fs/shiftfs.c
> +++ b/fs/shiftfs.c
> @@ -2057,6 +2057,7 @@ static int shiftfs_fill_super(struct super_block *sb, void *raw_data,
>   inode->i_private = dentry->d_inode;
>  
>   sb->s_magic = SHIFTFS_MAGIC;
> + sb->s_maxbytes = MAX_LFS_FILESIZE;
>   sb->s_op = &shiftfs_super_ops;
>   sb->s_xattr = shiftfs_xattr_handlers;
>   sb->s_d_op = &shiftfs_dentry_ops;
>


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

ACK: [PATCH][SRU][DISCO][EOAN] UBUNTU: SAUCE: shiftfs: setup correct s_maxbytes limit

Stefan Bader-2
In reply to this post by Christian Brauner-3
On 23.10.19 14:22, Christian Brauner wrote:

> BugLink: https://bugs.launchpad.net/bugs/1849482
>
> Set the s_maxbytes limit to MAX_LFS_FILESIZE.
> Currently shiftfs limits the maximum size for fallocate() needlessly
> causing calls such as fallocate --length 2GB ./file to fail. This
> limitation is arbitrary since it's not caused by the underlay but
> rather by shiftfs itself capping the s_maxbytes. This causes bugs such
> as the one reported in [1].
>
> [1]: https://github.com/lxc/lxd/issues/6333
> Signed-off-by: Christian Brauner <[hidden email]>
Acked-by: Stefan Bader <[hidden email]>

> ---
>  fs/shiftfs.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/fs/shiftfs.c b/fs/shiftfs.c
> index 55bb32b611f2..ac22a5bf5b1f 100644
> --- a/fs/shiftfs.c
> +++ b/fs/shiftfs.c
> @@ -2057,6 +2057,7 @@ static int shiftfs_fill_super(struct super_block *sb, void *raw_data,
>   inode->i_private = dentry->d_inode;
>  
>   sb->s_magic = SHIFTFS_MAGIC;
> + sb->s_maxbytes = MAX_LFS_FILESIZE;
>   sb->s_op = &shiftfs_super_ops;
>   sb->s_xattr = shiftfs_xattr_handlers;
>   sb->s_d_op = &shiftfs_dentry_ops;
>


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team

signature.asc (849 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

APPLIED: [PATCH][SRU][DISCO][EOAN] UBUNTU: SAUCE: shiftfs: setup correct s_maxbytes limit

Khaled Elmously
In reply to this post by Christian Brauner-3
On 2019-10-23 14:22:28 , Christian Brauner wrote:

> BugLink: https://bugs.launchpad.net/bugs/1849482
>
> Set the s_maxbytes limit to MAX_LFS_FILESIZE.
> Currently shiftfs limits the maximum size for fallocate() needlessly
> causing calls such as fallocate --length 2GB ./file to fail. This
> limitation is arbitrary since it's not caused by the underlay but
> rather by shiftfs itself capping the s_maxbytes. This causes bugs such
> as the one reported in [1].
>
> [1]: https://github.com/lxc/lxd/issues/6333
> Signed-off-by: Christian Brauner <[hidden email]>
> ---
>  fs/shiftfs.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/fs/shiftfs.c b/fs/shiftfs.c
> index 55bb32b611f2..ac22a5bf5b1f 100644
> --- a/fs/shiftfs.c
> +++ b/fs/shiftfs.c
> @@ -2057,6 +2057,7 @@ static int shiftfs_fill_super(struct super_block *sb, void *raw_data,
>   inode->i_private = dentry->d_inode;
>  
>   sb->s_magic = SHIFTFS_MAGIC;
> + sb->s_maxbytes = MAX_LFS_FILESIZE;
>   sb->s_op = &shiftfs_super_ops;
>   sb->s_xattr = shiftfs_xattr_handlers;
>   sb->s_d_op = &shiftfs_dentry_ops;
> --
> 2.23.0
>
>
> --
> kernel-team mailing list
> [hidden email]
> https://lists.ubuntu.com/mailman/listinfo/kernel-team

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

APPLIED[Unstable]: [PATCH][SRU][DISCO][EOAN] UBUNTU: SAUCE: shiftfs: setup correct s_maxbytes limit

Seth Forshee
In reply to this post by Christian Brauner-3
On Wed, Oct 23, 2019 at 02:22:28PM +0200, Christian Brauner wrote:

> BugLink: https://bugs.launchpad.net/bugs/1849482
>
> Set the s_maxbytes limit to MAX_LFS_FILESIZE.
> Currently shiftfs limits the maximum size for fallocate() needlessly
> causing calls such as fallocate --length 2GB ./file to fail. This
> limitation is arbitrary since it's not caused by the underlay but
> rather by shiftfs itself capping the s_maxbytes. This causes bugs such
> as the one reported in [1].
>
> [1]: https://github.com/lxc/lxd/issues/6333
> Signed-off-by: Christian Brauner <[hidden email]>

Applied to unstable/master, thanks!

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team