+int yaffs_mkdir_reldev(struct yaffs_dev *dev, const YCHAR *path, mode_t mode)
+{
+ return yaffs_mkdir_reldir(ROOT_DIR(dev), path, mode);
+}
+
+int yaffs_mkdir(const YCHAR *path, mode_t mode)
+{
+ return yaffs_mkdir_reldir(NULL, path, mode);
+}
+
+int yaffs_rmdir_reldir(struct yaffs_obj *reldir, const YCHAR *path)
+{
+ int result;
+ YCHAR *alt_path;
+
+ if (yaffsfs_CheckMemRegion(path, 0, 0) < 0) {
+ yaffsfs_SetError(-EFAULT);
+ return -1;
+ }
+
+ if (yaffsfs_CheckPath(path) < 0) {
+ yaffsfs_SetError(-ENAMETOOLONG);
+ return -1;
+ }
+
+ if (yaffsfs_alt_dir_path(path, &alt_path) < 0) {
+ yaffsfs_SetError(-ENOMEM);
+ return -1;
+ }
+ if (alt_path)
+ path = alt_path;
+ result = yaffsfs_DoUnlink_reldir(reldir, path, 1);
+
+ kfree(alt_path);
+
+ return result;
+}
+
+int yaffs_rmdir_reldev(struct yaffs_dev *dev, const YCHAR *path)
+{
+ return yaffs_rmdir_reldir(ROOT_DIR(dev), path);
+}
+
+int yaffs_rmdir(const YCHAR *path)
+{
+ return yaffs_rmdir_reldir(NULL, path);
+}
+
+/*
+ * The mount/unmount/sync functions act on devices rather than reldirs.
+ */
+void *yaffs_getdev(const YCHAR *path)