Paulo Alcantara <pc@xxxxxxxxxxxxx> wrote: > It wouldn't make sense to make it depend on PROC_FS. Correct. > I see two problems here: > > (1) We shouldn't be creating /proc/fs/netfs if CONFIG_PROC_FS=n Yes, the proc_*() calls will all fail if CONFIG_PROC_FS=n and so need to be #ifdef'd around. > (2) There's a wrong assumption in the API that @netfs_request_pool and > @netfs_subrequest_pool will always be initialized. For example, we > should return an error from netfs_alloc_[sub]rquest() functions in case > @mempool == NULL. No. The assumption is correct. The problem is that if the module is built in (ie. CONFIG_NETFS_SUPPORT=y), then there is no consequence of netfs_init() failing - and fail it does if CONFIG_PROC_FS=n - and 9p, afs and cifs will call into it anyway, despite the fact it deinitialised itself. It should marked be module_init(), not fs_initcall(). David