lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240823061824.3323522-1-lizetao1@huawei.com>
Date: Fri, 23 Aug 2024 14:18:21 +0800
From: Li Zetao <lizetao1@...wei.com>
To: <tytso@....edu>, <adilger.kernel@...ger.ca>
CC: <lizetao1@...wei.com>, <linux-ext4@...r.kernel.org>
Subject: [PATCH -next 0/3] ext4: Using scope-based resource management function

Hi all,

This patch set is dedicated to using scope-based resource management
functions to replace the direct use of lock/unlock methods, so that
developers can focus more on using resources in a certain scope and
avoid overly focusing on resource leakage issues.

At the same time, some functions can remove the controversial goto
label(eg: patch 3), which usually only releases resources and then
exits the function. After replacement, these functions can exit
directly without worrying about resources not being released.

This patch set has been tested by fsstress for a long time and no
problems were found.

Thanks,
Li Zetao.

Li Zetao (3):
  ext4: Use scoped()/scoped_guard() to drop read_lock()/unlock pair
  ext4: Use scoped()/scoped_guard() to drop write_lock()/unlock pair
  ext4: Use scoped()/scoped_guard() to drop rcu_read_lock()/unlock pair

 fs/ext4/block_validity.c |  27 +++--
 fs/ext4/ext4.h           |   3 +-
 fs/ext4/extents_status.c |  67 +++++--------
 fs/ext4/fast_commit.c    |   3 +-
 fs/ext4/inode.c          |  14 ++-
 fs/ext4/mballoc.c        | 208 +++++++++++++++++----------------------
 fs/ext4/resize.c         |  20 ++--
 fs/ext4/super.c          |  29 +++---
 8 files changed, 158 insertions(+), 213 deletions(-)

-- 
2.34.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