From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758532AbcKCTRX (ORCPT ); Thu, 3 Nov 2016 15:17:23 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:52232 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756663AbcKCTRW (ORCPT ); Thu, 3 Nov 2016 15:17:22 -0400 Date: Thu, 3 Nov 2016 12:17:21 -0700 From: Andrew Morton To: zhongjiang Cc: , , , , , , , Paul Gortmaker Subject: Re: [RFC PATCH] hugetlbfs: fix the hugetlbfs can not be mounted Message-Id: <20161103121721.50040185d201e3aac27fd366@linux-foundation.org> In-Reply-To: <1477721311-54522-1-git-send-email-zhongjiang@huawei.com> References: <1477721311-54522-1-git-send-email-zhongjiang@huawei.com> X-Mailer: Sylpheed 3.4.1 (GTK+ 2.24.23; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 29 Oct 2016 14:08:31 +0800 zhongjiang wrote: > From: zhong jiang > > Since 'commit 3e89e1c5ea84 ("hugetlb: make mm and fs code explicitly non-modular")' > bring in the mainline. mount hugetlbfs will result in the following issue. > > mount: unknown filesystme type 'hugetlbfs' > > because previous patch remove the module_alias_fs, when we mount the fs type, > the caller get_fs_type can not find the filesystem. > > The patch just recover the module_alias_fs to identify the hugetlbfs. hm, 3e89e1c5ea84 ("hugetlb: make mm and fs code explicitly non-modular") was merged almost a year ago. And you are apparently the first person to discover this regression. Can you think why that is? > index 4fb7b10..b63e7de 100644 > --- a/fs/hugetlbfs/inode.c > +++ b/fs/hugetlbfs/inode.c > @@ -35,6 +35,7 @@ > #include > #include > #include > +#include > #include > > #include > @@ -1209,6 +1210,7 @@ static struct dentry *hugetlbfs_mount(struct file_system_type *fs_type, > .mount = hugetlbfs_mount, > .kill_sb = kill_litter_super, > }; > +MODULE_ALIAS_FS("hugetlbfs"); > > static struct vfsmount *hugetlbfs_vfsmount[HUGE_MAX_HSTATE]; >