Index: uspace/lib/ext4/libext4_filesystem.c
===================================================================
--- uspace/lib/ext4/libext4_filesystem.c	(revision 6c501f8ff98956b3a251fb0b81b404ae0ecf44a1)
+++ uspace/lib/ext4/libext4_filesystem.c	(revision 01ab41b7aac1dcb93cd817e4174b7f00288199b1)
@@ -37,18 +37,69 @@
 
 #include <errno.h>
+#include <malloc.h>
 #include "libext4_filesystem.h"
 
+/**
+ * TODO doxy
+ */
 int ext4_filesystem_init(ext4_filesystem_t *fs, service_id_t service_id)
 {
+
+	int rc;
+	ext4_superblock_t *temp_superblock;
+	size_t block_size;
+
+	fs->device = service_id;
+
+	// TODO block size !!!
+	rc = block_init(EXCHANGE_SERIALIZE, fs->device, 2048);
+	if (rc != EOK) {
+		return rc;
+	}
+
+	rc = ext4_superblock_read_direct(fs->device, &temp_superblock);
+	if (rc != EOK) {
+		block_fini(fs->device);
+		return rc;
+	}
+
+	block_size = ext4_superblock_get_block_size(temp_superblock);
+
+	if (block_size > EXT4_MAX_BLOCK_SIZE) {
+		block_fini(fs->device);
+		return ENOTSUP;
+	}
+
+	rc = block_cache_init(service_id, block_size, 0, CACHE_MODE_WT);
+	if (rc != EOK) {
+		block_fini(fs->device);
+		return rc;
+	}
+
+	fs->superblock = temp_superblock;
+
+
 	// TODO
 	return EOK;
 }
 
+/**
+ * TODO doxy
+ */
 int ext4_filesystem_check_sanity(ext4_filesystem_t *fs)
 {
-	// TODO
+	int rc;
+
+	rc = ext4_superblock_check_sanity(fs->superblock);
+	if (rc != EOK) {
+		return rc;
+	}
+
 	return EOK;
 }
 
+/**
+ * TODO doxy
+ */
 int ext4_filesystem_check_flags(ext4_filesystem_t *fs, bool *o_read_only)
 {
@@ -57,7 +108,11 @@
 }
 
+/**
+ * TODO doxy
+ */
 void ext4_filesystem_fini(ext4_filesystem_t *fs)
 {
-	// TODO
+	free(fs->superblock);
+	block_fini(fs->device);
 }
 
Index: uspace/lib/ext4/libext4_filesystem.h
===================================================================
--- uspace/lib/ext4/libext4_filesystem.h	(revision 6c501f8ff98956b3a251fb0b81b404ae0ecf44a1)
+++ uspace/lib/ext4/libext4_filesystem.h	(revision 01ab41b7aac1dcb93cd817e4174b7f00288199b1)
@@ -42,4 +42,7 @@
 } ext4_filesystem_t;
 
+// TODO constant value
+#define EXT4_MAX_BLOCK_SIZE		8096
+
 extern int ext4_filesystem_init(ext4_filesystem_t *, service_id_t);
 extern int ext4_filesystem_check_sanity(ext4_filesystem_t *fs);
Index: uspace/lib/ext4/libext4_inode.c
===================================================================
--- uspace/lib/ext4/libext4_inode.c	(revision 6c501f8ff98956b3a251fb0b81b404ae0ecf44a1)
+++ uspace/lib/ext4/libext4_inode.c	(revision 01ab41b7aac1dcb93cd817e4174b7f00288199b1)
@@ -39,7 +39,10 @@
 
 // TODO check return type
+/**
+ * TODO doxy
+ */
 uint16_t ext4_inode_get_usage_count(ext4_inode_t *inode)
 {
-	// TODO
+	// TODO check
 	return 0;
 }
Index: uspace/lib/ext4/libext4_superblock.c
===================================================================
--- uspace/lib/ext4/libext4_superblock.c	(revision 6c501f8ff98956b3a251fb0b81b404ae0ecf44a1)
+++ uspace/lib/ext4/libext4_superblock.c	(revision 01ab41b7aac1dcb93cd817e4174b7f00288199b1)
@@ -36,6 +36,78 @@
  */
 
+#include <byteorder.h>
+#include <errno.h>
+#include <libblock.h>
+#include <malloc.h>
 #include "libext4_superblock.h"
 
+/**
+ * TODO doxy
+ */
+uint16_t ext2_superblock_get_magic(ext4_superblock_t *sb)
+{
+	return uint16_t_le2host(sb->s_magic);
+}
+
+/**
+ * TODO doxy
+ */
+uint32_t ext4_superblock_get_first_block(ext4_superblock_t *sb)
+{
+	return uint32_t_le2host(sb->s_first_data_block);
+}
+
+/**
+ * TODO doxy
+ */
+uint32_t ext4_superblock_get_block_size_log2(ext4_superblock_t *sb)
+{
+	return uint32_t_le2host(sb->s_log_block_size);
+}
+
+/**
+ * TODO doxy
+ */
+uint32_t ext4_superblock_get_block_size(ext4_superblock_t *sb)
+{
+	return 1024 << ext4_superblock_get_block_size_log2(sb);
+}
+
+
+/**
+ * TODO doxy
+ */
+int ext4_superblock_read_direct(service_id_t service_id,
+    ext4_superblock_t **superblock)
+{
+	void *data;
+	int rc;
+
+	data = malloc(EXT4_SUPERBLOCK_SIZE);
+	if (data == NULL) {
+		return ENOMEM;
+	}
+
+	rc = block_read_bytes_direct(service_id, EXT4_SUPERBLOCK_OFFSET,
+	    EXT4_SUPERBLOCK_SIZE, data);
+
+	if (rc != EOK) {
+		free(data);
+		return rc;
+	}
+
+	(*superblock) = data;
+
+	return EOK;
+}
+
+/**
+ * TODO doxy
+ */
+int ext4_superblock_check_sanity(ext4_superblock_t *sb)
+{
+	// TODO
+	return EOK;
+}
 
 /**
Index: uspace/lib/ext4/libext4_superblock.h
===================================================================
--- uspace/lib/ext4/libext4_superblock.h	(revision 6c501f8ff98956b3a251fb0b81b404ae0ecf44a1)
+++ uspace/lib/ext4/libext4_superblock.h	(revision 01ab41b7aac1dcb93cd817e4174b7f00288199b1)
@@ -34,4 +34,5 @@
 #define LIBEXT4_LIBEXT4_SUPERBLOCK_H_
 
+#include <libblock.h>
 #include <sys/types.h>
 
@@ -140,4 +141,14 @@
 } __attribute__((packed)) ext4_superblock_t;
 
+// TODO constants
+#define EXT4_SUPERBLOCK_MAGIC		0xEF53
+#define EXT4_SUPERBLOCK_SIZE		1024
+#define EXT4_SUPERBLOCK_OFFSET		1024
+
+extern uint32_t ext4_superblock_get_block_size_log2(ext4_superblock_t *);
+extern uint32_t ext4_superblock_get_block_size(ext4_superblock_t *);
+
+extern int ext4_superblock_read_direct(service_id_t, ext4_superblock_t **);
+extern int ext4_superblock_check_sanity(ext4_superblock_t *);
 
 #endif
