#include <linux/list.h>
#include <linux/spinlock.h>
#include <linux/module.h>
#include <linux/slab.h>
#include <linux/kmod.h>
#include <linux/fs.h>
#include <linux/kobject.h>
#include <linux/sysfs.h>
#include <linux/sysctl.h>
#include <cluster/masklog.h>
#include "ocfs2.h"
#include "ocfs2_fs.h"
#include "stackglue.h"
#include "inode.h"
#include "filecheck.h"
static const char * const ocfs2_filecheck_errs[] = …;
struct ocfs2_filecheck_entry { … };
struct ocfs2_filecheck_args { … };
static const char *
ocfs2_filecheck_error(int errno)
{ … }
static ssize_t ocfs2_filecheck_attr_show(struct kobject *kobj,
struct kobj_attribute *attr,
char *buf);
static ssize_t ocfs2_filecheck_attr_store(struct kobject *kobj,
struct kobj_attribute *attr,
const char *buf, size_t count);
static struct kobj_attribute ocfs2_filecheck_attr_chk = …;
static struct kobj_attribute ocfs2_filecheck_attr_fix = …;
static struct kobj_attribute ocfs2_filecheck_attr_set = …;
static struct attribute *ocfs2_filecheck_attrs[] = …;
ATTRIBUTE_GROUPS(…);
static void ocfs2_filecheck_release(struct kobject *kobj)
{ … }
static ssize_t
ocfs2_filecheck_show(struct kobject *kobj, struct attribute *attr, char *buf)
{ … }
static ssize_t
ocfs2_filecheck_store(struct kobject *kobj, struct attribute *attr,
const char *buf, size_t count)
{ … }
static const struct sysfs_ops ocfs2_filecheck_ops = …;
static struct kobj_type ocfs2_ktype_filecheck = …;
static void
ocfs2_filecheck_sysfs_free(struct ocfs2_filecheck_sysfs_entry *entry)
{ … }
int ocfs2_filecheck_create_sysfs(struct ocfs2_super *osb)
{ … }
void ocfs2_filecheck_remove_sysfs(struct ocfs2_super *osb)
{ … }
static int
ocfs2_filecheck_erase_entries(struct ocfs2_filecheck_sysfs_entry *ent,
unsigned int count);
static int
ocfs2_filecheck_adjust_max(struct ocfs2_filecheck_sysfs_entry *ent,
unsigned int len)
{ … }
#define OCFS2_FILECHECK_ARGS_LEN …
static int
ocfs2_filecheck_args_get_long(const char *buf, size_t count,
unsigned long *val)
{ … }
static int
ocfs2_filecheck_type_parse(const char *name, unsigned int *type)
{ … }
static int
ocfs2_filecheck_args_parse(const char *name, const char *buf, size_t count,
struct ocfs2_filecheck_args *args)
{ … }
static ssize_t ocfs2_filecheck_attr_show(struct kobject *kobj,
struct kobj_attribute *attr,
char *buf)
{ … }
static inline int
ocfs2_filecheck_is_dup_entry(struct ocfs2_filecheck_sysfs_entry *ent,
unsigned long ino)
{ … }
static inline int
ocfs2_filecheck_erase_entry(struct ocfs2_filecheck_sysfs_entry *ent)
{ … }
static int
ocfs2_filecheck_erase_entries(struct ocfs2_filecheck_sysfs_entry *ent,
unsigned int count)
{ … }
static void
ocfs2_filecheck_done_entry(struct ocfs2_filecheck_sysfs_entry *ent,
struct ocfs2_filecheck_entry *entry)
{ … }
static unsigned int
ocfs2_filecheck_handle(struct ocfs2_super *osb,
unsigned long ino, unsigned int flags)
{ … }
static void
ocfs2_filecheck_handle_entry(struct ocfs2_filecheck_sysfs_entry *ent,
struct ocfs2_filecheck_entry *entry)
{ … }
static ssize_t ocfs2_filecheck_attr_store(struct kobject *kobj,
struct kobj_attribute *attr,
const char *buf, size_t count)
{ … }