#include <linux/module.h>
#include <linux/highuid.h>
#include <linux/pagemap.h>
#include <linux/buffer_head.h>
#include <linux/writeback.h>
#include <linux/statfs.h>
#include <linux/parser.h>
#include <linux/seq_file.h>
static const struct super_operations qnx6_sops;
static void qnx6_put_super(struct super_block *sb);
static struct inode *qnx6_alloc_inode(struct super_block *sb);
static void qnx6_destroy_inode(struct inode *inode);
static int qnx6_remount(struct super_block *sb, int *flags, char *data);
static int qnx6_statfs(struct dentry *dentry, struct kstatfs *buf);
static int qnx6_show_options(struct seq_file *seq, struct dentry *root);
static const struct super_operations qnx6_sops = {
.alloc_inode = qnx6_alloc_inode,
.destroy_inode = qnx6_destroy_inode,
.put_super = qnx6_put_super,
.remount_fs = qnx6_remount,
.show_options = qnx6_show_options,
static int qnx6_show_options(struct seq_file *seq, struct dentry *root)
struct super_block *sb = root->d_sb;
struct qnx6_sb_info *sbi = QNX6_SB(sb);
if (sbi->s_mount_opt & QNX6_MOUNT_MMI_FS)
seq_puts(seq, ",mmi_fs");
static int qnx6_remount(struct super_block *sb, int *flags, char *data)
static unsigned qnx6_get_devblock(struct super_block *sb, __fs32 block)
struct qnx6_sb_info *sbi = QNX6_SB(sb);
return fs32_to_cpu(sbi, block) + sbi->s_blks_off;
static unsigned qnx6_block_map(struct inode *inode, unsigned iblock);
static int qnx6_get_block(struct inode *inode, sector_t iblock,
struct buffer_head *bh, int create)
pr_debug("qnx6_get_block inode=[%ld] iblock=[%ld]\n",
inode->i_ino, (unsigned long)iblock);
phys = qnx6_block_map(inode, iblock);
map_bh(bh, inode->i_sb, phys);
static int qnx6_check_blockptr(__fs32 ptr)
pr_err("hit unused blockpointer.\n");