Re: [PATCH 4/6] qla2xxx_nvmet: Add FC-NVMe Target handling

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

 



Hi Anil,

I love your patch! Perhaps something to improve:

[auto build test WARNING on scsi/for-next]
[also build test WARNING on next-20180913]
[cannot apply to v4.19-rc3]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Himanshu-Madhani/qla2xxx-Add-FC-NVMe-Target-support/20180916-090108
base:   https://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi.git for-next
config: xtensa-allmodconfig (attached as .config)
compiler: xtensa-linux-gcc (GCC) 8.1.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        GCC_VERSION=8.1.0 make.cross ARCH=xtensa 

All warnings (new ones prefixed by >>):

   drivers/scsi/qla2xxx/qla_target.c: In function 'qlt_send_plogi_resp':
>> drivers/scsi/qla2xxx/qla_target.c:480:63: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 8 has type 'dma_addr_t' {aka 'unsigned int'} [-Wformat=]
         "sp: %p, vha: %p, plogi_ack_buf: %p, plogi_ack_udma: %#llx\n",
                                                              ~~~~^
                                                              %#x
         sp, vha, plogi_ack_buf, plogi_ack_udma);
                                 ~~~~~~~~~~~~~~                    
   drivers/scsi/qla2xxx/qla_target.c: In function 'qlt_process_logo':
   drivers/scsi/qla2xxx/qla_target.c:693:60: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 8 has type 'dma_addr_t' {aka 'unsigned int'} [-Wformat=]
         "sp: %p, vha: %p, logo_ack_buf: %p, logo_ack_buf: %#llx\n",
                                                           ~~~~^
                                                           %#x
         sp, vha, logo_ack_buf, logo_ack_udma);
                                ~~~~~~~~~~~~~                   

vim +480 drivers/scsi/qla2xxx/qla_target.c

   456	
   457	static int qlt_send_plogi_resp(struct scsi_qla_host *vha, uint8_t op_code,
   458		struct purex_entry_24xx *purex, struct fc_port *fcport)
   459	{
   460		int ret, rval, i;
   461		dma_addr_t plogi_ack_udma = vha->vha_tgt.qla_tgt->nvme_els_rsp;
   462		void *plogi_ack_buf = vha->vha_tgt.qla_tgt->nvme_els_ptr;
   463		uint8_t *tmp;
   464		uint32_t *opcode;
   465		srb_t *sp;
   466	
   467		/* Alloc SRB structure */
   468		sp = qla2x00_get_sp(vha, fcport, GFP_KERNEL);
   469		if (!sp) {
   470			ql_log(ql_log_info, vha, 0x11033,
   471			    "Failed to allocate SRB\n");
   472			return -ENOMEM;
   473		}
   474	
   475		sp->type = SRB_NVME_ELS_RSP;
   476		sp->done = qlt_nvme_els_done;
   477		sp->vha = vha;
   478	
   479		ql_log(ql_log_info, vha, 0x11034,
 > 480		    "sp: %p, vha: %p, plogi_ack_buf: %p, plogi_ack_udma: %#llx\n",
   481		    sp, vha, plogi_ack_buf, plogi_ack_udma);
   482	
   483		sp->u.snvme_els.dma_addr = plogi_ack_udma;
   484		sp->u.snvme_els.dma_ptr = plogi_ack_buf;
   485		sp->gen1 = 116;
   486		sp->gen2 = ELS_ACC;
   487		sp->u.snvme_els.ptr = (struct purex_entry_24xx *)purex;
   488		sp->cmd_type = ELS_PLOGI;
   489	
   490		tmp = (uint8_t *)plogi_ack_udma;
   491	
   492		tmp += 4;	/* fw doesn't return 1st 4 bytes where opcode goes */
   493	
   494		ret = qla2x00_get_plogi_template(vha, (dma_addr_t)tmp, (116/4 - 1));
   495		if (ret) {
   496			ql_log(ql_log_warn, vha, 0x11035,
   497			    "Failed to get plogi template\n");
   498			return -ENOMEM;
   499		}
   500	
   501		opcode = (uint32_t *) plogi_ack_buf;
   502		*opcode = cpu_to_be32(ELS_ACC << 24);
   503	
   504		for (i = 0; i < 0x1c; i++) {
   505			++opcode;
   506			*opcode = cpu_to_be32(*opcode);
   507		}
   508	
   509		ql_dbg(ql_dbg_disc + ql_dbg_verbose, vha, 0xfff3,
   510		    "Dumping the PLOGI from fw\n");
   511		ql_dump_buffer(ql_dbg_disc + ql_dbg_verbose, vha, 0x70cf,
   512			(uint8_t *)plogi_ack_buf, 116);
   513	
   514		rval = qla2x00_start_sp(sp);
   515		if (rval != QLA_SUCCESS)
   516			qla2x00_rel_sp(sp);
   517	
   518		return 0;
   519	}
   520	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip


[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