[xilinx-xlnx:master 946/1117] drivers/spi/spi-zynqmp-gqspi.c:229:6: warning: no previous prototype for function 'zynqmp_gqspi_update_stripe'

kernel test robot lkp at intel.com
Wed Apr 12 10:56:07 PDT 2023


tree:   https://github.com/Xilinx/linux-xlnx master
head:   3a2a9dcee70777a85b3952269c47e6eb65779b78
commit: 754602bf2ee623dc6274c971e7e84058b70450aa [946/1117] spi: spi-zynqmp-gqspi: Add parallel memories support in GQSPI driver
config: x86_64-randconfig-a006-20230410 (https://download.01.org/0day-ci/archive/20230413/202304130122.DoBs1fgx-lkp@intel.com/config)
compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1)
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/Xilinx/linux-xlnx/commit/754602bf2ee623dc6274c971e7e84058b70450aa
        git remote add xilinx-xlnx https://github.com/Xilinx/linux-xlnx
        git fetch --no-tags xilinx-xlnx master
        git checkout 754602bf2ee623dc6274c971e7e84058b70450aa
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/spi/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp at intel.com>
| Link: https://lore.kernel.org/oe-kbuild-all/202304130122.DoBs1fgx-lkp@intel.com/

All warnings (new ones prefixed by >>):

   In file included from drivers/spi/spi-zynqmp-gqspi.c:26:
   In file included from include/linux/mtd/spi-nor.h:10:
   include/linux/mtd/cfi.h:62:2: warning: No CONFIG_MTD_CFI_Ix selected. No NOR chip support can work. [-W#warnings]
   #warning No CONFIG_MTD_CFI_Ix selected. No NOR chip support can work.
    ^
>> drivers/spi/spi-zynqmp-gqspi.c:229:6: warning: no previous prototype for function 'zynqmp_gqspi_update_stripe' [-Wmissing-prototypes]
   bool zynqmp_gqspi_update_stripe(const struct spi_mem_op *op)
        ^
   drivers/spi/spi-zynqmp-gqspi.c:229:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
   bool zynqmp_gqspi_update_stripe(const struct spi_mem_op *op)
   ^
   static 
   In file included from drivers/spi/spi-zynqmp-gqspi.c:13:
   include/linux/firmware/xlnx-zynqmp.h:1249:12: warning: unused function 'zynqmp_pm_sec_read_reg' [-Wunused-function]
   static int zynqmp_pm_sec_read_reg(u32 node_id, u32 offset, u32 *ret_value)
              ^
   include/linux/firmware/xlnx-zynqmp.h:1254:12: warning: unused function 'zynqmp_pm_sec_mask_write_reg' [-Wunused-function]
   static int zynqmp_pm_sec_mask_write_reg(const u32 node_id, const u32 offset,
              ^
   include/linux/firmware/xlnx-zynqmp.h:1324:12: warning: unused function 'zynqmp_pm_fpga_get_version' [-Wunused-function]
   static int zynqmp_pm_fpga_get_version(u32 *value)
              ^
   include/linux/firmware/xlnx-zynqmp.h:1329:12: warning: unused function 'zynqmp_pm_fpga_get_feature_list' [-Wunused-function]
   static int zynqmp_pm_fpga_get_feature_list(u32 *value)
              ^
   include/linux/firmware/xlnx-zynqmp.h:1334:12: warning: unused function 'versal_pm_sha_hash' [-Wunused-function]
   static int versal_pm_sha_hash(const u64 src, const u64 dst, const u32 size)
              ^
   7 warnings generated.


vim +/zynqmp_gqspi_update_stripe +229 drivers/spi/spi-zynqmp-gqspi.c

   221	
   222	/**
   223	 * zynqmp_gqspi_update_stripe - For GQSPI controller data stripe capabilities
   224	 * @op:	Pointer to mem ops
   225	 * Return:      Status of the data stripe
   226	 *
   227	 * Returns true if data stripe need to be enabled, else returns false
   228	 */
 > 229	bool zynqmp_gqspi_update_stripe(const struct spi_mem_op *op)
   230	{
   231		if (op->cmd.opcode ==  SPINOR_OP_BE_4K ||
   232		    op->cmd.opcode ==  SPINOR_OP_BE_32K ||
   233		    op->cmd.opcode ==  SPINOR_OP_CHIP_ERASE ||
   234		    op->cmd.opcode ==  SPINOR_OP_SE ||
   235		    op->cmd.opcode ==  SPINOR_OP_BE_32K_4B ||
   236		    op->cmd.opcode ==  SPINOR_OP_SE_4B ||
   237		    op->cmd.opcode == SPINOR_OP_BE_4K_4B ||
   238		    op->cmd.opcode ==  SPINOR_OP_WRSR ||
   239		    op->cmd.opcode ==  SPINOR_OP_BRWR ||
   240		    (op->cmd.opcode ==  SPINOR_OP_WRSR2 && !op->addr.nbytes))
   241			return false;
   242	
   243		return true;
   244	}
   245	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests



More information about the linux-arm-kernel mailing list