tools/vm/slabinfo: Handle files in debugfs
authorStéphane Graber <stgraber@ubuntu.com>
Thu, 23 Jun 2022 21:45:52 +0000 (16:45 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 11 Aug 2022 11:07:50 +0000 (13:07 +0200)
commit9894717519cc144827bf8a46b543363533e8c0fe
treeaf3c6e7b102f834b1ccd2fb8a12491279a228d56
parent7ad47f414b4095fa104daaf08c8c942308f5a5c4
tools/vm/slabinfo: Handle files in debugfs

commit 0c7e0d699ef1430d7f4cf12b4b1d097af58b5515 upstream.

Commit 64dd68497be76 relocated and renamed the alloc_calls and
free_calls files from /sys/kernel/slab/NAME/*_calls over to
/sys/kernel/debug/slab/NAME/*_calls but didn't update the slabinfo tool
with the new location.

This change will now have slabinfo look at the new location (and filenames)
with a fallback to the prior files.

Fixes: 64dd68497be76 ("mm: slub: move sysfs slab alloc/free interfaces to debugfs")
Cc: stable@vger.kernel.org
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com>
Tested-by: Stéphane Graber <stgraber@ubuntu.com>
Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
tools/vm/slabinfo.c