[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 2/6] nfs: implement netfs_get_source
From: |
Samuel Thibault |
Subject: |
Re: [PATCH 2/6] nfs: implement netfs_get_source |
Date: |
Tue, 25 Feb 2014 00:27:54 -0500 |
User-agent: |
Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30) |
Justus Winter, le Tue 11 Feb 2014 17:13:08 +0100, a écrit :
> Implement netfs_get_source so that nfs translators show up in
> /proc/mounts.
>
> * nfs/main.c (netfs_get_source): New function.
Ack.
> ---
> nfs/main.c | 14 ++++++++++++++
> 1 file changed, 14 insertions(+)
>
> diff --git a/nfs/main.c b/nfs/main.c
> index 3ce75a9..cd1c29a 100644
> --- a/nfs/main.c
> +++ b/nfs/main.c
> @@ -269,6 +269,20 @@ netfs_append_args (char **argz, size_t *argz_len)
> return err;
> }
>
> +/* The user may define this function. The function must set source to
> + the source of CRED. The function may return an EOPNOTSUPP to
> + indicate that the concept of a source device is not applicable. The
> + default function always returns EOPNOTSUPP. */
> +error_t
> +netfs_get_source (struct protid *cred, char *source, size_t source_len)
> +{
> + if (! cred)
> + return EOPNOTSUPP;
> +
> + snprintf (source, source_len, "%s:%s", host, remote_fs);
> + return 0;
> +}
> +
> /* Extract the host and remote filesystem names from SPEC, which should use
> either HOST:FS or FS@HOST notation. Returns the malloced storage into
> which both REMOTE_FS and HOST point, or 0 if SPEC is invalid. */
> --
> 1.8.5.2
>
--
Samuel
> dvips -o $@ $<
Faut faire gffe de pas te couper avec ton truc, t'as mis des ciseaux ($<)
partout :))
-+- Dom in Guide du linuxien pervers - "J'aime pas les Makefile !" -+-
- fix the get-children and get-source procedures, Justus Winter, 2014/02/11
- [PATCH 2/6] nfs: implement netfs_get_source, Justus Winter, 2014/02/11
- Re: [PATCH 2/6] nfs: implement netfs_get_source,
Samuel Thibault <=
- [PATCH 3/6] trans/mtab: ignore translators that do not implement file_get_source, Justus Winter, 2014/02/11
- [PATCH 4/6] tmpfs: set diskfs_disk_name to "none", Justus Winter, 2014/02/11
- [PATCH 5/6] trans/mtab: do not map unknown source strings to "none", Justus Winter, 2014/02/11
- [PATCH 6/6] New RPCs, fix build, Justus Winter, 2014/02/11
- [PATCH 1/6] hurd: fix the get-children and get-source procedures, Justus Winter, 2014/02/11