driverdev-devel.linuxdriverproject.org archive mirror
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
To: Wambui Karuga <wambui.karugax@gmail.com>
Cc: devel@driverdev.osuosl.org,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	kbuild-all@lists.01.org
Subject: [staging:staging-testing 157/337] drivers/staging/octeon/ethernet.c:463:30: error: storage size of 'link_info' isn't known
Date: Tue, 12 Nov 2019 09:27:31 +0800	[thread overview]
Message-ID: <201911120930.vdaECUhO%lkp@intel.com> (raw)

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git staging-testing
head:   08283d30744434d8f30d386622372e8f5b03bcf2
commit: 73aef0c9d2c6f746e8c84775b73ef374b7a2a4dc [157/337] staging: octeon: remove typedef declaration for cvmx_helper_link_info
config: mips-cavium_octeon_defconfig (attached as .config)
compiler: mips64-linux-gcc (GCC) 7.4.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 73aef0c9d2c6f746e8c84775b73ef374b7a2a4dc
        # save the attached .config to linux build tree
        GCC_VERSION=7.4.0 make.cross ARCH=mips 

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

All error/warnings (new ones prefixed by >>):

   In file included from drivers/staging/octeon/ethernet-mem.c:12:0:
>> drivers/staging/octeon/octeon-ethernet.h:94:12: warning: 'union cvmx_helper_link_info' declared inside parameter list will not be visible outside of this definition or declaration
         union cvmx_helper_link_info li);
               ^~~~~~~~~~~~~~~~~~~~~
--
   In file included from drivers/staging/octeon/ethernet.c:22:0:
>> drivers/staging/octeon/octeon-ethernet.h:94:12: warning: 'union cvmx_helper_link_info' declared inside parameter list will not be visible outside of this definition or declaration
         union cvmx_helper_link_info li);
               ^~~~~~~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet.c: In function 'cvm_oct_free_work':
   drivers/staging/octeon/ethernet.c:177:21: error: dereferencing pointer to incomplete type 'struct cvmx_wqe'
     int segments = work->word2.s.bufs;
                        ^~
   drivers/staging/octeon/ethernet.c: In function 'cvm_oct_common_open':
>> drivers/staging/octeon/ethernet.c:463:30: error: storage size of 'link_info' isn't known
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
   drivers/staging/octeon/ethernet.c:463:30: warning: unused variable 'link_info' [-Wunused-variable]
   drivers/staging/octeon/ethernet.c: In function 'cvm_oct_link_poll':
   drivers/staging/octeon/ethernet.c:499:30: error: storage size of 'link_info' isn't known
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
>> drivers/staging/octeon/ethernet.c:516:29: error: type of formal parameter 2 is incomplete
     cvm_oct_note_carrier(priv, link_info);
                                ^~~~~~~~~
   drivers/staging/octeon/ethernet.c:499:30: warning: unused variable 'link_info' [-Wunused-variable]
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
--
   In file included from drivers/staging/octeon/ethernet-mdio.c:16:0:
>> drivers/staging/octeon/octeon-ethernet.h:94:12: warning: 'union cvmx_helper_link_info' declared inside parameter list will not be visible outside of this definition or declaration
         union cvmx_helper_link_info li);
               ^~~~~~~~~~~~~~~~~~~~~
>> drivers/staging/octeon/ethernet-mdio.c:68:12: warning: 'union cvmx_helper_link_info' declared inside parameter list will not be visible outside of this definition or declaration
         union cvmx_helper_link_info li)
               ^~~~~~~~~~~~~~~~~~~~~
>> drivers/staging/octeon/ethernet-mdio.c:68:34: error: parameter 2 ('li') has incomplete type
         union cvmx_helper_link_info li)
                                     ^~
   drivers/staging/octeon/ethernet-mdio.c: In function 'cvm_oct_adjust_link':
>> drivers/staging/octeon/ethernet-mdio.c:84:30: error: storage size of 'link_info' isn't known
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
>> drivers/staging/octeon/ethernet-mdio.c:101:30: error: type of formal parameter 2 is incomplete
      cvm_oct_note_carrier(priv, link_info);
                                 ^~~~~~~~~
   drivers/staging/octeon/ethernet-mdio.c:84:30: warning: unused variable 'link_info' [-Wunused-variable]
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
   drivers/staging/octeon/ethernet-mdio.c: In function 'cvm_oct_common_stop':
   drivers/staging/octeon/ethernet-mdio.c:109:30: error: storage size of 'link_info' isn't known
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
   drivers/staging/octeon/ethernet-mdio.c:127:30: error: type of formal parameter 2 is incomplete
      cvm_oct_note_carrier(priv, link_info);
                                 ^~~~~~~~~
   drivers/staging/octeon/ethernet-mdio.c:109:30: warning: unused variable 'link_info' [-Wunused-variable]
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
--
   In file included from drivers/staging/octeon/ethernet-rgmii.c:15:0:
