On Tue, Feb 1, 2011 at 5:27 AM, M. Mohan Kumar <mo...@in.ibm.com> wrote:
> +static int passthrough_mknod(FsContext *fs_ctx, const char *path, FsCred 
> *credp)
> +{
> +    V9fsFileObjectRequest request;
> +    int retval, error = 0;
> +
> +    fill_request(&request, path, credp);
> +    request.data.type = T_MKNOD;
> +
> +    retval = v9fs_create_special(fs_ctx, &request, &error);
> +    if (retval < 0) {
> +        errno = error;
> +    }
> +    return retval;
> +}

It would be nice to avoid duplicating all these wrappers.  Would it be
possible to write one generic function which takes the request type
and some optional arguments and runs the request?

Stefan

Reply via email to