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: <20240825083515.4074081-1-wangzhaolong1@huawei.com>
Date: Sun, 25 Aug 2024 16:35:15 +0800
From: Wang Zhaolong <wangzhaolong1@...wei.com>
To: <richard@....at>, <miquel.raynal@...tlin.com>, <vigneshr@...com>
CC: <linux-mtd@...ts.infradead.org>, <linux-kernel@...r.kernel.org>,
	<wangzhaolong1@...wei.com>, <yi.zhang@...wei.com>
Subject: [PATCH] mtd: ubi: remove unused parameter 'pnum' from add_volume()

The parameter 'pnum' in the function add_volume() is not used inside the
function body. This patch removes this unused parameter to clean up the
code and improve readability.

This change does not affect the functionality of add_volume() or any other
part of the UBI subsystem, as the removed parameter is not utilized.

Signed-off-by: Wang Zhaolong <wangzhaolong1@...wei.com>
---
 drivers/mtd/ubi/attach.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/mtd/ubi/attach.c b/drivers/mtd/ubi/attach.c
index ae5abe492b52..fe9784c90ea4 100644
--- a/drivers/mtd/ubi/attach.c
+++ b/drivers/mtd/ubi/attach.c
@@ -393,8 +393,7 @@ static int validate_vid_hdr(const struct ubi_device *ubi,
  * to the allocated "av" object in case of success and a negative error code in
  * case of failure.
  */
-static struct ubi_ainf_volume *add_volume(struct ubi_attach_info *ai,
-					  int vol_id, int pnum,
+static struct ubi_ainf_volume *add_volume(struct ubi_attach_info *ai, int vol_id,
 					  const struct ubi_vid_hdr *vid_hdr)
 {
 	struct ubi_ainf_volume *av;
@@ -576,7 +575,7 @@ int ubi_add_to_av(struct ubi_device *ubi, struct ubi_attach_info *ai, int pnum,
 	dbg_bld("PEB %d, LEB %d:%d, EC %d, sqnum %llu, bitflips %d",
 		pnum, vol_id, lnum, ec, sqnum, bitflips);
 
-	av = add_volume(ai, vol_id, pnum, vid_hdr);
+	av = add_volume(ai, vol_id, vid_hdr);
 	if (IS_ERR(av))
 		return PTR_ERR(av);
 
-- 
2.34.3


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