Index: uspace/srv/vfs/vfs.h
===================================================================
--- uspace/srv/vfs/vfs.h	(revision 4db6eaf06a371efbb5d1f20919cbf3e224a20036)
+++ uspace/srv/vfs/vfs.h	(revision 10d6b8581001bd7ee48d03024e92ffbc0a7f49e3)
@@ -148,4 +148,7 @@
  */
 typedef struct {
+	/** Serializes access to this open file. */
+	futex_t lock;
+
 	vfs_node_t *node;
 	
Index: uspace/srv/vfs/vfs_file.c
===================================================================
--- uspace/srv/vfs/vfs_file.c	(revision 4db6eaf06a371efbb5d1f20919cbf3e224a20036)
+++ uspace/srv/vfs/vfs_file.c	(revision 10d6b8581001bd7ee48d03024e92ffbc0a7f49e3)
@@ -87,4 +87,5 @@
 				return ENOMEM;
 			memset(files[i], 0, sizeof(vfs_file_t));
+			futex_initialize(&files[i]->lock, 1);
 			vfs_file_addref(files[i]);
 			return i;
Index: uspace/srv/vfs/vfs_rdwr.c
===================================================================
--- uspace/srv/vfs/vfs_rdwr.c	(revision 4db6eaf06a371efbb5d1f20919cbf3e224a20036)
+++ uspace/srv/vfs/vfs_rdwr.c	(revision 10d6b8581001bd7ee48d03024e92ffbc0a7f49e3)
@@ -83,4 +83,10 @@
 
 	/*
+	 * Lock the open file structure so that no other thread can manipulate
+	 * the same open file at a time.
+	 */
+	futex_down(&file->lock);
+
+	/*
 	 * Lock the file's node so that no other client can read/write to it at
 	 * the same time.
@@ -127,7 +133,8 @@
 
 	/*
-	 * Update the position pointer.
+	 * Update the position pointer and unlock the open file.
 	 */
 	file->pos += bytes;
+	futex_up(&file->lock);
 
 	/*
