Re: [PATCH] scsi: ufs: Add checking lifetime attribute for WriteBooster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Jinyoung,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on mkp-scsi/for-next]
[also build test WARNING on jejb-scsi/for-next v5.17-rc1 next-20220125]
[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]

url:    https://github.com/0day-ci/linux/commits/Jinyoung-CHOI/scsi-ufs-Add-checking-lifetime-attribute-for-WriteBooster/20220127-064945
base:   https://git.kernel.org/pub/scm/linux/kernel/git/mkp/scsi.git for-next
config: alpha-allmodconfig (https://download.01.org/0day-ci/archive/20220127/202201270725.pB39Qr9M-lkp@xxxxxxxxx/config)
compiler: alpha-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/0day-ci/linux/commit/119120165af15780b5bdb5bf4bf59cfd8a2826ba
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Jinyoung-CHOI/scsi-ufs-Add-checking-lifetime-attribute-for-WriteBooster/20220127-064945
        git checkout 119120165af15780b5bdb5bf4bf59cfd8a2826ba
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=alpha SHELL=/bin/bash drivers/scsi/

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All warnings (new ones prefixed by >>):

   In file included from include/linux/device.h:15,
                    from include/linux/async.h:14,
                    from drivers/scsi/ufs/ufshcd.c:12:
   drivers/scsi/ufs/ufshcd.c: In function 'ufshcd_is_wb_buf_lifetime_available':
>> drivers/scsi/ufs/ufshcd.c:5811:35: warning: '0' flag ignored with precision and '%X' gnu_printf format [-Wformat=]
    5811 |                 dev_err(hba->dev, "%s: WB buf lifetime is exhausted 0x%0.2X\n",
         |                                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/dev_printk.h:110:30: note: in definition of macro 'dev_printk_index_wrap'
     110 |                 _p_func(dev, fmt, ##__VA_ARGS__);                       \
         |                              ^~~
   include/linux/dev_printk.h:144:56: note: in expansion of macro 'dev_fmt'
     144 |         dev_printk_index_wrap(_dev_err, KERN_ERR, dev, dev_fmt(fmt), ##__VA_ARGS__)
         |                                                        ^~~~~~~
   drivers/scsi/ufs/ufshcd.c:5811:17: note: in expansion of macro 'dev_err'
    5811 |                 dev_err(hba->dev, "%s: WB buf lifetime is exhausted 0x%0.2X\n",
         |                 ^~~~~~~
   In file included from include/linux/printk.h:555,
                    from include/asm-generic/bug.h:22,
                    from arch/alpha/include/asm/bug.h:23,
                    from include/linux/bug.h:5,
                    from include/linux/thread_info.h:13,
                    from include/asm-generic/current.h:5,
                    from ./arch/alpha/include/generated/asm/current.h:1,
                    from include/linux/sched.h:12,
                    from include/linux/ratelimit.h:6,
                    from include/linux/dev_printk.h:16,
                    from include/linux/device.h:15,
                    from include/linux/async.h:14,
                    from drivers/scsi/ufs/ufshcd.c:12:
   drivers/scsi/ufs/ufshcd.c:5816:27: warning: '0' flag ignored with precision and '%X' gnu_printf format [-Wformat=]
    5816 |         dev_dbg(hba->dev, "%s: WB buf lifetime is 0x%0.2X\n",
         |                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/dynamic_debug.h:134:29: note: in definition of macro '__dynamic_func_call'
     134 |                 func(&id, ##__VA_ARGS__);               \
         |                             ^~~~~~~~~~~
   include/linux/dynamic_debug.h:166:9: note: in expansion of macro '_dynamic_func_call'
     166 |         _dynamic_func_call(fmt,__dynamic_dev_dbg,               \
         |         ^~~~~~~~~~~~~~~~~~
   include/linux/dev_printk.h:155:9: note: in expansion of macro 'dynamic_dev_dbg'
     155 |         dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
         |         ^~~~~~~~~~~~~~~
   include/linux/dev_printk.h:155:30: note: in expansion of macro 'dev_fmt'
     155 |         dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
         |                              ^~~~~~~
   drivers/scsi/ufs/ufshcd.c:5816:9: note: in expansion of macro 'dev_dbg'
    5816 |         dev_dbg(hba->dev, "%s: WB buf lifetime is 0x%0.2X\n",
         |         ^~~~~~~


vim +5811 drivers/scsi/ufs/ufshcd.c

  5792	
  5793	static bool ufshcd_is_wb_buf_lifetime_available(struct ufs_hba *hba)
  5794	{
  5795		u32 lifetime;
  5796		int ret;
  5797		u8 index;
  5798	
  5799		index = ufshcd_wb_get_query_index(hba);
  5800		ret = ufshcd_query_attr_retry(hba, UPIU_QUERY_OPCODE_READ_ATTR,
  5801					      QUERY_ATTR_IDN_WB_BUFF_LIFE_TIME_EST,
  5802					      index, 0, &lifetime);
  5803		if (ret) {
  5804			dev_err(hba->dev,
  5805				"%s: bWriteBoosterBufferLifeTimeEst read failed %d\n",
  5806				__func__, ret);
  5807			return false;
  5808		}
  5809	
  5810		if (lifetime == UFS_WB_EXCEED_LIFETIME) {
> 5811			dev_err(hba->dev, "%s: WB buf lifetime is exhausted 0x%0.2X\n",
  5812				__func__, lifetime);
  5813			return false;
  5814		}
  5815	
  5816		dev_dbg(hba->dev, "%s: WB buf lifetime is 0x%0.2X\n",
  5817			__func__, lifetime);
  5818	
  5819		return true;
  5820	}
  5821	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux