|
@@ -84,6 +84,8 @@ struct fsnotify_event_private_data;
|
|
struct fsnotify_fname;
|
|
struct fsnotify_fname;
|
|
struct fsnotify_iter_info;
|
|
struct fsnotify_iter_info;
|
|
|
|
|
|
|
|
+struct mem_cgroup;
|
|
|
|
+
|
|
/*
|
|
/*
|
|
* Each group much define these ops. The fsnotify infrastructure will call
|
|
* Each group much define these ops. The fsnotify infrastructure will call
|
|
* these operations for each relevant group.
|
|
* these operations for each relevant group.
|
|
@@ -127,6 +129,8 @@ struct fsnotify_event {
|
|
* everything will be cleaned up.
|
|
* everything will be cleaned up.
|
|
*/
|
|
*/
|
|
struct fsnotify_group {
|
|
struct fsnotify_group {
|
|
|
|
+ const struct fsnotify_ops *ops; /* how this group handles things */
|
|
|
|
+
|
|
/*
|
|
/*
|
|
* How the refcnt is used is up to each group. When the refcnt hits 0
|
|
* How the refcnt is used is up to each group. When the refcnt hits 0
|
|
* fsnotify will clean up all of the resources associated with this group.
|
|
* fsnotify will clean up all of the resources associated with this group.
|
|
@@ -137,8 +141,6 @@ struct fsnotify_group {
|
|
*/
|
|
*/
|
|
refcount_t refcnt; /* things with interest in this group */
|
|
refcount_t refcnt; /* things with interest in this group */
|
|
|
|
|
|
- const struct fsnotify_ops *ops; /* how this group handles things */
|
|
|
|
-
|
|
|
|
/* needed to send notification to userspace */
|
|
/* needed to send notification to userspace */
|
|
spinlock_t notification_lock; /* protect the notification_list */
|
|
spinlock_t notification_lock; /* protect the notification_list */
|
|
struct list_head notification_list; /* list of event_holder this group needs to send to userspace */
|
|
struct list_head notification_list; /* list of event_holder this group needs to send to userspace */
|
|
@@ -160,6 +162,8 @@ struct fsnotify_group {
|
|
atomic_t num_marks; /* 1 for each mark and 1 for not being
|
|
atomic_t num_marks; /* 1 for each mark and 1 for not being
|
|
* past the point of no return when freeing
|
|
* past the point of no return when freeing
|
|
* a group */
|
|
* a group */
|
|
|
|
+ atomic_t user_waits; /* Number of tasks waiting for user
|
|
|
|
+ * response */
|
|
struct list_head marks_list; /* all inode marks for this group */
|
|
struct list_head marks_list; /* all inode marks for this group */
|
|
|
|
|
|
struct fasync_struct *fsn_fa; /* async notification */
|
|
struct fasync_struct *fsn_fa; /* async notification */
|
|
@@ -167,8 +171,8 @@ struct fsnotify_group {
|
|
struct fsnotify_event *overflow_event; /* Event we queue when the
|
|
struct fsnotify_event *overflow_event; /* Event we queue when the
|
|
* notification list is too
|
|
* notification list is too
|
|
* full */
|
|
* full */
|
|
- atomic_t user_waits; /* Number of tasks waiting for user
|
|
|
|
- * response */
|
|
|
|
|
|
+
|
|
|
|
+ struct mem_cgroup *memcg; /* memcg to charge allocations */
|
|
|
|
|
|
/* groups can define private fields here or use the void *private */
|
|
/* groups can define private fields here or use the void *private */
|
|
union {
|
|
union {
|