All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Gao Xiang <hsiangkao@linux.alibaba.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: Re: [PATCH] erofs: simplify compression configuration parser
Date: Sat, 21 Oct 2023 11:31:18 +0800	[thread overview]
Message-ID: <202310211151.sklVyQL9-lkp@intel.com> (raw)
In-Reply-To: <20231021020109.1646299-1-hsiangkao@linux.alibaba.com>

Hi Gao,

kernel test robot noticed the following build warnings:

[auto build test WARNING on xiang-erofs/dev-test]
[also build test WARNING on xiang-erofs/dev xiang-erofs/fixes linus/master v6.6-rc6 next-20231020]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Gao-Xiang/erofs-simplify-compression-configuration-parser/20231021-100253
base:   https://git.kernel.org/pub/scm/linux/kernel/git/xiang/erofs.git dev-test
patch link:    https://lore.kernel.org/r/20231021020109.1646299-1-hsiangkao%40linux.alibaba.com
patch subject: [PATCH] erofs: simplify compression configuration parser
config: m68k-allyesconfig (https://download.01.org/0day-ci/archive/20231021/202310211151.sklVyQL9-lkp@intel.com/config)
compiler: m68k-linux-gcc (GCC) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231021/202310211151.sklVyQL9-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202310211151.sklVyQL9-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> fs/erofs/decompressor.c:27:5: warning: no previous prototype for 'z_erofs_load_lz4_config' [-Wmissing-prototypes]
      27 | int z_erofs_load_lz4_config(struct super_block *sb,
         |     ^~~~~~~~~~~~~~~~~~~~~~~


vim +/z_erofs_load_lz4_config +27 fs/erofs/decompressor.c

d67aee76d41861 Gao Xiang    2021-12-28  26  
5d50538fc567c6 Huang Jianan 2021-03-29 @27  int z_erofs_load_lz4_config(struct super_block *sb,
51fd9879fa6135 Gao Xiang    2023-10-21  28  			    struct erofs_super_block *dsb, void *data, int size)
5d50538fc567c6 Huang Jianan 2021-03-29  29  {
4fea63f7d76e42 Gao Xiang    2021-04-07  30  	struct erofs_sb_info *sbi = EROFS_SB(sb);
51fd9879fa6135 Gao Xiang    2023-10-21  31  	struct z_erofs_lz4_cfgs *lz4 = data;
46249cded18ac0 Gao Xiang    2021-03-29  32  	u16 distance;
46249cded18ac0 Gao Xiang    2021-03-29  33  
46249cded18ac0 Gao Xiang    2021-03-29  34  	if (lz4) {
46249cded18ac0 Gao Xiang    2021-03-29  35  		if (size < sizeof(struct z_erofs_lz4_cfgs)) {
46249cded18ac0 Gao Xiang    2021-03-29  36  			erofs_err(sb, "invalid lz4 cfgs, size=%u", size);
46249cded18ac0 Gao Xiang    2021-03-29  37  			return -EINVAL;
46249cded18ac0 Gao Xiang    2021-03-29  38  		}
46249cded18ac0 Gao Xiang    2021-03-29  39  		distance = le16_to_cpu(lz4->max_distance);
4fea63f7d76e42 Gao Xiang    2021-04-07  40  
4fea63f7d76e42 Gao Xiang    2021-04-07  41  		sbi->lz4.max_pclusterblks = le16_to_cpu(lz4->max_pclusterblks);
4fea63f7d76e42 Gao Xiang    2021-04-07  42  		if (!sbi->lz4.max_pclusterblks) {
4fea63f7d76e42 Gao Xiang    2021-04-07  43  			sbi->lz4.max_pclusterblks = 1;	/* reserved case */
4fea63f7d76e42 Gao Xiang    2021-04-07  44  		} else if (sbi->lz4.max_pclusterblks >
3acea5fc335420 Jingbo Xu    2023-03-13  45  			   erofs_blknr(sb, Z_EROFS_PCLUSTER_MAX_SIZE)) {
4fea63f7d76e42 Gao Xiang    2021-04-07  46  			erofs_err(sb, "too large lz4 pclusterblks %u",
4fea63f7d76e42 Gao Xiang    2021-04-07  47  				  sbi->lz4.max_pclusterblks);
4fea63f7d76e42 Gao Xiang    2021-04-07  48  			return -EINVAL;
4fea63f7d76e42 Gao Xiang    2021-04-07  49  		}
46249cded18ac0 Gao Xiang    2021-03-29  50  	} else {
14373711dd54be Gao Xiang    2021-03-29  51  		distance = le16_to_cpu(dsb->u1.lz4_max_distance);
4fea63f7d76e42 Gao Xiang    2021-04-07  52  		sbi->lz4.max_pclusterblks = 1;
46249cded18ac0 Gao Xiang    2021-03-29  53  	}
5d50538fc567c6 Huang Jianan 2021-03-29  54  
4fea63f7d76e42 Gao Xiang    2021-04-07  55  	sbi->lz4.max_distance_pages = distance ?
5d50538fc567c6 Huang Jianan 2021-03-29  56  					DIV_ROUND_UP(distance, PAGE_SIZE) + 1 :
5d50538fc567c6 Huang Jianan 2021-03-29  57  					LZ4_MAX_DISTANCE_PAGES;
4fea63f7d76e42 Gao Xiang    2021-04-07  58  	return erofs_pcpubuf_growsize(sbi->lz4.max_pclusterblks);
5d50538fc567c6 Huang Jianan 2021-03-29  59  }
5d50538fc567c6 Huang Jianan 2021-03-29  60  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

  reply	other threads:[~2023-10-21  3:31 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-21  2:01 [PATCH] erofs: simplify compression configuration parser Gao Xiang
2023-10-21  2:01 ` Gao Xiang
2023-10-21  3:31 ` kernel test robot [this message]
2023-10-22 13:09 ` [PATCH v2] " Gao Xiang
2023-10-22 13:09   ` Gao Xiang
2023-10-30 15:01   ` 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=202310211151.sklVyQL9-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=hsiangkao@linux.alibaba.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.