summaryrefslogtreecommitdiff
path: root/security
diff options
context:
space:
mode:
authorTejun Heo <tj@kernel.org>2022-01-06 11:02:29 -1000
committerTejun Heo <tj@kernel.org>2022-01-06 11:02:29 -1000
commit0d2b5955b36250a9428c832664f2079cbf723bec (patch)
tree333a3aec9300107bcf9bc68fc59643ae93da55bf /security
parent1756d7994ad85c2479af6ae5a9750b92324685af (diff)
cgroup: Allocate cgroup_file_ctx for kernfs_open_file->priv
of->priv is currently used by each interface file implementation to store private information. This patch collects the current two private data usages into struct cgroup_file_ctx which is allocated and freed by the common path. This allows generic private data which applies to multiple files, which will be used to in the following patch. Note that cgroup_procs iterator is now embedded as procs.iter in the new cgroup_file_ctx so that it doesn't need to be allocated and freed separately. v2: union dropped from cgroup_file_ctx and the procs iterator is embedded in cgroup_file_ctx as suggested by Linus. v3: Michal pointed out that cgroup1's procs pidlist uses of->priv too. Converted. Didn't change to embedded allocation as cgroup1 pidlists get stored for caching. Signed-off-by: Tejun Heo <tj@kernel.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Reviewed-by: Michal Koutný <mkoutny@suse.com>
Diffstat (limited to 'security')
0 files changed, 0 insertions, 0 deletions