All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] spufs: fix a crash in spufs_create_root()
@ 2019-10-08 14:13 Emmanuel Nicolet
  2019-10-08 15:57 ` Arnd Bergmann
  2019-10-11  8:22 ` Michael Ellerman
  0 siblings, 2 replies; 3+ messages in thread
From: Emmanuel Nicolet @ 2019-10-08 14:13 UTC (permalink / raw)
  To: Jeremy Kerr; +Cc: linuxppc-dev, Arnd Bergmann

The spu_fs_context was not set in fc->fs_private, this caused a crash
when accessing ctx->mode in spufs_create_root().

Signed-off-by: Emmanuel Nicolet <emmanuel.nicolet@gmail.com>
---
 arch/powerpc/platforms/cell/spufs/inode.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/powerpc/platforms/cell/spufs/inode.c b/arch/powerpc/platforms/cell/spufs/inode.c
index 1d93e55a2de1..2dd452a047cd 100644
--- a/arch/powerpc/platforms/cell/spufs/inode.c
+++ b/arch/powerpc/platforms/cell/spufs/inode.c
@@ -761,6 +761,7 @@ static int spufs_init_fs_context(struct fs_context *fc)
 	ctx->gid = current_gid();
 	ctx->mode = 0755;
 
+	fc->fs_private = ctx;
 	fc->s_fs_info = sbi;
 	fc->ops = &spufs_context_ops;
 	return 0;
-- 
2.23.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] spufs: fix a crash in spufs_create_root()
  2019-10-08 14:13 [PATCH] spufs: fix a crash in spufs_create_root() Emmanuel Nicolet
@ 2019-10-08 15:57 ` Arnd Bergmann
  2019-10-11  8:22 ` Michael Ellerman
  1 sibling, 0 replies; 3+ messages in thread
From: Arnd Bergmann @ 2019-10-08 15:57 UTC (permalink / raw)
  To: Emmanuel Nicolet; +Cc: David Howells, linuxppc-dev, Jeremy Kerr

On Tue, Oct 8, 2019 at 4:13 PM Emmanuel Nicolet
<emmanuel.nicolet@gmail.com> wrote:
>
> The spu_fs_context was not set in fc->fs_private, this caused a crash
> when accessing ctx->mode in spufs_create_root().
>
> Signed-off-by: Emmanuel Nicolet <emmanuel.nicolet@gmail.com>

Fixes: d2e0981c3b9a ("vfs: Convert spufs to use the new mount API")
Acked-by: Arnd Bergmann <arnd@arndb.de>

>  arch/powerpc/platforms/cell/spufs/inode.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/arch/powerpc/platforms/cell/spufs/inode.c b/arch/powerpc/platforms/cell/spufs/inode.c
> index 1d93e55a2de1..2dd452a047cd 100644
> --- a/arch/powerpc/platforms/cell/spufs/inode.c
> +++ b/arch/powerpc/platforms/cell/spufs/inode.c
> @@ -761,6 +761,7 @@ static int spufs_init_fs_context(struct fs_context *fc)
>         ctx->gid = current_gid();
>         ctx->mode = 0755;
>
> +       fc->fs_private = ctx;
>         fc->s_fs_info = sbi;
>         fc->ops = &spufs_context_ops;
>         return 0;
> --
> 2.23.0
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] spufs: fix a crash in spufs_create_root()
  2019-10-08 14:13 [PATCH] spufs: fix a crash in spufs_create_root() Emmanuel Nicolet
  2019-10-08 15:57 ` Arnd Bergmann
@ 2019-10-11  8:22 ` Michael Ellerman
  1 sibling, 0 replies; 3+ messages in thread
From: Michael Ellerman @ 2019-10-11  8:22 UTC (permalink / raw)
  To: Emmanuel Nicolet, Jeremy Kerr; +Cc: linuxppc-dev, Arnd Bergmann

On Tue, 2019-10-08 at 14:13:42 UTC, Emmanuel Nicolet wrote:
> The spu_fs_context was not set in fc->fs_private, this caused a crash
> when accessing ctx->mode in spufs_create_root().
> 
> Signed-off-by: Emmanuel Nicolet <emmanuel.nicolet@gmail.com>

Applied to powerpc fixes, thanks.

https://git.kernel.org/powerpc/c/2272905a4580f26630f7d652cc33935b59f96d4c

cheers

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-10-11  8:33 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-10-08 14:13 [PATCH] spufs: fix a crash in spufs_create_root() Emmanuel Nicolet
2019-10-08 15:57 ` Arnd Bergmann
2019-10-11  8:22 ` Michael Ellerman

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.