[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202108172136.lNRSutvc-lkp@intel.com>
Date: Tue, 17 Aug 2021 21:53:43 +0800
From: kernel test robot <lkp@...el.com>
To: Hannes Reinecke <hare@...e.de>
Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: [hare-scsi-devel:eh-rework.v2 33/51]
drivers/scsi/bfa/bfad_im.c:371:30: warning: variable 'itnim' set but not
used
tree: https://git.kernel.org/pub/scm/linux/kernel/git/hare/scsi-devel.git eh-rework.v2
head: 7603e2e1f37e470064b8c865b5d6470137baa79b
commit: fa7da686b96cd50ff111019e1d05aa05c22690c6 [33/51] bfa: Do not use scsi command to signal TMF status
config: s390-allyesconfig (attached as .config)
compiler: s390-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://git.kernel.org/pub/scm/linux/kernel/git/hare/scsi-devel.git/commit/?id=fa7da686b96cd50ff111019e1d05aa05c22690c6
git remote add hare-scsi-devel https://git.kernel.org/pub/scm/linux/kernel/git/hare/scsi-devel.git
git fetch --no-tags hare-scsi-devel eh-rework.v2
git checkout fa7da686b96cd50ff111019e1d05aa05c22690c6
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=s390
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
All warnings (new ones prefixed by >>):
drivers/scsi/bfa/bfad_im.c: In function 'bfad_im_reset_target_handler':
>> drivers/scsi/bfa/bfad_im.c:371:30: warning: variable 'itnim' set but not used [-Wunused-but-set-variable]
371 | struct bfad_itnim_s *itnim;
| ^~~~~
vim +/itnim +371 drivers/scsi/bfa/bfad_im.c
360
361 /*
362 * Scsi_Host template entry, resets the target and abort all commands.
363 */
364 static int
365 bfad_im_reset_target_handler(struct scsi_cmnd *cmnd)
366 {
367 struct scsi_target *starget = scsi_target(cmnd->device);
368 struct fc_rport *rport = starget_to_rport(starget);
369 struct Scsi_Host *shost = rport_to_shost(rport);
370 struct bfad_itnim_data_s *itnim_data;
> 371 struct bfad_itnim_s *itnim;
372 struct bfad_im_port_s *im_port =
373 (struct bfad_im_port_s *) shost->hostdata[0];
374 struct bfad_s *bfad = im_port->bfad;
375 unsigned long flags;
376 u32 rc, rtn = FAILED;
377 DECLARE_WAIT_QUEUE_HEAD_ONSTACK(wq);
378 enum bfi_tskim_status task_status;
379
380 spin_lock_irqsave(&bfad->bfad_lock, flags);
381 if (!rport->dd_data) {
382 spin_unlock_irqrestore(&bfad->bfad_lock, flags);
383 return rtn;
384 }
385 itnim_data = rport->dd_data;
386 if (itnim_data->tmf_wq) {
387 BFA_LOG(KERN_ERR, bfad, bfa_log_level,
388 "target reset failed, TMF already active");
389 spin_unlock_irqrestore(&bfad->bfad_lock, flags);
390 return rtn;
391 }
392 itnim = itnim_data->itnim;
393
394 itnim_data->tmf_wq = &wq;
395 itnim_data->tmf_status = 0;
396 rc = bfad_im_target_reset_send(bfad, itnim_data);
397 if (rc == BFA_STATUS_OK) {
398 /* wait target reset to complete */
399 spin_unlock_irqrestore(&bfad->bfad_lock, flags);
400 wait_event(wq, test_bit(IO_DONE_BIT, &itnim_data->tmf_status));
401 spin_lock_irqsave(&bfad->bfad_lock, flags);
402
403 task_status = itnim_data->tmf_status >> 1;
404 if (task_status != BFI_TSKIM_STS_OK)
405 BFA_LOG(KERN_ERR, bfad, bfa_log_level,
406 "target reset failure,"
407 " status: %d\n", task_status);
408 else
409 rtn = SUCCESS;
410 }
411 spin_unlock_irqrestore(&bfad->bfad_lock, flags);
412
413 return rtn;
414 }
415
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Download attachment ".config.gz" of type "application/gzip" (66809 bytes)
Powered by blists - more mailing lists