Re: [PATCH] do not check for modprobe or procfs or load module

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2012-06-08 at 11:06 +0400, Michael Tokarev wrote:
> Loading autofs module is #ifdef'ed in the source, so
> there is no need to check for /proc (which is only used
> to load module) or modprobe.  Both modprobe and /proc
> are always in the fixed location so there's no need to
> check for these to start with.

/proc is needed for the mounted file systems lists.
autofs won't work without it.
 
> 
> diff --git a/configure.in b/configure.in
> index 46de65a..5109675 100644
> --- a/configure.in
> +++ b/configure.in
> @@ -34,11 +34,6 @@ AC_MSG_CHECKING([for binaries in])
>  AC_MSG_RESULT([$searchpath])
>  
>  #
> -# Make sure we have "/proc"
> -#
> -AF_LINUX_PROCFS()
> -
> -#
>  # Location of init.d directory?
>  #
>  AF_INIT_D()
> @@ -132,7 +127,6 @@ AF_PATH_INCLUDE(UMOUNT, umount, /bin/umount, $searchpath)
>  AF_PATH_INCLUDE(E2FSCK, fsck.ext2 e2fsck, , $searchpath)
>  AF_PATH_INCLUDE(E3FSCK, fsck.ext3 e3fsck, , $searchpath)
>  AF_PATH_INCLUDE(E4FSCK, fsck.ext4 e4fsck, , $searchpath)
> -AF_PATH_INCLUDE(MODPROBE, modprobe, , $searchpath)
>  
>  AF_CHECK_PROG(LEX, flex lex, , $searchpath)
>  AF_CHECK_PROG(YACC, bison, , $searchpath)
> diff --git a/daemon/module.c b/daemon/module.c
> index 466d8d7..36cefe7 100644
> --- a/daemon/module.c
> +++ b/daemon/module.c
> @@ -18,6 +18,8 @@
>  #include <stdlib.h>
>  #include "automount.h"
>  
> +#if 0
> +/* see comment in daemon/automount.c around load_autofs4_module() call */
>  int load_autofs4_module(void)
>  {
>  	FILE *fp;
> @@ -52,6 +54,7 @@ int load_autofs4_module(void)
>  
>  	return 1;
>  }
> +#endif
>  
>  struct lookup_mod *open_lookup(const char *name, const char *err_prefix,
>  			       const char *mapfmt, int argc, const char *const *argv)
> diff --git a/include/automount.h b/include/automount.h
> index 8816c15..b89aa1d 100644
> --- a/include/automount.h
> +++ b/include/automount.h
> @@ -50,16 +50,11 @@
>  #error Failed to locate umount(8)!
>  #endif
>  
> -#ifndef HAVE_MODPROBE
> -#error Failed to locate modprobe(8)!
> -#endif
> -
> -#ifndef HAVE_LINUX_PROCFS
> -#error Failed to verify existence of procfs filesystem!
> -#endif
> -
> +#if 0
> +/* see comment in daemon/automount.c around load_autofs4_module() call */
>  #define FS_MODULE_NAME  "autofs4"
>  int load_autofs4_module(void);
> +#endif
>  
>  /* The -s (sloppy) option to mount is good, if we have it... */
>  
> --
> To unsubscribe from this list: send the line "unsubscribe autofs" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


--
To unsubscribe from this list: send the line "unsubscribe autofs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Filesystem Development]     [Linux Ext4]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux