summaryrefslogtreecommitdiffstats
path: root/support/include/nfsd_path.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 06:03:02 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 06:03:02 +0000
commit4897093455a2bf08f3db3a1132cc2f6f5484d77c (patch)
tree9e6373544263f003139431fb4b08f9766e1ed530 /support/include/nfsd_path.h
parentInitial commit. (diff)
downloadnfs-utils-4897093455a2bf08f3db3a1132cc2f6f5484d77c.tar.xz
nfs-utils-4897093455a2bf08f3db3a1132cc2f6f5484d77c.zip
Adding upstream version 1:2.6.4.upstream/1%2.6.4upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'support/include/nfsd_path.h')
-rw-r--r--support/include/nfsd_path.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/support/include/nfsd_path.h b/support/include/nfsd_path.h
new file mode 100644
index 0000000..aa1e1dd
--- /dev/null
+++ b/support/include/nfsd_path.h
@@ -0,0 +1,32 @@
+/*
+ * Copyright (C) 2019 Trond Myklebust <trond.myklebust@hammerspace.com>
+ */
+#ifndef NFSD_PATH_H
+#define NFSD_PATH_H
+
+#include <sys/stat.h>
+
+struct file_handle;
+struct statfs;
+
+void nfsd_path_init(void);
+
+const char * nfsd_path_nfsd_rootdir(void);
+char * nfsd_path_strip_root(char *pathname);
+char * nfsd_path_prepend_dir(const char *dir, const char *pathname);
+
+int nfsd_path_stat(const char *pathname, struct stat *statbuf);
+int nfsd_path_lstat(const char *pathname, struct stat *statbuf);
+
+int nfsd_path_statfs(const char *pathname,
+ struct statfs *statbuf);
+
+char * nfsd_realpath(const char *path, char *resolved_path);
+
+ssize_t nfsd_path_read(int fd, char *buf, size_t len);
+ssize_t nfsd_path_write(int fd, const char *buf, size_t len);
+
+int nfsd_name_to_handle_at(int fd, const char *path,
+ struct file_handle *fh,
+ int *mount_id, int flags);
+#endif