alistair23-linux/kernel/cgroup
Tejun Heo fe0f726c9f kernfs: combine ino/id lookup functions into kernfs_find_and_get_node_by_id()
kernfs_find_and_get_node_by_ino() looks the kernfs_node matching the
specified ino.  On top of that, kernfs_get_node_by_id() and
kernfs_fh_get_inode() implement full ID matching by testing the rest
of ID.

On surface, confusingly, the two are slightly different in that the
latter uses 0 gen as wildcard while the former doesn't - does it mean
that the latter can't uniquely identify inodes w/ 0 gen?  In practice,
this is a distinction without a difference because generation number
starts at 1.  There are no actual IDs with 0 gen, so it can always
safely used as wildcard.

Let's simplify the code by renaming kernfs_find_and_get_node_by_ino()
to kernfs_find_and_get_node_by_id(), moving all lookup logics into it,
and removing now unnecessary kernfs_get_node_by_id().

Signed-off-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-11-12 08:18:04 -08:00
..
cgroup-internal.h cgroup: Optimize single thread migration 2019-10-07 07:11:53 -07:00
cgroup-v1.c cgroup: Optimize single thread migration 2019-10-07 07:11:53 -07:00
cgroup.c kernfs: combine ino/id lookup functions into kernfs_find_and_get_node_by_id() 2019-11-12 08:18:04 -08:00
cpuset.c cgroup: remove cgroup_enable_task_cg_lists() optimization 2019-10-25 05:56:28 -07:00
debug.c kernel: cgroup: fix misuse of %x 2019-05-06 08:47:48 -07:00
freezer.c cgroup: freezer: don't change task and cgroups status unnecessarily 2019-11-07 07:38:41 -08:00
legacy_freezer.c cgroup: rename freezer.c into legacy_freezer.c 2019-04-19 11:26:48 -07:00
Makefile cgroup: cgroup v2 freezer 2019-04-19 11:26:48 -07:00
namespace.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
pids.c cgroup: pids: use atomic64_t for pids->limit 2019-10-24 12:07:10 -07:00
rdma.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 451 2019-06-19 17:09:08 +02:00
rstat.c cgroup: use cgroup->last_bstat instead of cgroup->bstat_pending for consistency 2019-11-06 12:50:15 -08:00