Index: testsuites/fstests/.cvsignore
===================================================================
--- testsuites/fstests/.cvsignore	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
+++ testsuites/fstests/.cvsignore	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
@@ -0,0 +1,15 @@
+aclocal.m4
+autom4te*.cache
+config.cache
+config.guess
+config.h.in
+config.log
+config.status
+config.sub
+configure
+depcomp
+install-sh
+Makefile
+Makefile.in
+missing
+mkinstalldirs
Index: testsuites/fstests/ChangeLog
===================================================================
--- testsuites/fstests/ChangeLog	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
+++ testsuites/fstests/ChangeLog	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
@@ -0,0 +1,10 @@
+2011-04-20	Joel Sherrill <joel.sherrill@oarcorp.com>
+
+	Add initial test to File System Test Suite.
+	* .cvsignore, ChangeLog, Makefile.am, configure.ac, fs01/fs91.doc,
+	fs01/init.c, imfs_fs01/.cvsignore, imfs_fs01/Makefile.am,
+	imfs_fs01/imfs_fs01.scn, imfs_support/fs_config.h,
+	imfs_support/fs_support.c, mimfs_fs01/.cvsignore,
+	mimfs_fs01/Makefile.am, mimfs_fs01/mimfs_fs01.scn,
+	mimfs_support/fs_config.h, mimfs_support/fs_support.c: New files.
+
Index: testsuites/fstests/Makefile.am
===================================================================
--- testsuites/fstests/Makefile.am	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
+++ testsuites/fstests/Makefile.am	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
@@ -0,0 +1,15 @@
+##
+## $Id$
+##
+
+ACLOCAL_AMFLAGS = -I ../aclocal
+
+SUBDIRS = \
+  imfs_fs01 \
+  mimfs_fs01
+
+DIST_SUBDIRS = $(SUBDIRS)
+EXTRA_DIST = fs01/init.c fs01/fs01.doc
+
+include $(top_srcdir)/../automake/subdirs.am
+include $(top_srcdir)/../automake/local.am
Index: testsuites/fstests/configure.ac
===================================================================
--- testsuites/fstests/configure.ac	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
+++ testsuites/fstests/configure.ac	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
@@ -0,0 +1,84 @@
+## Process this file with autoconf to produce a configure script.
+## 
+## $Id$
+
+AC_PREREQ([2.68])
+AC_INIT([rtems-c-src-tests-fstests],[_RTEMS_VERSION],[http://www.rtems.org/bugzilla])
+AC_CONFIG_SRCDIR([imfs_support])
+RTEMS_TOP([../..],[..])
+
+RTEMS_CANONICAL_TARGET_CPU
+
+AM_INIT_AUTOMAKE([no-define foreign 1.11.1])
+AM_MAINTAINER_MODE
+
+RTEMS_ENV_RTEMSBSP
+
+RTEMS_PROJECT_ROOT
+
+RTEMS_PROG_CC_FOR_TARGET
+
+RTEMS_CANONICALIZE_TOOLS
+
+RTEMS_CHECK_CUSTOM_BSP(RTEMS_BSP)
+AC_CONFIG_HEADER([config.h])
+
+RTEMS_CHECK_CPUOPTS([RTEMS_POSIX_API])
+AM_CONDITIONAL(HAS_POSIX,test x"${rtems_cv_RTEMS_POSIX_API}" = x"yes")
+
+# but newlib doesn't have sys/mman.h
+AC_CHECK_HEADERS([sys/mman.h])
+
+# FIXME: newlib should supply declaration of pthread_rwlock_unlock()
+AC_CHECK_DECLS([pthread_rwlock_unlock],[],[],[[#include <pthread.h>]])
+
+# FIXME: newlib should supply declaration of pthread_atfork()
+AC_CHECK_DECLS([pthread_atfork],[],[],[[#include <pthread.h>]])
+
+# FIXME: RTEMS presumes pthread_attr_getcputime to be IEEE Std 1003.1
+# Likely an anachronism in RTEMS.
+AC_CHECK_DECLS([pthread_attr_getcputime],[],[],[[#include <pthread.h>]])
+
+# FIXME: RTEMS presumes pthread_attr_getcputime to be IEEE Std 1003.1
+# Likely an anachronism in RTEMS.
+AC_CHECK_DECLS([pthread_attr_getcputime],[],[],[[#include <pthread.h>]])
+
+# FIXME: RTEMS presumes pthread_attr_setcputime to be IEEE Std 1003.1
+# Likely an anachronism in RTEMS.
+AC_CHECK_DECLS([pthread_attr_setcputime],[],[],[[#include <pthread.h>]])
+
+# Added to pthreads after initial revision.  May not be in toolset
+AC_CHECK_DECLS([pthread_attr_getstack],[],[],[[#include <pthread.h>]])
+
+# Added to pthreads after initial revision.  May not be in toolset
+AC_CHECK_DECLS([pthread_attr_setstack],[],[],[[#include <pthread.h>]])
+
+# Added to pthreads after initial revision.  May not be in toolset
+AC_CHECK_DECLS([pthread_attr_getguardsize],[],[],[[#include <pthread.h>]])
+
+# Added to pthreads after initial revision.  May not be in toolset
+AC_CHECK_DECLS([pthread_attr_setguardsize],[],[],[[#include <pthread.h>]])
+
+# FIXME: adjtime is a non-standardized BSD/Linux extension
+# RTEMS should not rely on adjtime
+AC_CHECK_DECLS([adjtime],[],[],[[#include <sys/time.h>]])
+
+# FIXME: IEEE Std 1003.1-2008 mandates mprotect in sys/mman.h,
+# RTEMS provides a stub, despite newlib doesn't have sys/mman.h
+AC_CHECK_DECLS([mprotect],[],[],[[#include <sys/mman.h>]])
+
+# FIXME: IEEE Std 1003.1-2008 mandates seteuid in unistd.h
+# RTEMS provides it, despite newlib doesn't declare it.
+AC_CHECK_DECLS([seteuid],[],[],[#include <unistd.h>])
+
+# FIXME: We should get rid of this. It's a cludge.
+AC_CHECK_SIZEOF([off_t])
+AC_CHECK_SIZEOF([blksize_t])
+AC_CHECK_SIZEOF([blkcnt_t])
+
+# Explicitly list all Makefiles here
+AC_CONFIG_FILES([Makefile
+imfs_fs01/Makefile
+mimfs_fs01/Makefile
+])
+AC_OUTPUT
Index: testsuites/fstests/imfs_support/fs_config.h
===================================================================
--- testsuites/fstests/imfs_support/fs_config.h	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
+++ testsuites/fstests/imfs_support/fs_config.h	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
@@ -0,0 +1,10 @@
+/*
+ *  $Id$
+ */
+
+#define FILESYSTEM "IMFS"
+#define BASE_FOR_TEST ""
+
+extern void test_initialize_filesystem(void);
+
+extern void test_shutdown_filesystem(void);
Index: testsuites/fstests/imfs_support/fs_support.c
===================================================================
--- testsuites/fstests/imfs_support/fs_support.c	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
+++ testsuites/fstests/imfs_support/fs_support.c	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
@@ -0,0 +1,11 @@
+/*
+ *  $Id$
+ */
+
+void test_initialize_filesystem(void)
+{
+}
+
+void test_shutdown_filesystem(void)
+{
+}
Index: testsuites/fstests/mimfs_support/fs_config.h
===================================================================
--- testsuites/fstests/mimfs_support/fs_config.h	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
+++ testsuites/fstests/mimfs_support/fs_config.h	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
@@ -0,0 +1,10 @@
+/*
+ *  $Id$
+ */
+
+#define FILESYSTEM "MOUNTED IMFS"
+#define BASE_FOR_TEST "/mnt/"
+
+extern void test_initialize_filesystem(void);
+
+extern void test_shutdown_filesystem(void);
Index: testsuites/fstests/mimfs_support/fs_support.c
===================================================================
--- testsuites/fstests/mimfs_support/fs_support.c	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
+++ testsuites/fstests/mimfs_support/fs_support.c	(revision a2f875f222865a6a92c980418e6a6094fcff9089)
@@ -0,0 +1,41 @@
+/*
+ *  $Id$
+ */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include <sys/stat.h>
+#include <sys/types.h>
+
+#include "pmacros.h"
+#include "fs_config.h"
+
+#include <rtems/libio.h>
+
+void test_initialize_filesystem(void)
+{
+  int rc;
+
+  rc = mkdir( BASE_FOR_TEST, 0777 );
+  rtems_test_assert( rc == 0 );
+
+  rc = mount(
+    "null",
+     BASE_FOR_TEST,
+    "imfs",
+    RTEMS_FILESYSTEM_READ_ONLY,
+    NULL
+  );
+  rtems_test_assert( rc == 0 );
+}
+
+void test_shutdown_filesystem(void)
+{
+  int rc;
+
+  rc = unmount( BASE_FOR_TEST );
+  rtems_test_assert( rc == 0 );
+
+}
