Message ID | alpine.LSU.2.11.1408181350260.1127@eggly.anvils (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Hi Hugh, On Mon, 18 Aug 2014 13:58:26 -0700 (PDT) Hugh Dickins <hughd@google.com> wrote: > > [PATCH next] vfs: initialize m_list to fix crash in mnt_set_mountpoint > > Fix mnt_set_mountpoint() crash: new_mountpoint() must initialize m_list. > > Reported-by: Felipe Balbi <balbi@ti.com> > Signed-off-by: Hugh Dickins <hughd@google.com> I assume that this is a fix for commit 89f7ca1af15b ("vfs: Keep a list of mounts on a mount point") that is currently i the vfs tree. I will apply this patch as a fix up for the vfs tree in linux-next today.
On Wed, 20 Aug 2014, Stephen Rothwell wrote: > On Mon, 18 Aug 2014 13:58:26 -0700 (PDT) Hugh Dickins <hughd@google.com> wrote: > > > > [PATCH next] vfs: initialize m_list to fix crash in mnt_set_mountpoint > > > > Fix mnt_set_mountpoint() crash: new_mountpoint() must initialize m_list. > > > > Reported-by: Felipe Balbi <balbi@ti.com> > > Signed-off-by: Hugh Dickins <hughd@google.com> > > I assume that this is a fix for commit 89f7ca1af15b ("vfs: Keep a list > of mounts on a mount point") that is currently i the vfs tree. I will > apply this patch as a fix up for the vfs tree in linux-next today. Yes, that's it: thanks a lot, Stephen, that will help everybody. I should acknowledge that Thierry Reding posted the same fix (a few lines away) before mine, but I only came across his later in the day. Hugh
--- 3.17-rc1-next/fs/namespace.c 2014-08-18 12:26:26.619992661 -0700 +++ linux/fs/namespace.c 2014-08-18 13:02:42.948389147 -0700 @@ -738,6 +738,7 @@ static struct mountpoint *new_mountpoint mp->m_dentry = dentry; mp->m_count = 1; + INIT_HLIST_HEAD(&mp->m_list); hlist_add_head(&mp->m_hash, chain); return mp; }