linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [xlnx:master 197/271] drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:370:4: error: 'struct axienet_local' has no member named 'qbv_regs'
@ 2021-02-09  8:41 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-02-09  8:41 UTC (permalink / raw)
  To: Pranavi Somisetty
  Cc: Saurabh Sengar, Michal Simek, kbuild-all, Ravali Potineni,
	Syed Syed, Priyadarshini Babu, linux-arm-kernel

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

tree:   https://github.com/Xilinx/linux-xlnx master
head:   d3774573d5a9700273bd0c3ff82af157107f7fa6
commit: 1a67745a47fc9601447f7d8aff40ddb1023848d5 [197/271] net: xilinx: Access qdv address and associated properties separately
config: h8300-randconfig-s031-20210209 (attached as .config)
compiler: h8300-linux-gcc (GCC) 9.3.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # apt-get install sparse
        # sparse version: v0.6.3-215-g0fb77bb6-dirty
        # https://github.com/Xilinx/linux-xlnx/commit/1a67745a47fc9601447f7d8aff40ddb1023848d5
        git remote add xlnx https://github.com/Xilinx/linux-xlnx
        git fetch --no-tags xlnx master
        git checkout 1a67745a47fc9601447f7d8aff40ddb1023848d5
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=h8300 

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

All errors (new ones prefixed by >>):

   In file included from arch/h8300/include/asm/bug.h:8,
                    from include/linux/bug.h:5,
                    from include/linux/thread_info.h:12,
                    from include/asm-generic/preempt.h:5,
                    from ./arch/h8300/include/generated/asm/preempt.h:1,
                    from include/linux/preempt.h:78,
                    from include/linux/spinlock.h:51,
                    from include/linux/seqlock.h:36,
                    from include/linux/time.h:6,
                    from include/linux/skbuff.h:15,
                    from include/linux/if_ether.h:19,
                    from include/linux/etherdevice.h:20,
                    from drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:18:
   include/linux/dma-mapping.h: In function 'dma_map_resource':
   include/asm-generic/page.h:91:32: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
      91 | #define pfn_valid(pfn)  ((pfn) >= ARCH_PFN_OFFSET && ((pfn) - ARCH_PFN_OFFSET) < max_mapnr)
         |                                ^~
   include/asm-generic/bug.h:182:25: note: in definition of macro 'WARN_ON'
     182 |  int __ret_warn_on = !!(condition);    \
         |                         ^~~~~~~~~
   include/linux/dma-mapping.h:355:6: note: in expansion of macro 'WARN_ON_ONCE'
     355 |  if (WARN_ON_ONCE(pfn_valid(PHYS_PFN(phys_addr))))
         |      ^~~~~~~~~~~~
   include/linux/dma-mapping.h:355:19: note: in expansion of macro 'pfn_valid'
     355 |  if (WARN_ON_ONCE(pfn_valid(PHYS_PFN(phys_addr))))
         |                   ^~~~~~~~~
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c: In function 'tsn_ep_open':
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:57:9: error: implicit declaration of function 'axienet_mcdma_rx_q_init'; did you mean 'axienet_dma_q_init'? [-Werror=implicit-function-declaration]
      57 |   ret = axienet_mcdma_rx_q_init(ndev, q);
         |         ^~~~~~~~~~~~~~~~~~~~~~~
         |         axienet_dma_q_init
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:60:32: error: 'axienet_mcdma_rx_irq' undeclared (first use in this function); did you mean 'axienet_rx_irq'?
      60 |   ret = request_irq(q->rx_irq, axienet_mcdma_rx_irq,
         |                                ^~~~~~~~~~~~~~~~~~~~
         |                                axienet_rx_irq
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:60:32: note: each undeclared identifier is reported only once for each function it appears in
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:66:9: error: 'axienet_mcdma_err_handler' undeclared (first use in this function); did you mean 'axienet_dma_err_handler'?
      66 |         axienet_mcdma_err_handler,
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
         |         axienet_dma_err_handler
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:74:9: error: implicit declaration of function 'axienet_mcdma_tx_q_init'; did you mean 'axienet_dma_q_init'? [-Werror=implicit-function-declaration]
      74 |   ret = axienet_mcdma_tx_q_init(ndev, q);
         |         ^~~~~~~~~~~~~~~~~~~~~~~
         |         axienet_dma_q_init
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:76:32: error: 'axienet_mcdma_tx_irq' undeclared (first use in this function); did you mean 'axienet_tx_irq'?
      76 |   ret = request_irq(q->tx_irq, axienet_mcdma_tx_irq,
         |                                ^~~~~~~~~~~~~~~~~~~~
         |                                axienet_tx_irq
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c: In function 'tsn_mcdma_probe':
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:270:2: error: implicit declaration of function 'axienet_mcdma_rx_probe'; did you mean 'axienet_tsn_probe'? [-Werror=implicit-function-declaration]
     270 |  axienet_mcdma_rx_probe(pdev, lp, ndev);
         |  ^~~~~~~~~~~~~~~~~~~~~~
         |  axienet_tsn_probe
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:271:2: error: implicit declaration of function 'axienet_mcdma_tx_probe'; did you mean 'axienet_tsn_probe'? [-Werror=implicit-function-declaration]
     271 |  axienet_mcdma_tx_probe(pdev, np, lp);
         |  ^~~~~~~~~~~~~~~~~~~~~~
         |  axienet_tsn_probe
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c: In function 'tsn_ep_probe':
>> drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:370:4: error: 'struct axienet_local' has no member named 'qbv_regs'
     370 |  lp->qbv_regs = lp->regs;
         |    ^~
>> drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:373:4: error: 'struct axienet_local' has no member named 'qbv_irq'
     373 |  lp->qbv_irq = platform_get_irq_byname(pdev, irq_name);
         |    ^~
>> drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:374:2: error: implicit declaration of function 'axienet_qbv_init'; did you mean 'axienet_dma_q_init'? [-Werror=implicit-function-declaration]
     374 |  axienet_qbv_init(ndev);
         |  ^~~~~~~~~~~~~~~~
         |  axienet_dma_q_init
   drivers/net/ethernet/xilinx/xilinx_tsn_ep.c: In function 'tsn_ep_remove':
>> drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:392:2: error: implicit declaration of function 'axienet_qbv_remove'; did you mean 'axienet_bd_free'? [-Werror=implicit-function-declaration]
     392 |  axienet_qbv_remove(ndev);
         |  ^~~~~~~~~~~~~~~~~~
         |  axienet_bd_free
   cc1: some warnings being treated as errors


vim +370 drivers/net/ethernet/xilinx/xilinx_tsn_ep.c

   281	
   282	/**
   283	 * tsn_ep_probe - TSN ep pointer probe function.
   284	 * @pdev:	Pointer to platform device structure.
   285	 *
   286	 * Return: 0, on success
   287	 *	    Non-zero error value on failure.
   288	 *
   289	 * This is the probe routine for TSN endpoint driver.
   290	 */
   291	static int tsn_ep_probe(struct platform_device *pdev)
   292	{
   293		int ret = 0;
   294		struct axienet_local *lp;
   295		struct net_device *ndev;
   296		struct resource *ethres;
   297		const void *mac_addr;
   298		u16 num_tc = 0;
   299		char irq_name[32];
   300	
   301		ndev = alloc_netdev(sizeof(*lp), "ep", NET_NAME_UNKNOWN, ether_setup);
   302		if (!ndev)
   303			return -ENOMEM;
   304	
   305		platform_set_drvdata(pdev, ndev);
   306	
   307		SET_NETDEV_DEV(ndev, &pdev->dev);
   308		ndev->flags &= ~IFF_MULTICAST;  /* clear multicast */
   309		ndev->features = NETIF_F_SG;
   310		ndev->netdev_ops = &ep_netdev_ops;
   311	
   312		/* MTU range: 64 - 9000 */
   313		ndev->min_mtu = 64;
   314		ndev->max_mtu = XAE_JUMBO_MTU;
   315	
   316		lp = netdev_priv(ndev);
   317		lp->ndev = ndev;
   318		lp->dev = &pdev->dev;
   319		lp->options = XAE_OPTION_DEFAULTS;
   320		lp->tx_bd_num = TX_BD_NUM_DEFAULT;
   321		lp->rx_bd_num = RX_BD_NUM_DEFAULT;
   322	
   323		/* TODO
   324		 * there are two temacs or two slaves to ep
   325		 * get this infor from design?
   326		 */
   327		lp->slaves[0] = NULL;
   328		lp->slaves[1] = NULL;
   329	
   330		lp->axienet_config = &tsn_endpoint_cfg;
   331	
   332		lp->max_frm_size = XAE_MAX_VLAN_FRAME_SIZE;
   333	
   334		/* Setup checksum offload, but default to off if not specified */
   335		lp->features = 0;
   336	
   337		lp->eth_hasnobuf = of_property_read_bool(pdev->dev.of_node,
   338							 "xlnx,eth-hasnobuf");
   339	
   340		/* Retrieve the MAC address */
   341		mac_addr = of_get_mac_address(pdev->dev.of_node);
   342		if (!mac_addr) {
   343			dev_err(&pdev->dev, "could not find MAC address\n");
   344			goto free_netdev;
   345		}
   346		if (mac_addr)
   347			ether_addr_copy(ndev->dev_addr, mac_addr);
   348		if (!is_valid_ether_addr(ndev->dev_addr))
   349			eth_hw_addr_random(ndev);
   350	
   351		ret = tsn_mcdma_probe(pdev, lp, ndev);
   352		if (ret) {
   353			dev_err(&pdev->dev, "Getting MCDMA resource failed\n");
   354			goto free_netdev;
   355		}
   356	
   357		ret = of_property_read_u16(
   358			pdev->dev.of_node, "xlnx,num-tc", &num_tc);
   359		if (ret || (num_tc != 2 && num_tc != 3))
   360			lp->num_tc = XAE_MAX_TSN_TC;
   361		else
   362			lp->num_tc = num_tc;
   363		/* Map device registers */
   364		ethres = platform_get_resource(pdev, IORESOURCE_MEM, 0);
   365		lp->regs = devm_ioremap_resource(&pdev->dev, ethres);
   366		if (IS_ERR(lp->regs)) {
   367			ret = PTR_ERR(lp->regs);
   368			goto free_netdev;
   369		}
 > 370		lp->qbv_regs = lp->regs;
   371	
   372		sprintf(irq_name, "tsn_ep_scheduler_irq");
 > 373		lp->qbv_irq = platform_get_irq_byname(pdev, irq_name);
 > 374		axienet_qbv_init(ndev);
   375	
   376		ret = register_netdev(lp->ndev);
   377		if (ret)
   378			dev_err(lp->dev, "register_netdev() error (%i)\n", ret);
   379	
   380		return ret;
   381	
   382	free_netdev:
   383		free_netdev(ndev);
   384	
   385		return ret;
   386	}
   387	
   388	static int tsn_ep_remove(struct platform_device *pdev)
   389	{
   390		struct net_device *ndev = platform_get_drvdata(pdev);
   391	
 > 392		axienet_qbv_remove(ndev);
   393		unregister_netdev(ndev);
   394	
   395		free_netdev(ndev);
   396	
   397		return 0;
   398	}
   399	

---
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: 19804 bytes --]

[-- Attachment #3: Type: text/plain, Size: 176 bytes --]

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

only message in thread, other threads:[~2021-02-09  8:44 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-09  8:41 [xlnx:master 197/271] drivers/net/ethernet/xilinx/xilinx_tsn_ep.c:370:4: error: 'struct axienet_local' has no member named 'qbv_regs' 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;
as well as URLs for NNTP newsgroup(s).