mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* drivers/dma/qcom/gpi.c:1254:15: warning: iteration 2 invokes undefined behavior
@ 2021-01-02  0:41 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-01-02  0:41 UTC (permalink / raw)
  To: Vinod Koul; +Cc: kbuild-all, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 2057 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   eda809aef53426d044b519405d25d9da55319b76
commit: 5d0c3533a19f48e5e7e73806a3e4b29cd4364130 dmaengine: qcom: Add GPI dma driver
date:   5 weeks ago
config: arm64-randconfig-p002-20210102 (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.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://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=5d0c3533a19f48e5e7e73806a3e4b29cd4364130
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout 5d0c3533a19f48e5e7e73806a3e4b29cd4364130
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm64 

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

All warnings (new ones prefixed by >>):

   drivers/dma/qcom/gpi.c: In function 'gpi_alloc_chan_resources':
>> drivers/dma/qcom/gpi.c:1254:15: warning: iteration 2 invokes undefined behavior [-Waggressive-loop-optimizations]
    1254 |  struct gpii *gpii = gchan->gpii;
         |               ^~~~
   drivers/dma/qcom/gpi.c:1951:2: note: within this loop
    1951 |  for (i = i - 1; i >= 0; i++) {
         |  ^~~


vim +1254 drivers/dma/qcom/gpi.c

  1251	
  1252	static int gpi_stop_chan(struct gchan *gchan)
  1253	{
> 1254		struct gpii *gpii = gchan->gpii;
  1255		int ret;
  1256	
  1257		ret = gpi_send_cmd(gpii, gchan, GPI_CH_CMD_STOP);
  1258		if (ret) {
  1259			dev_err(gpii->gpi_dev->dev, "Error with cmd:%s ret:%d\n",
  1260				TO_GPI_CMD_STR(GPI_CH_CMD_STOP), ret);
  1261			return ret;
  1262		}
  1263	
  1264		return 0;
  1265	}
  1266	

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

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 31831 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-01-02  0:43 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-02  0:41 drivers/dma/qcom/gpi.c:1254:15: warning: iteration 2 invokes undefined behavior kernel test robot

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®