Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 215752fc authored by Al Viro's avatar Al Viro
Browse files

acct: get rid of acct_list



Put these suckers on per-vfsmount and per-superblock lists instead.
Note: right now it's still acct_lock for everything, but that's
going to change.

Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
parent 54a4d58a
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -56,6 +56,7 @@ struct mount {
	int mnt_group_id;		/* peer group identifier */
	int mnt_expiry_mark;		/* true if marked for expiry */
	int mnt_pinned;
	struct hlist_head mnt_pins;
	struct path mnt_ex_mountpoint;
};

+1 −1
Original line number Diff line number Diff line
@@ -956,7 +956,7 @@ static void mntput_no_expire(struct mount *mnt)
		mnt->mnt_pinned = 0;
		rcu_read_unlock();
		unlock_mount_hash();
		acct_auto_close_mnt(&mnt->mnt);
		acct_auto_close_mnt(&mnt->mnt_pins);
		goto put_again;
	}
	if (unlikely(mnt->mnt.mnt_flags & MNT_DOOMED)) {
+1 −1
Original line number Diff line number Diff line
@@ -703,7 +703,7 @@ int do_remount_sb(struct super_block *sb, int flags, void *data, int force)
#endif

	if (flags & MS_RDONLY)
		acct_auto_close(sb);
		acct_auto_close(&sb->s_pins);
	shrink_dcache_sb(sb);

	remount_ro = (flags & MS_RDONLY) && !(sb->s_flags & MS_RDONLY);
+3 −3
Original line number Diff line number Diff line
@@ -24,14 +24,14 @@ struct super_block;
struct pacct_struct;
struct pid_namespace;
extern int acct_parm[]; /* for sysctl */
extern void acct_auto_close_mnt(struct vfsmount *m);
extern void acct_auto_close(struct super_block *sb);
extern void acct_auto_close(struct hlist_head *);
extern void acct_auto_close_mnt(struct hlist_head *);
extern void acct_collect(long exitcode, int group_dead);
extern void acct_process(void);
extern void acct_exit_ns(struct pid_namespace *);
#else
#define acct_auto_close_mnt(x)	do { } while (0)
#define acct_auto_close(x)	do { } while (0)
#define acct_auto_close_mnt(x)	do { } while (0)
#define acct_collect(x,y)	do { } while (0)
#define acct_process()		do { } while (0)
#define acct_exit_ns(ns)	do { } while (0)
+1 −0
Original line number Diff line number Diff line
@@ -1250,6 +1250,7 @@ struct super_block {

	/* AIO completions deferred from interrupt context */
	struct workqueue_struct *s_dio_done_wq;
	struct hlist_head s_pins;

	/*
	 * Keep the lru lists last in the structure so they always sit on their
Loading