>> drivers/staging/octeon/octeon-ethernet.h:94:12: warning: 'union cvmx_helper_link_info' declared inside parameter list will not be visible outside of this definition or declaration
         union cvmx_helper_link_info li);
               ^~~~~~~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet-rgmii.c: In function 'cvm_oct_check_preamble_errors':
>> drivers/staging/octeon/ethernet-rgmii.c:56:30: error: storage size of 'link_info' isn't known
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
   drivers/staging/octeon/ethernet-rgmii.c:56:30: warning: unused variable 'link_info' [-Wunused-variable]
   drivers/staging/octeon/ethernet-rgmii.c: In function 'cvm_oct_rgmii_poll':
   drivers/staging/octeon/ethernet-rgmii.c:106:30: error: storage size of 'link_info' isn't known
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
>> drivers/staging/octeon/ethernet-rgmii.c:128:29: error: type of formal parameter 2 is incomplete
     cvm_oct_note_carrier(priv, link_info);
                                ^~~~~~~~~
   drivers/staging/octeon/ethernet-rgmii.c:106:30: warning: unused variable 'link_info' [-Wunused-variable]
     union cvmx_helper_link_info link_info;
                                 ^~~~~~~~~
--
   In file included from drivers/staging/octeon/ethernet-rx.c:26:0:
