public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Chao Yu <chao@kernel.org>
To: Yangtao Li <frank.li@vivo.com>, Jaegeuk Kim <jaegeuk@kernel.org>
Cc: linux-f2fs-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] f2fs: merge lz4hc_compress_pages() to lz4_compress_pages()
Date: Wed, 5 Apr 2023 10:42:02 +0800	[thread overview]
Message-ID: <a6d9887f-1ff0-fd43-85ff-e6fee87bbe84@kernel.org> (raw)
In-Reply-To: <20230330164948.29644-1-frank.li@vivo.com>

On 2023/3/31 0:49, Yangtao Li wrote:
> +#ifdef CONFIG_F2FS_FS_LZ4HC
> +	unsigned char level = F2FS_I(cc->inode)->i_compress_level;
>   
>   	if (level)
>   		len = LZ4_compress_HC(cc->rbuf, cc->cbuf->cdata, cc->rlen,
>   					cc->clen, level, cc->private);
>   	else

[snip]

>   #endif

[snip]

> +		len = LZ4_compress_default(cc->rbuf, cc->cbuf->cdata, cc->rlen,

It's weired that whole else xxx; statement is split by #endif.

What about?

	unsigned char level = 0;

#if
...
#endif
	if (!level)
		len = LZ4_compress_default()

Thanks,

>   						cc->clen, cc->private);
>   	if (!len)
>   		return -EAGAIN;

  reply	other threads:[~2023-04-05  2:42 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-30 16:49 [PATCH v2] f2fs: merge lz4hc_compress_pages() to lz4_compress_pages() Yangtao Li
2023-04-05  2:42 ` Chao Yu [this message]
2023-04-05 16:13   ` Jaegeuk Kim
2023-04-07  1:22     ` Chao Yu

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=a6d9887f-1ff0-fd43-85ff-e6fee87bbe84@kernel.org \
    --to=chao@kernel.org \
    --cc=frank.li@vivo.com \
    --cc=jaegeuk@kernel.org \
    --cc=linux-f2fs-devel@lists.sourceforge.net \
    --cc=linux-kernel@vger.kernel.org \
    /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