Skip to content

mm/damon/sysfs-schemes: fix wrong directories put orders in error paths

SeongJae Park damon linux-mm lkml stable 1 version Applied

Status from this message: [merged mm-hotfixes-stable] mm-damon-sysfs-schemes-put-stats-for-scheme_add_dirs-internal-error.patch removed from -mm tree

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 0 repliesApplied 2/2

Changes from RFC v1 from the cover letter

- RFC v1: https://lore.kernel.org/[email protected]
- Add damon_sysfs_access_pattern_add_dirs() fix.

Patches in v1 All 2 applied

#Subject and filesSizeRepliesApplied
1/2mm/damon/sysfs-schemes: fix dir put orders in access_pattern_add_dirs()mm/damon/sysfs-schemes.c+3 -60 repliesApplied
2/2mm/damon/sysfs-schemes: put stats for scheme_add_dirs() internal errormm/damon/sysfs-schemes.c+4 -40 repliesApplied

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2] mm/damon/sysfs-schemes: fix wrong directories put orders in error paths

Error paths of damon_sysfs_access_pattern_add_dirs() and damon_sysfs_scheme_add_dirs() functions put references to directories in wrong orders. As a result, uninitialized memory dereference and/or memory leak can happen. Fix those.

Changes from RFC v1.1
- RFC v1.1: https://lore.kernel.org/[email protected]
- Drop RFC tag.
- Rebase to latest mm-new.
Changes from RFC v1
- RFC v1: https://lore.kernel.org/[email protected]
- Add damon_sysfs_access_pattern_add_dirs() fix.

SeongJae Park (2):
mm/damon/sysfs-schemes: fix dir put orders in
access_pattern_add_dirs()
mm/damon/sysfs-schemes: put stats for scheme_add_dirs() internal error

 mm/damon/sysfs-schemes.c | 17 +++++++----------
 1 file changed, 7 insertions(+), 10 deletions(-)

base-commit: d20942f0d52b1cfa54931e00eeaaa2350ee46169

Signature · 1 line
2.47.3