mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Zhihao Cheng <chengzhihao1@huawei.com>
To: Xichao Zhao <zhao.xichao@vivo.com>,
	Richard Weinberger <richard@nod.at>,
	"open list:UBI FILE SYSTEM (UBIFS)"
	<linux-mtd@lists.infradead.org>,
	open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2 1/2] ubifs: Remove unnecessary parameters '*c'
Date: Tue, 12 Aug 2025 11:06:20 +0800	[thread overview]
Message-ID: <be8c49cd-82e9-10ff-30d6-f5dfd461d731@huawei.com> (raw)
In-Reply-To: <20250812021009.414756-2-zhao.xichao@vivo.com>

在 2025/8/12 10:10, Xichao Zhao 写道:
> Because the variable *c is not used within the function,
> remove it from the ubifs_crc_node function.
> 
> Signed-off-by: Xichao Zhao <zhao.xichao@vivo.com>
> ---
>   fs/ubifs/io.c    | 4 ++--
>   fs/ubifs/ubifs.h | 2 +-
>   2 files changed, 3 insertions(+), 3 deletions(-)

Reviewed-by: Zhihao Cheng <chengzhihao1@huawei.com>
> 
> diff --git a/fs/ubifs/io.c b/fs/ubifs/io.c
> index a79f229df475..e0dfe6827d65 100644
> --- a/fs/ubifs/io.c
> +++ b/fs/ubifs/io.c
> @@ -395,7 +395,7 @@ void ubifs_init_node(struct ubifs_info *c, void *node, int len, int pad)
>   	}
>   }
>   
> -void ubifs_crc_node(struct ubifs_info *c, void *node, int len)
> +void ubifs_crc_node(void *node, int len)
>   {
>   	struct ubifs_ch *ch = node;
>   	uint32_t crc;
> @@ -432,7 +432,7 @@ int ubifs_prepare_node_hmac(struct ubifs_info *c, void *node, int len,
>   			return err;
>   	}
>   
> -	ubifs_crc_node(c, node, len);
> +	ubifs_crc_node(node, len);
>   
>   	return 0;
>   }
> diff --git a/fs/ubifs/ubifs.h b/fs/ubifs/ubifs.h
> index 5db45c9e26ee..5d172509091a 100644
> --- a/fs/ubifs/ubifs.h
> +++ b/fs/ubifs/ubifs.h
> @@ -1743,7 +1743,7 @@ int ubifs_write_node_hmac(struct ubifs_info *c, void *buf, int len, int lnum,
>   int ubifs_check_node(const struct ubifs_info *c, const void *buf, int len,
>   		     int lnum, int offs, int quiet, int must_chk_crc);
>   void ubifs_init_node(struct ubifs_info *c, void *buf, int len, int pad);
> -void ubifs_crc_node(struct ubifs_info *c, void *buf, int len);
> +void ubifs_crc_node(void *buf, int len);
>   void ubifs_prepare_node(struct ubifs_info *c, void *buf, int len, int pad);
>   int ubifs_prepare_node_hmac(struct ubifs_info *c, void *node, int len,
>   			    int hmac_offs, int pad);
> 


  reply	other threads:[~2025-08-12  3:06 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-08-12  2:10 [PATCH v2 0/2] ubifs: Simplify the code and remove unnecessary parameters Xichao Zhao
2025-08-12  2:10 ` [PATCH v2 1/2] ubifs: Remove unnecessary parameters '*c' Xichao Zhao
2025-08-12  3:06   ` Zhihao Cheng [this message]
2025-08-12  2:10 ` [PATCH v2 2/2] ubifs: Simplify the code using ubifs_crc_node Xichao Zhao
2025-08-12  3:06   ` Zhihao Cheng

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=be8c49cd-82e9-10ff-30d6-f5dfd461d731@huawei.com \
    --to=chengzhihao1@huawei.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=richard@nod.at \
    --cc=zhao.xichao@vivo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®