linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: "Russell King (Oracle)" <rmk+kernel@armlinux.org.uk>
Cc: kbuild-all@lists.01.org, linux-arm-kernel@lists.infradead.org
Subject: [arm:zii 42/102] drivers/net/phy/phylink.c:322:9: error: enumeration value 'PHY_INTERFACE_MODE_SMII' not handled in switch
Date: Thu, 11 Nov 2021 22:37:06 +0800	[thread overview]
Message-ID: <202111112201.s79nmjYJ-lkp@intel.com> (raw)

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

tree:   git://git.armlinux.org.uk/~rmk/linux-arm.git zii
head:   259f23bb268ce5e8c9dcc5791ca96448a3180a93
commit: 867e7218e10d7c016baaed61855f2e0054a2ae3b [42/102] net: phylink: add generic validate implementation
config: arc-allyesconfig (attached as .config)
compiler: arceb-elf-gcc (GCC) 11.2.0
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
        git remote add arm git://git.armlinux.org.uk/~rmk/linux-arm.git
        git fetch --no-tags arm zii
        git checkout 867e7218e10d7c016baaed61855f2e0054a2ae3b
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=arc 

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 >>):

   drivers/net/phy/phylink.c: In function 'phylink_get_linkmodes':
>> drivers/net/phy/phylink.c:322:9: error: enumeration value 'PHY_INTERFACE_MODE_SMII' not handled in switch [-Werror=switch]
     322 |         switch (interface) {
         |         ^~~~~~
>> drivers/net/phy/phylink.c:322:9: error: enumeration value 'PHY_INTERFACE_MODE_MOCA' not handled in switch [-Werror=switch]
   cc1: all warnings being treated as errors


vim +/PHY_INTERFACE_MODE_SMII +322 drivers/net/phy/phylink.c

   306	
   307	/**
   308	 * phylink_get_linkmodes() - get acceptable link modes
   309	 * @linkmodes: ethtool linkmode mask (must be already initialised)
   310	 * @interface: phy interface mode defined by &typedef phy_interface_t
   311	 * @mac_capabilities: bitmask of MAC capabilities
   312	 *
   313	 * Set all possible pause, speed and duplex linkmodes in @linkmodes that
   314	 * are supported by the @interface mode and @mac_capabilities. @linkmodes
   315	 * must have been initialised previously.
   316	 */
   317	void phylink_get_linkmodes(unsigned long *linkmodes, phy_interface_t interface,
   318				   unsigned long mac_capabilities)
   319	{
   320		unsigned long caps = MAC_SYM_PAUSE | MAC_ASYM_PAUSE;
   321	
 > 322		switch (interface) {
   323		case PHY_INTERFACE_MODE_USXGMII:
   324			caps |= MAC_10000FD | MAC_5000FD | MAC_2500FD;
   325			fallthrough;
   326	
   327		case PHY_INTERFACE_MODE_RGMII_TXID:
   328		case PHY_INTERFACE_MODE_RGMII_RXID:
   329		case PHY_INTERFACE_MODE_RGMII_ID:
   330		case PHY_INTERFACE_MODE_RGMII:
   331		case PHY_INTERFACE_MODE_QSGMII:
   332		case PHY_INTERFACE_MODE_SGMII:
   333		case PHY_INTERFACE_MODE_GMII:
   334			caps |= MAC_1000HD | MAC_1000FD;
   335			fallthrough;
   336	
   337		case PHY_INTERFACE_MODE_REVRMII:
   338		case PHY_INTERFACE_MODE_RMII:
   339		case PHY_INTERFACE_MODE_REVMII:
   340		case PHY_INTERFACE_MODE_MII:
   341			caps |= MAC_10HD | MAC_10FD;
   342			fallthrough;
   343	
   344		case PHY_INTERFACE_MODE_100BASEX:
   345			caps |= MAC_100HD | MAC_100FD;
   346			break;
   347	
   348		case PHY_INTERFACE_MODE_TBI:
   349		case PHY_INTERFACE_MODE_RTBI:
   350		case PHY_INTERFACE_MODE_1000BASEX:
   351			caps |= MAC_1000HD;
   352			fallthrough;
   353		case PHY_INTERFACE_MODE_TRGMII:
   354			caps |= MAC_1000FD;
   355			break;
   356	
   357		case PHY_INTERFACE_MODE_2500BASEX:
   358			caps |= MAC_2500FD;
   359			break;
   360	
   361		case PHY_INTERFACE_MODE_5GBASER:
   362			caps |= MAC_5000FD;
   363			break;
   364	
   365		case PHY_INTERFACE_MODE_XGMII:
   366		case PHY_INTERFACE_MODE_RXAUI:
   367		case PHY_INTERFACE_MODE_XAUI:
   368		case PHY_INTERFACE_MODE_10GBASER:
   369		case PHY_INTERFACE_MODE_10GKR:
   370			caps |= MAC_10000FD;
   371			break;
   372	
   373		case PHY_INTERFACE_MODE_25GBASER:
   374			caps |= MAC_25000FD;
   375			break;
   376	
   377		case PHY_INTERFACE_MODE_XLGMII:
   378			caps |= MAC_40000FD;
   379			break;
   380	
   381		case PHY_INTERFACE_MODE_INTERNAL:
   382			caps |= ~0;
   383			break;
   384	
   385		case PHY_INTERFACE_MODE_NA:
   386		case PHY_INTERFACE_MODE_MAX:
   387			break;
   388		}
   389	
   390		phylink_caps_to_linkmodes(linkmodes, caps & mac_capabilities);
   391	}
   392	EXPORT_SYMBOL_GPL(phylink_get_linkmodes);
   393	

---
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: 69478 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

                 reply	other threads:[~2021-11-11 14:39 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=202111112201.s79nmjYJ-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=rmk+kernel@armlinux.org.uk \
    /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).