linux/fs/vboxsf/vboxsf_wrappers.c

// SPDX-License-Identifier: MIT
/*
 * Wrapper functions for the shfl host calls.
 *
 * Copyright (C) 2006-2018 Oracle Corporation
 */

#include <linux/mm.h>
#include <linux/slab.h>
#include <linux/vbox_err.h>
#include <linux/vbox_utils.h>
#include "vfsmod.h"

#define SHFL_REQUEST

static u32 vboxsf_client_id;

int vboxsf_connect(void)
{}

void vboxsf_disconnect(void)
{}

static int vboxsf_call(u32 function, void *parms, u32 parm_count, int *status)
{}

int vboxsf_map_folder(struct shfl_string *folder_name, u32 *root)
{}

int vboxsf_unmap_folder(u32 root)
{}

/**
 * vboxsf_create - Create a new file or folder
 * @root:         Root of the shared folder in which to create the file
 * @parsed_path:  The path of the file or folder relative to the shared folder
 * @create_parms: Parameters for file/folder creation.
 *
 * Create a new file or folder or open an existing one in a shared folder.
 * Note this function always returns 0 / success unless an exceptional condition
 * occurs - out of memory, invalid arguments, etc. If the file or folder could
 * not be opened or created, create_parms->handle will be set to
 * SHFL_HANDLE_NIL on return.  In this case the value in create_parms->result
 * provides information as to why (e.g. SHFL_FILE_EXISTS), create_parms->result
 * is also set on success as additional information.
 *
 * Returns:
 * 0 or negative errno value.
 */
int vboxsf_create(u32 root, struct shfl_string *parsed_path,
		  struct shfl_createparms *create_parms)
{}

int vboxsf_close(u32 root, u64 handle)
{}

int vboxsf_remove(u32 root, struct shfl_string *parsed_path, u32 flags)
{}

int vboxsf_rename(u32 root, struct shfl_string *src_path,
		  struct shfl_string *dest_path, u32 flags)
{}

int vboxsf_read(u32 root, u64 handle, u64 offset, u32 *buf_len, u8 *buf)
{}

int vboxsf_write(u32 root, u64 handle, u64 offset, u32 *buf_len, u8 *buf)
{}

/* Returns 0 on success, 1 on end-of-dir, negative errno otherwise */
int vboxsf_dirinfo(u32 root, u64 handle,
		   struct shfl_string *parsed_path, u32 flags, u32 index,
		   u32 *buf_len, struct shfl_dirinfo *buf, u32 *file_count)
{}

int vboxsf_fsinfo(u32 root, u64 handle, u32 flags,
		  u32 *buf_len, void *buf)
{}

int vboxsf_readlink(u32 root, struct shfl_string *parsed_path,
		    u32 buf_len, u8 *buf)
{}

int vboxsf_symlink(u32 root, struct shfl_string *new_path,
		   struct shfl_string *old_path, struct shfl_fsobjinfo *buf)
{}

int vboxsf_set_utf8(void)
{}

int vboxsf_set_symlinks(void)
{}