>> drivers/staging/octeon/octeon-ethernet.h:94:12: warning: 'union cvmx_helper_link_info' declared inside parameter list will not be visible outside of this definition or declaration
         union cvmx_helper_link_info li);
               ^~~~~~~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet-rx.c:63:50: warning: 'struct cvmx_wqe' declared inside parameter list will not be visible outside of this definition or declaration
    static inline int cvm_oct_check_rcv_error(struct cvmx_wqe *work)
                                                     ^~~~~~~~
   drivers/staging/octeon/ethernet-rx.c: In function 'cvm_oct_check_rcv_error':
   drivers/staging/octeon/ethernet-rx.c:68:14: error: dereferencing pointer to incomplete type 'struct cvmx_wqe'
      port = work->word0.pip.cn68xx.pknd;
                 ^~
   drivers/staging/octeon/ethernet-rx.c: At top level:
   drivers/staging/octeon/ethernet-rx.c:138:41: warning: 'struct cvmx_wqe' declared inside parameter list will not be visible outside of this definition or declaration
    static void copy_segments_to_skb(struct cvmx_wqe *work, struct sk_buff *skb)
                                            ^~~~~~~~
   drivers/staging/octeon/ethernet-rx.c: In function 'copy_segments_to_skb':
   drivers/staging/octeon/ethernet-rx.c:140:21: error: dereferencing pointer to incomplete type 'struct cvmx_wqe'
     int segments = work->word2.s.bufs;
                        ^~
   drivers/staging/octeon/ethernet-rx.c: In function 'cvm_oct_poll':
   drivers/staging/octeon/ethernet-rx.c:222:9: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
       work = cvmx_pow_work_response_async(CVMX_SCR_SCRATCH);
            ^
   drivers/staging/octeon/ethernet-rx.c:224:9: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
       work = cvmx_pow_work_request_sync(CVMX_POW_NO_WAIT);
            ^
   drivers/staging/octeon/ethernet-rx.c:245:32: error: dereferencing pointer to incomplete type 'struct cvmx_wqe'
       (cvm_oct_get_buffer_ptr(work->packet_ptr) -
                                   ^~
   drivers/staging/octeon/ethernet-rx.c:272:32: error: passing argument 1 of 'cvm_oct_check_rcv_error' from incompatible pointer type [-Werror=incompatible-pointer-types]
       if (cvm_oct_check_rcv_error(work))
                                   ^~~~
   drivers/staging/octeon/ethernet-rx.c:63:19: note: expected 'struct cvmx_wqe *' but argument is of type 'struct cvmx_wqe *'
    static inline int cvm_oct_check_rcv_error(struct cvmx_wqe *work)
                      ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet-rx.c:319:26: error: passing argument 1 of 'copy_segments_to_skb' from incompatible pointer type [-Werror=incompatible-pointer-types]
        copy_segments_to_skb(work, skb);
                             ^~~~
   drivers/staging/octeon/ethernet-rx.c:138:13: note: expected 'struct cvmx_wqe *' but argument is of type 'struct cvmx_wqe *'
    static void copy_segments_to_skb(struct cvmx_wqe *work, struct sk_buff *skb)
                ^~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors
--
   In file included from drivers/staging/octeon/ethernet-tx.c:25:0:
>> drivers/staging/octeon/octeon-ethernet.h:94:12: warning: 'union cvmx_helper_link_info' declared inside parameter list will not be visible outside of this definition or declaration
         union cvmx_helper_link_info li);
               ^~~~~~~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet-tx.c: In function 'cvm_oct_xmit_pow':
   drivers/staging/octeon/ethernet-tx.c:562:7: error: dereferencing pointer to incomplete type 'struct cvmx_wqe'
      work->word0.pip.cn38xx.hw_chksum = skb->csum;
          ^~
   drivers/staging/octeon/ethernet-tx.c:564:20: error: passing argument 1 of 'cvmx_wqe_set_port' from incompatible pointer type [-Werror=incompatible-pointer-types]
     cvmx_wqe_set_port(work, priv->port);
                       ^~~~
   In file included from arch/mips/include/asm/octeon/cvmx-helper.h:39:0,
                    from drivers/staging/octeon/octeon-ethernet.h:25,
                    from drivers/staging/octeon/ethernet-tx.c:25:
   arch/mips/include/asm/octeon/cvmx-wqe.h:610:20: note: expected 'cvmx_wqe_t * {aka struct <anonymous> *}' but argument is of type 'struct cvmx_wqe *'
    static inline void cvmx_wqe_set_port(cvmx_wqe_t *work, int port)
                       ^~~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet-tx.c:565:19: error: passing argument 1 of 'cvmx_wqe_set_qos' from incompatible pointer type [-Werror=incompatible-pointer-types]
     cvmx_wqe_set_qos(work, priv->port & 0x7);
                      ^~~~
   In file included from arch/mips/include/asm/octeon/cvmx-helper.h:39:0,
                    from drivers/staging/octeon/octeon-ethernet.h:25,
                    from drivers/staging/octeon/ethernet-tx.c:25:
   arch/mips/include/asm/octeon/cvmx-wqe.h:650:20: note: expected 'cvmx_wqe_t * {aka struct <anonymous> *}' but argument is of type 'struct cvmx_wqe *'
    static inline void cvmx_wqe_set_qos(cvmx_wqe_t *work, int qos)
                       ^~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet-tx.c:566:19: error: passing argument 1 of 'cvmx_wqe_set_grp' from incompatible pointer type [-Werror=incompatible-pointer-types]
     cvmx_wqe_set_grp(work, pow_send_group);
                      ^~~~
   In file included from arch/mips/include/asm/octeon/cvmx-helper.h:39:0,
                    from drivers/staging/octeon/octeon-ethernet.h:25,
                    from drivers/staging/octeon/ethernet-tx.c:25:
   arch/mips/include/asm/octeon/cvmx-wqe.h:630:20: note: expected 'cvmx_wqe_t * {aka struct <anonymous> *}' but argument is of type 'struct cvmx_wqe *'
    static inline void cvmx_wqe_set_grp(cvmx_wqe_t *work, int grp)
                       ^~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet-tx.c:649:26: error: passing argument 1 of 'cvmx_wqe_get_qos' from incompatible pointer type [-Werror=incompatible-pointer-types]
            cvmx_wqe_get_qos(work), cvmx_wqe_get_grp(work));
                             ^~~~
   In file included from arch/mips/include/asm/octeon/cvmx-helper.h:39:0,
                    from drivers/staging/octeon/octeon-ethernet.h:25,
                    from drivers/staging/octeon/ethernet-tx.c:25:
   arch/mips/include/asm/octeon/cvmx-wqe.h:638:19: note: expected 'cvmx_wqe_t * {aka struct <anonymous> *}' but argument is of type 'struct cvmx_wqe *'
    static inline int cvmx_wqe_get_qos(cvmx_wqe_t *work)
                      ^~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet-tx.c:649:50: error: passing argument 1 of 'cvmx_wqe_get_grp' from incompatible pointer type [-Werror=incompatible-pointer-types]
            cvmx_wqe_get_qos(work), cvmx_wqe_get_grp(work));
                                                     ^~~~
   In file included from arch/mips/include/asm/octeon/cvmx-helper.h:39:0,
                    from drivers/staging/octeon/octeon-ethernet.h:25,
                    from drivers/staging/octeon/ethernet-tx.c:25:
   arch/mips/include/asm/octeon/cvmx-wqe.h:618:19: note: expected 'cvmx_wqe_t * {aka struct <anonymous> *}' but argument is of type 'struct cvmx_wqe *'
    static inline int cvmx_wqe_get_grp(cvmx_wqe_t *work)
                      ^~~~~~~~~~~~~~~~
   drivers/staging/octeon/ethernet-tx.c:648:23: error: passing argument 1 of 'cvmx_pow_work_submit' from incompatible pointer type [-Werror=incompatible-pointer-types]
     cvmx_pow_work_submit(work, work->word1.tag, work->word1.tag_type,
                          ^~~~
   In file included from arch/mips/include/asm/octeon/cvmx-pko.h:62:0,
                    from drivers/staging/octeon/octeon-ethernet.h:31,
                    from drivers/staging/octeon/ethernet-tx.c:25:
   arch/mips/include/asm/octeon/cvmx-pow.h:1806:20: note: expected 'cvmx_wqe_t * {aka struct <anonymous> *}' but argument is of type 'struct cvmx_wqe *'
    static inline void cvmx_pow_work_submit(cvmx_wqe_t *wqp, uint32_t tag,
                       ^~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors

vim +463 drivers/staging/octeon/ethernet.c

   455	
   456	int cvm_oct_common_open(struct net_device *dev,
   457				void (*link_poll)(struct net_device *))
   458	{
   459		union cvmx_gmxx_prtx_cfg gmx_cfg;
   460		struct octeon_ethernet *priv = netdev_priv(dev);
   461		int interface = INTERFACE(priv->port);
   462		int index = INDEX(priv->port);
 > 463		union cvmx_helper_link_info link_info;
   464		int rv;
   465	
   466		rv = cvm_oct_phy_setup_device(dev);
   467		if (rv)
   468			return rv;
   469	
   470		gmx_cfg.u64 = cvmx_read_csr(CVMX_GMXX_PRTX_CFG(index, interface));
   471		gmx_cfg.s.en = 1;
   472		if (octeon_has_feature(OCTEON_FEATURE_PKND))
   473			gmx_cfg.s.pknd = priv->port;
   474		cvmx_write_csr(CVMX_GMXX_PRTX_CFG(index, interface), gmx_cfg.u64);
   475	
   476		if (octeon_is_simulation())
   477			return 0;
   478	
   479		if (dev->phydev) {
   480			int r = phy_read_status(dev->phydev);
   481	
   482			if (r == 0 && dev->phydev->link == 0)
   483				netif_carrier_off(dev);
   484			cvm_oct_adjust_link(dev);
   485		} else {
   486			link_info = cvmx_helper_link_get(priv->port);
   487			if (!link_info.s.link_up)
   488				netif_carrier_off(dev);
   489			priv->poll = link_poll;
   490			link_poll(dev);
   491		}
   492	
   493		return 0;
   494	}
   495	
   496	void cvm_oct_link_poll(struct net_device *dev)
   497	{
   498		struct octeon_ethernet *priv = netdev_priv(dev);
   499		union cvmx_helper_link_info link_info;
   500	
   501		link_info = cvmx_helper_link_get(priv->port);
   502		if (link_info.u64 == priv->link_info)
   503			return;
   504	
   505		if (cvmx_helper_link_set(priv->port, link_info))
   506			link_info.u64 = priv->link_info;
   507		else
   508			priv->link_info = link_info.u64;
   509	
   510		if (link_info.s.link_up) {
   511			if (!netif_carrier_ok(dev))
   512				netif_carrier_on(dev);
   513		} else if (netif_carrier_ok(dev)) {
   514			netif_carrier_off(dev);
   515		}
 > 516		cvm_oct_note_carrier(priv, link_info);
   517	}
   518	

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

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 17935 bytes --]

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

_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

                 reply	other threads:[~2019-11-12  1:28 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201911120930.vdaECUhO%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=kbuild-all@lists.01.org \
    --cc=wambui.karugax@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).