Message ID | 20231205103559.9605-12-fancer.lancer@gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | None | expand |
Hi Serge, kernel test robot noticed the following build errors: [auto build test ERROR on net-next/main] url: https://github.com/intel-lab-lkp/linux/commits/Serge-Semin/net-pcs-xpcs-Drop-sentinel-entry-from-2500basex-ifaces-list/20231205-183808 base: net-next/main patch link: https://lore.kernel.org/r/20231205103559.9605-12-fancer.lancer%40gmail.com patch subject: [PATCH net-next 11/16] net: pcs: xpcs: Change xpcs_create_mdiodev() suffix to "byaddr" config: arc-randconfig-001-20231206 (https://download.01.org/0day-ci/archive/20231206/202312060634.Cblfigt2-lkp@intel.com/config) compiler: arc-elf-gcc (GCC) 13.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231206/202312060634.Cblfigt2-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202312060634.Cblfigt2-lkp@intel.com/ All error/warnings (new ones prefixed by >>): drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c: In function 'txgbe_mdio_pcs_init': >> drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:150:16: error: implicit declaration of function 'xpcs_create_mdiodev'; did you mean 'xpcs_create_byaddr'? [-Werror=implicit-function-declaration] 150 | xpcs = xpcs_create_mdiodev(mii_bus, 0, PHY_INTERFACE_MODE_10GBASER); | ^~~~~~~~~~~~~~~~~~~ | xpcs_create_byaddr >> drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:150:14: warning: assignment to 'struct dw_xpcs *' from 'int' makes pointer from integer without a cast [-Wint-conversion] 150 | xpcs = xpcs_create_mdiodev(mii_bus, 0, PHY_INTERFACE_MODE_10GBASER); | ^ cc1: some warnings being treated as errors vim +150 drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c 854cace61387b6 Jiawen Wu 2023-06-06 121 854cace61387b6 Jiawen Wu 2023-06-06 122 static int txgbe_mdio_pcs_init(struct txgbe *txgbe) 854cace61387b6 Jiawen Wu 2023-06-06 123 { 854cace61387b6 Jiawen Wu 2023-06-06 124 struct mii_bus *mii_bus; 854cace61387b6 Jiawen Wu 2023-06-06 125 struct dw_xpcs *xpcs; 854cace61387b6 Jiawen Wu 2023-06-06 126 struct pci_dev *pdev; 854cace61387b6 Jiawen Wu 2023-06-06 127 struct wx *wx; 854cace61387b6 Jiawen Wu 2023-06-06 128 int ret = 0; 854cace61387b6 Jiawen Wu 2023-06-06 129 854cace61387b6 Jiawen Wu 2023-06-06 130 wx = txgbe->wx; 854cace61387b6 Jiawen Wu 2023-06-06 131 pdev = wx->pdev; 854cace61387b6 Jiawen Wu 2023-06-06 132 854cace61387b6 Jiawen Wu 2023-06-06 133 mii_bus = devm_mdiobus_alloc(&pdev->dev); 854cace61387b6 Jiawen Wu 2023-06-06 134 if (!mii_bus) 854cace61387b6 Jiawen Wu 2023-06-06 135 return -ENOMEM; 854cace61387b6 Jiawen Wu 2023-06-06 136 854cace61387b6 Jiawen Wu 2023-06-06 137 mii_bus->name = "txgbe_pcs_mdio_bus"; 854cace61387b6 Jiawen Wu 2023-06-06 138 mii_bus->read_c45 = &txgbe_pcs_read; 854cace61387b6 Jiawen Wu 2023-06-06 139 mii_bus->write_c45 = &txgbe_pcs_write; 854cace61387b6 Jiawen Wu 2023-06-06 140 mii_bus->parent = &pdev->dev; 854cace61387b6 Jiawen Wu 2023-06-06 141 mii_bus->phy_mask = ~0; 854cace61387b6 Jiawen Wu 2023-06-06 142 mii_bus->priv = wx; 854cace61387b6 Jiawen Wu 2023-06-06 143 snprintf(mii_bus->id, MII_BUS_ID_SIZE, "txgbe_pcs-%x", d8c21ef7b2b147 Xiongfeng Wang 2023-08-08 144 pci_dev_id(pdev)); 854cace61387b6 Jiawen Wu 2023-06-06 145 854cace61387b6 Jiawen Wu 2023-06-06 146 ret = devm_mdiobus_register(&pdev->dev, mii_bus); 854cace61387b6 Jiawen Wu 2023-06-06 147 if (ret) 854cace61387b6 Jiawen Wu 2023-06-06 148 return ret; 854cace61387b6 Jiawen Wu 2023-06-06 149 854cace61387b6 Jiawen Wu 2023-06-06 @150 xpcs = xpcs_create_mdiodev(mii_bus, 0, PHY_INTERFACE_MODE_10GBASER); 854cace61387b6 Jiawen Wu 2023-06-06 151 if (IS_ERR(xpcs)) 854cace61387b6 Jiawen Wu 2023-06-06 152 return PTR_ERR(xpcs); 854cace61387b6 Jiawen Wu 2023-06-06 153 854cace61387b6 Jiawen Wu 2023-06-06 154 txgbe->xpcs = xpcs; 854cace61387b6 Jiawen Wu 2023-06-06 155 854cace61387b6 Jiawen Wu 2023-06-06 156 return 0; 854cace61387b6 Jiawen Wu 2023-06-06 157 } 854cace61387b6 Jiawen Wu 2023-06-06 158
Hi Serge,
kernel test robot noticed the following build warnings:
[auto build test WARNING on net-next/main]
url: https://github.com/intel-lab-lkp/linux/commits/Serge-Semin/net-pcs-xpcs-Drop-sentinel-entry-from-2500basex-ifaces-list/20231205-183808
base: net-next/main
patch link: https://lore.kernel.org/r/20231205103559.9605-12-fancer.lancer%40gmail.com
patch subject: [PATCH net-next 11/16] net: pcs: xpcs: Change xpcs_create_mdiodev() suffix to "byaddr"
config: x86_64-randconfig-006-20231206 (https://download.01.org/0day-ci/archive/20231206/202312060843.C3pV7P8b-lkp@intel.com/config)
compiler: gcc-7 (Ubuntu 7.5.0-6ubuntu2) 7.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231206/202312060843.C3pV7P8b-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202312060843.C3pV7P8b-lkp@intel.com/
All warnings (new ones prefixed by >>):
drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c: In function 'txgbe_mdio_pcs_init':
drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:150:9: error: implicit declaration of function 'xpcs_create_mdiodev'; did you mean 'xpcs_create_byaddr'? [-Werror=implicit-function-declaration]
xpcs = xpcs_create_mdiodev(mii_bus, 0, PHY_INTERFACE_MODE_10GBASER);
^~~~~~~~~~~~~~~~~~~
xpcs_create_byaddr
>> drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:150:7: warning: assignment makes pointer from integer without a cast [-Wint-conversion]
xpcs = xpcs_create_mdiodev(mii_bus, 0, PHY_INTERFACE_MODE_10GBASER);
^
cc1: some warnings being treated as errors
vim +150 drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c
854cace61387b6 Jiawen Wu 2023-06-06 121
854cace61387b6 Jiawen Wu 2023-06-06 122 static int txgbe_mdio_pcs_init(struct txgbe *txgbe)
854cace61387b6 Jiawen Wu 2023-06-06 123 {
854cace61387b6 Jiawen Wu 2023-06-06 124 struct mii_bus *mii_bus;
854cace61387b6 Jiawen Wu 2023-06-06 125 struct dw_xpcs *xpcs;
854cace61387b6 Jiawen Wu 2023-06-06 126 struct pci_dev *pdev;
854cace61387b6 Jiawen Wu 2023-06-06 127 struct wx *wx;
854cace61387b6 Jiawen Wu 2023-06-06 128 int ret = 0;
854cace61387b6 Jiawen Wu 2023-06-06 129
854cace61387b6 Jiawen Wu 2023-06-06 130 wx = txgbe->wx;
854cace61387b6 Jiawen Wu 2023-06-06 131 pdev = wx->pdev;
854cace61387b6 Jiawen Wu 2023-06-06 132
854cace61387b6 Jiawen Wu 2023-06-06 133 mii_bus = devm_mdiobus_alloc(&pdev->dev);
854cace61387b6 Jiawen Wu 2023-06-06 134 if (!mii_bus)
854cace61387b6 Jiawen Wu 2023-06-06 135 return -ENOMEM;
854cace61387b6 Jiawen Wu 2023-06-06 136
854cace61387b6 Jiawen Wu 2023-06-06 137 mii_bus->name = "txgbe_pcs_mdio_bus";
854cace61387b6 Jiawen Wu 2023-06-06 138 mii_bus->read_c45 = &txgbe_pcs_read;
854cace61387b6 Jiawen Wu 2023-06-06 139 mii_bus->write_c45 = &txgbe_pcs_write;
854cace61387b6 Jiawen Wu 2023-06-06 140 mii_bus->parent = &pdev->dev;
854cace61387b6 Jiawen Wu 2023-06-06 141 mii_bus->phy_mask = ~0;
854cace61387b6 Jiawen Wu 2023-06-06 142 mii_bus->priv = wx;
854cace61387b6 Jiawen Wu 2023-06-06 143 snprintf(mii_bus->id, MII_BUS_ID_SIZE, "txgbe_pcs-%x",
d8c21ef7b2b147 Xiongfeng Wang 2023-08-08 144 pci_dev_id(pdev));
854cace61387b6 Jiawen Wu 2023-06-06 145
854cace61387b6 Jiawen Wu 2023-06-06 146 ret = devm_mdiobus_register(&pdev->dev, mii_bus);
854cace61387b6 Jiawen Wu 2023-06-06 147 if (ret)
854cace61387b6 Jiawen Wu 2023-06-06 148 return ret;
854cace61387b6 Jiawen Wu 2023-06-06 149
854cace61387b6 Jiawen Wu 2023-06-06 @150 xpcs = xpcs_create_mdiodev(mii_bus, 0, PHY_INTERFACE_MODE_10GBASER);
854cace61387b6 Jiawen Wu 2023-06-06 151 if (IS_ERR(xpcs))
854cace61387b6 Jiawen Wu 2023-06-06 152 return PTR_ERR(xpcs);
854cace61387b6 Jiawen Wu 2023-06-06 153
854cace61387b6 Jiawen Wu 2023-06-06 154 txgbe->xpcs = xpcs;
854cace61387b6 Jiawen Wu 2023-06-06 155
854cace61387b6 Jiawen Wu 2023-06-06 156 return 0;
854cace61387b6 Jiawen Wu 2023-06-06 157 }
854cace61387b6 Jiawen Wu 2023-06-06 158
On Wed, Dec 06, 2023 at 07:03:46AM +0800, kernel test robot wrote: > Hi Serge, > > kernel test robot noticed the following build errors: > > [auto build test ERROR on net-next/main] > > url: https://github.com/intel-lab-lkp/linux/commits/Serge-Semin/net-pcs-xpcs-Drop-sentinel-entry-from-2500basex-ifaces-list/20231205-183808 > base: net-next/main > patch link: https://lore.kernel.org/r/20231205103559.9605-12-fancer.lancer%40gmail.com > patch subject: [PATCH net-next 11/16] net: pcs: xpcs: Change xpcs_create_mdiodev() suffix to "byaddr" > config: arc-randconfig-001-20231206 (https://download.01.org/0day-ci/archive/20231206/202312060634.Cblfigt2-lkp@intel.com/config) > compiler: arc-elf-gcc (GCC) 13.2.0 > reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231206/202312060634.Cblfigt2-lkp@intel.com/reproduce) > > If you fix the issue in a separate patch/commit (i.e. not just a new version of > the same patch/commit), kindly add following tags > | Reported-by: kernel test robot <lkp@intel.com> > | Closes: https://lore.kernel.org/oe-kbuild-all/202312060634.Cblfigt2-lkp@intel.com/ > > All error/warnings (new ones prefixed by >>): > > drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c: In function 'txgbe_mdio_pcs_init': > >> drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:150:16: error: implicit declaration of function 'xpcs_create_mdiodev'; did you mean 'xpcs_create_byaddr'? [-Werror=implicit-function-declaration] > 150 | xpcs = xpcs_create_mdiodev(mii_bus, 0, PHY_INTERFACE_MODE_10GBASER); > | ^~~~~~~~~~~~~~~~~~~ > | xpcs_create_byaddr > >> drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c:150:14: warning: assignment to 'struct dw_xpcs *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > 150 | xpcs = xpcs_create_mdiodev(mii_bus, 0, PHY_INTERFACE_MODE_10GBASER); > | ^ > cc1: some warnings being treated as errors > > > vim +150 drivers/net/ethernet/wangxun/txgbe/txgbe_phy.c Ah, right. I had been creating the series some times earlier than this code was introduced and just missed it on the last rebase. I'll fix this on v2. -Serge(y) > > 854cace61387b6 Jiawen Wu 2023-06-06 121 > 854cace61387b6 Jiawen Wu 2023-06-06 122 static int txgbe_mdio_pcs_init(struct txgbe *txgbe) > 854cace61387b6 Jiawen Wu 2023-06-06 123 { > 854cace61387b6 Jiawen Wu 2023-06-06 124 struct mii_bus *mii_bus; > 854cace61387b6 Jiawen Wu 2023-06-06 125 struct dw_xpcs *xpcs; > 854cace61387b6 Jiawen Wu 2023-06-06 126 struct pci_dev *pdev; > 854cace61387b6 Jiawen Wu 2023-06-06 127 struct wx *wx; > 854cace61387b6 Jiawen Wu 2023-06-06 128 int ret = 0; > 854cace61387b6 Jiawen Wu 2023-06-06 129 > 854cace61387b6 Jiawen Wu 2023-06-06 130 wx = txgbe->wx; > 854cace61387b6 Jiawen Wu 2023-06-06 131 pdev = wx->pdev; > 854cace61387b6 Jiawen Wu 2023-06-06 132 > 854cace61387b6 Jiawen Wu 2023-06-06 133 mii_bus = devm_mdiobus_alloc(&pdev->dev); > 854cace61387b6 Jiawen Wu 2023-06-06 134 if (!mii_bus) > 854cace61387b6 Jiawen Wu 2023-06-06 135 return -ENOMEM; > 854cace61387b6 Jiawen Wu 2023-06-06 136 > 854cace61387b6 Jiawen Wu 2023-06-06 137 mii_bus->name = "txgbe_pcs_mdio_bus"; > 854cace61387b6 Jiawen Wu 2023-06-06 138 mii_bus->read_c45 = &txgbe_pcs_read; > 854cace61387b6 Jiawen Wu 2023-06-06 139 mii_bus->write_c45 = &txgbe_pcs_write; > 854cace61387b6 Jiawen Wu 2023-06-06 140 mii_bus->parent = &pdev->dev; > 854cace61387b6 Jiawen Wu 2023-06-06 141 mii_bus->phy_mask = ~0; > 854cace61387b6 Jiawen Wu 2023-06-06 142 mii_bus->priv = wx; > 854cace61387b6 Jiawen Wu 2023-06-06 143 snprintf(mii_bus->id, MII_BUS_ID_SIZE, "txgbe_pcs-%x", > d8c21ef7b2b147 Xiongfeng Wang 2023-08-08 144 pci_dev_id(pdev)); > 854cace61387b6 Jiawen Wu 2023-06-06 145 > 854cace61387b6 Jiawen Wu 2023-06-06 146 ret = devm_mdiobus_register(&pdev->dev, mii_bus); > 854cace61387b6 Jiawen Wu 2023-06-06 147 if (ret) > 854cace61387b6 Jiawen Wu 2023-06-06 148 return ret; > 854cace61387b6 Jiawen Wu 2023-06-06 149 > 854cace61387b6 Jiawen Wu 2023-06-06 @150 xpcs = xpcs_create_mdiodev(mii_bus, 0, PHY_INTERFACE_MODE_10GBASER); > 854cace61387b6 Jiawen Wu 2023-06-06 151 if (IS_ERR(xpcs)) > 854cace61387b6 Jiawen Wu 2023-06-06 152 return PTR_ERR(xpcs); > 854cace61387b6 Jiawen Wu 2023-06-06 153 > 854cace61387b6 Jiawen Wu 2023-06-06 154 txgbe->xpcs = xpcs; > 854cace61387b6 Jiawen Wu 2023-06-06 155 > 854cace61387b6 Jiawen Wu 2023-06-06 156 return 0; > 854cace61387b6 Jiawen Wu 2023-06-06 157 } > 854cace61387b6 Jiawen Wu 2023-06-06 158 > > -- > 0-DAY CI Kernel Test Service > https://github.com/intel/lkp-tests/wiki
diff --git a/drivers/net/dsa/sja1105/sja1105_mdio.c b/drivers/net/dsa/sja1105/sja1105_mdio.c index 833e55e4b961..9101079e365d 100644 --- a/drivers/net/dsa/sja1105/sja1105_mdio.c +++ b/drivers/net/dsa/sja1105/sja1105_mdio.c @@ -409,7 +409,7 @@ static int sja1105_mdiobus_pcs_register(struct sja1105_private *priv) priv->phy_mode[port] != PHY_INTERFACE_MODE_2500BASEX) continue; - xpcs = xpcs_create_mdiodev(bus, port, priv->phy_mode[port]); + xpcs = xpcs_create_byaddr(bus, port, priv->phy_mode[port]); if (IS_ERR(xpcs)) { rc = PTR_ERR(xpcs); goto out_pcs_free; diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c index fa9e7e7040b9..aa75e4f1e212 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c @@ -507,7 +507,7 @@ int stmmac_xpcs_setup(struct mii_bus *bus) /* Try to probe the XPCS by scanning all addresses. */ for (addr = 0; addr < PHY_MAX_ADDR; addr++) { - xpcs = xpcs_create_mdiodev(bus, addr, mode); + xpcs = xpcs_create_byaddr(bus, addr, mode); if (IS_ERR(xpcs)) continue; diff --git a/drivers/net/pcs/pcs-xpcs.c b/drivers/net/pcs/pcs-xpcs.c index 183a37929b60..e376e255f1d3 100644 --- a/drivers/net/pcs/pcs-xpcs.c +++ b/drivers/net/pcs/pcs-xpcs.c @@ -1511,8 +1511,8 @@ static struct dw_xpcs *xpcs_create(struct mdio_device *mdiodev, return ERR_PTR(ret); } -struct dw_xpcs *xpcs_create_mdiodev(struct mii_bus *bus, int addr, - phy_interface_t interface) +struct dw_xpcs *xpcs_create_byaddr(struct mii_bus *bus, int addr, + phy_interface_t interface) { struct mdio_device *mdiodev; struct dw_xpcs *xpcs; @@ -1535,7 +1535,7 @@ struct dw_xpcs *xpcs_create_mdiodev(struct mii_bus *bus, int addr, return xpcs; } -EXPORT_SYMBOL_GPL(xpcs_create_mdiodev); +EXPORT_SYMBOL_GPL(xpcs_create_byaddr); void xpcs_destroy(struct dw_xpcs *xpcs) { diff --git a/include/linux/pcs/pcs-xpcs.h b/include/linux/pcs/pcs-xpcs.h index 53adbffb4c0a..b11bbb5e820a 100644 --- a/include/linux/pcs/pcs-xpcs.h +++ b/include/linux/pcs/pcs-xpcs.h @@ -73,8 +73,8 @@ int xpcs_do_config(struct dw_xpcs *xpcs, phy_interface_t interface, void xpcs_get_interfaces(struct dw_xpcs *xpcs, unsigned long *interfaces); int xpcs_config_eee(struct dw_xpcs *xpcs, int mult_fact_100ns, int enable); -struct dw_xpcs *xpcs_create_mdiodev(struct mii_bus *bus, int addr, - phy_interface_t interface); +struct dw_xpcs *xpcs_create_byaddr(struct mii_bus *bus, int addr, + phy_interface_t interface); void xpcs_destroy(struct dw_xpcs *xpcs); #endif /* __LINUX_PCS_XPCS_H */
The fwnode-based way of creating XPCS descriptor is about to be added. In order to have a function name distinguishable from the already implemented xpcs_create_mdiodev() method convert the later name to be xpcs_create_byaddr() which BTW better describes the method semantic in anyway. Signed-off-by: Serge Semin <fancer.lancer@gmail.com> --- drivers/net/dsa/sja1105/sja1105_mdio.c | 2 +- drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c | 2 +- drivers/net/pcs/pcs-xpcs.c | 6 +++--- include/linux/pcs/pcs-xpcs.h | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-)