Re: [PATCH 07/11] qla2xxx: Avoid side effects when using endianizer macros.

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

 



Hi Joe,

[auto build test WARNING on scsi/for-next]
[also build test WARNING on v4.5-rc1 next-20160125]
[if your patch is applied to the wrong git tree, please drop us a note to help improving the system]

url:    https://github.com/0day-ci/linux/commits/Himanshu-Madhani/qla2xxx-Remove-unneeded-link-offline-message/20160127-015650
base:   https://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi.git for-next
config: xtensa-allyesconfig (attached as .config)
reproduce:
        wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        make.cross ARCH=xtensa 

All warnings (new ones prefixed by >>):

   In file included from include/linux/byteorder/big_endian.h:4:0,
                    from arch/xtensa/include/uapi/asm/byteorder.h:7,
                    from arch/xtensa/include/asm/bitops.h:23,
                    from include/linux/bitops.h:36,
                    from include/linux/kernel.h:10,
                    from drivers/scsi/qla2xxx/qla_def.h:10,
                    from drivers/scsi/qla2xxx/qla_mbx.c:7:
   drivers/scsi/qla2xxx/qla_mbx.c: In function 'qla2x00_get_link_status':
>> include/uapi/linux/byteorder/big_endian.h:94:27: warning: passing argument 1 of '__swab32s' makes pointer from integer without a cast
    #define __le32_to_cpus(x) __swab32s((x))
                              ^
>> include/linux/byteorder/generic.h:112:22: note: in expansion of macro '__le32_to_cpus'
    #define le32_to_cpus __le32_to_cpus
                         ^
>> drivers/scsi/qla2xxx/qla_mbx.c:2806:5: note: in expansion of macro 'le32_to_cpus'
        le32_to_cpus(*iter);
        ^
   In file included from include/linux/swab.h:4:0,
                    from include/uapi/linux/byteorder/big_endian.h:12,
                    from include/linux/byteorder/big_endian.h:4,
                    from arch/xtensa/include/uapi/asm/byteorder.h:7,
                    from arch/xtensa/include/asm/bitops.h:23,
                    from include/linux/bitops.h:36,
                    from include/linux/kernel.h:10,
                    from drivers/scsi/qla2xxx/qla_def.h:10,
                    from drivers/scsi/qla2xxx/qla_mbx.c:7:
   include/uapi/linux/swab.h:235:20: note: expected '__u32 *' but argument is of type 'uint32_t'
    static inline void __swab32s(__u32 *p)
                       ^
   In file included from include/linux/byteorder/big_endian.h:4:0,
                    from arch/xtensa/include/uapi/asm/byteorder.h:7,
                    from arch/xtensa/include/asm/bitops.h:23,
                    from include/linux/bitops.h:36,
                    from include/linux/kernel.h:10,
                    from drivers/scsi/qla2xxx/qla_def.h:10,
                    from drivers/scsi/qla2xxx/qla_mbx.c:7:
   drivers/scsi/qla2xxx/qla_mbx.c: In function 'qla24xx_get_isp_stats':
>> include/uapi/linux/byteorder/big_endian.h:94:27: warning: passing argument 1 of '__swab32s' makes pointer from integer without a cast
    #define __le32_to_cpus(x) __swab32s((x))
                              ^
>> include/linux/byteorder/generic.h:112:22: note: in expansion of macro '__le32_to_cpus'
    #define le32_to_cpus __le32_to_cpus
                         ^
   drivers/scsi/qla2xxx/qla_mbx.c:2854:5: note: in expansion of macro 'le32_to_cpus'
        le32_to_cpus(*iter);
        ^
   In file included from include/linux/swab.h:4:0,
                    from include/uapi/linux/byteorder/big_endian.h:12,
                    from include/linux/byteorder/big_endian.h:4,
                    from arch/xtensa/include/uapi/asm/byteorder.h:7,
                    from arch/xtensa/include/asm/bitops.h:23,
                    from include/linux/bitops.h:36,
                    from include/linux/kernel.h:10,
                    from drivers/scsi/qla2xxx/qla_def.h:10,
                    from drivers/scsi/qla2xxx/qla_mbx.c:7:
   include/uapi/linux/swab.h:235:20: note: expected '__u32 *' but argument is of type 'uint32_t'
    static inline void __swab32s(__u32 *p)
                       ^

vim +/le32_to_cpus +2806 drivers/scsi/qla2xxx/qla_mbx.c

  2790		mcp->flags = IOCTL_CMD;
  2791		rval = qla2x00_mailbox_command(vha, mcp);
  2792	
  2793		if (rval == QLA_SUCCESS) {
  2794			if (mcp->mb[0] != MBS_COMMAND_COMPLETE) {
  2795				ql_dbg(ql_dbg_mbx, vha, 0x1085,
  2796				    "Failed=%x mb[0]=%x.\n", rval, mcp->mb[0]);
  2797				rval = QLA_FUNCTION_FAILED;
  2798			} else {
  2799				/* Copy over data -- firmware data is LE. */
  2800				ql_dbg(ql_dbg_mbx + ql_dbg_verbose, vha, 0x1086,
  2801				    "Done %s.\n", __func__);
  2802				dwords = offsetof(struct link_statistics,
  2803						link_up_cnt) / 4;
  2804				iter = &stats->link_fail_cnt;
  2805				for ( ; dwords--; iter++)
> 2806					le32_to_cpus(*iter);
  2807			}
  2808		} else {
  2809			/* Failed. */
  2810			ql_dbg(ql_dbg_mbx, vha, 0x1087, "Failed=%x.\n", rval);
  2811		}
  2812	
  2813		return rval;
  2814	}

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

Attachment: .config.gz
Description: Binary data


[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