Skip to contentSkip to conversation

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c:1235:48: error: 'outl' undeclared; did you mean 'out'?

PATCH Applied kernel test robot 5 participants 6 messages Jan 8, 2022 – Jan 10, 2022

Subsystems (4)
lore
Share & tools
lore

kernel test robot

author build bot
#0 lore raw
tree:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master
head:   82192cb497f9eca6c0d44dbc173e68d59ea2f3c9
commit: 0a1498ebfa55b860e8ec929d73585bcd3fd81a4e [59/127] net/mlx5e: Expose FEC counters via ethtool
config: arm-allyesconfig (https://download.01.org/0day-ci/archive/20220109/202201090211.3kpW0hGj-lkp(a)intel.com/config)
compiler: arm-linux-gnueabi-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
# https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git/commit/?id=0a1498ebfa55b860e8ec929d73585bcd3fd81a4e
git remote add net-next https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git
git fetch --no-tags net-next master
git checkout 0a1498ebfa55b860e8ec929d73585bcd3fd81a4e
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arm SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate

All errors (new ones prefixed by >>):

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c: In function 'fec_set_block_stats':

>> drivers/net/ethernet/mellanox/mlx5/core/en_stats.c:1235:48: error: 'outl' undeclared (first use in this function); did you mean 'out'?
    1235 |         if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))
         |                                                ^~~~
         |                                                out

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c:1235:48: note: each undeclared identifier is reported only once for each function it appears in

vim +1235 drivers/net/ethernet/mellanox/mlx5/core/en_stats.c

1220
1221 static void fec_set_block_stats(struct mlx5e_priv *priv,
1222 struct ethtool_fec_stats *fec_stats)
1223 {
1224 struct mlx5_core_dev *mdev = priv->mdev;
1225 u32 out[MLX5_ST_SZ_DW(ppcnt_reg)] = {};
1226 u32 in[MLX5_ST_SZ_DW(ppcnt_reg)] = {};
1227 int sz = MLX5_ST_SZ_BYTES(ppcnt_reg);
1228 int mode = fec_active_mode(mdev);
1229
1230 if (mode == MLX5E_FEC_NOFEC)
1231 return;
1232
1233 MLX5_SET(ppcnt_reg, in, local_port, 1);
1234 MLX5_SET(ppcnt_reg, in, grp, MLX5_PHYSICAL_LAYER_COUNTERS_GROUP);

> 1235		if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))

1236 return;
1237
1238 switch (mode) {
1239 case MLX5E_FEC_RS_528_514:
1240 case MLX5E_FEC_RS_544_514:
1241 case MLX5E_FEC_LLRS_272_257_1:
1242 fec_set_rs_stats(fec_stats, out);
1243 return;
1244 case MLX5E_FEC_FIRECODE:
1245 fec_set_fc_stats(fec_stats, out, fec_num_lanes(mdev));
1246 }
1247 }
1248

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

#1 lore raw
Quoted 31 lines · kernel test robot
tree:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git master
head:   82192cb497f9eca6c0d44dbc173e68d59ea2f3c9
commit: 0a1498ebfa55b860e8ec929d73585bcd3fd81a4e [59/127] net/mlx5e: Expose FEC counters via ethtool
config: arm-allyesconfig (https://download.01.org/0day-ci/archive/20220109/202201090211.3kpW0hGj-lkp(a)intel.com/config)
compiler: arm-linux-gnueabi-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
# https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git/commit/?id=0a1498ebfa55b860e8ec929d73585bcd3fd81a4e
git remote add net-next https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git
git fetch --no-tags net-next master
git checkout 0a1498ebfa55b860e8ec929d73585bcd3fd81a4e
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arm SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate

All errors (new ones prefixed by >>):

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c: In function 'fec_set_block_stats':

Quoted 1 line
Quoted 1 line

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c:1235:48: error: 'outl' undeclared (first use in this function); did you mean 'out'?

    1235 |         if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))
         |                                                ^~~~
         |                                                out

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c:1235:48: note: each undeclared identifier is reported only once for each function it appears in

vim +1235 drivers/net/ethernet/mellanox/mlx5/core/en_stats.c

Quoted 16 lines

1220
1221 static void fec_set_block_stats(struct mlx5e_priv *priv,
1222 struct ethtool_fec_stats *fec_stats)
1223 {
1224 struct mlx5_core_dev *mdev = priv->mdev;
1225 u32 out[MLX5_ST_SZ_DW(ppcnt_reg)] = {};
1226 u32 in[MLX5_ST_SZ_DW(ppcnt_reg)] = {};
1227 int sz = MLX5_ST_SZ_BYTES(ppcnt_reg);
1228 int mode = fec_active_mode(mdev);
1229
1230 if (mode == MLX5E_FEC_NOFEC)
1231 return;
1232
1233 MLX5_SET(ppcnt_reg, in, local_port, 1);
1234 MLX5_SET(ppcnt_reg, in, grp, MLX5_PHYSICAL_LAYER_COUNTERS_GROUP);

Quoted 1 line

1235 if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))

Obviously, this should be "out" and not "outl".

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c +1 -1
index 7e7c0c1019f6..26e326fe503c 100644
@@ -1232,7 +1232,7 @@ static void fec_set_block_stats(struct mlx5e_priv *priv,
 
        MLX5_SET(ppcnt_reg, in, local_port, 1);
        MLX5_SET(ppcnt_reg, in, grp, MLX5_PHYSICAL_LAYER_COUNTERS_GROUP);
-       if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))
+       if (mlx5_core_access_reg(mdev, in, sz, out, sz, MLX5_REG_PPCNT, 0, 0))
                return;
 
        switch (mode) {
Quoted 17 lines
  1236			return;
  1237	
  1238		switch (mode) {
  1239		case MLX5E_FEC_RS_528_514:
  1240		case MLX5E_FEC_RS_544_514:
  1241		case MLX5E_FEC_LLRS_272_257_1:
  1242			fec_set_rs_stats(fec_stats, out);
  1243			return;
  1244		case MLX5E_FEC_FIRECODE:
  1245			fec_set_fc_stats(fec_stats, out, fec_num_lanes(mdev));
  1246		}
  1247	}
  1248	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

maintainer
#2 lore raw

PATCH 1/1 net/mlx5e: Fix build error in fec_set_block_stats()

Build bot reports:

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c: In function 'fec_set_block_stats':
drivers/net/ethernet/mellanox/mlx5/core/en_stats.c:1235:48: error: 'outl' undeclared (first use in this function); did you mean 'out'?

    1235 |         if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))
         |                                                ^~~~
         |                                                out
---
 drivers/net/ethernet/mellanox/mlx5/core/en_stats.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/mellanox/mlx5/core/en_stats.c +1 -1
index 7e7c0c1019f6..26e326fe503c 100644
@@ -1232,7 +1232,7 @@ static void fec_set_block_stats(struct mlx5e_priv *priv,
 
 	MLX5_SET(ppcnt_reg, in, local_port, 1);
 	MLX5_SET(ppcnt_reg, in, grp, MLX5_PHYSICAL_LAYER_COUNTERS_GROUP);
-	if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))
+	if (mlx5_core_access_reg(mdev, in, sz, out, sz, MLX5_REG_PPCNT, 0, 0))
 		return;
 
 	switch (mode) {
Signature · 1 line
2.31.1
#3 lore raw

Re: [PATCH net-next] net/mlx5e: Fix build error in fec_set_block_stats()

This patch was applied to netdev/net-next.git (master) by Jakub Kicinski <[email protected]>:

Hello:

This patch was applied to netdev/net-next.git (master) by Jakub Kicinski <[email protected]>:

Quoted 9 lines · On Sun, 9 Jan 2022 13:33:21 -0800 you wrote:

Build bot reports:

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c: In function 'fec_set_block_stats':
drivers/net/ethernet/mellanox/mlx5/core/en_stats.c:1235:48: error: 'outl' undeclared (first use in this function); did you mean 'out'?

    1235 |         if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))
         |                                                ^~~~
         |                                                out

[...]

Here is the summary with links:
- [net-next] net/mlx5e: Fix build error in fec_set_block_stats()

    https://git.kernel.org/netdev/net-next/c/342402c42690

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
#4 lore raw

Re: [PATCH net-next] net/mlx5e: Fix build error in fec_set_block_stats()

In reply to Jakub Kicinski
Quoted 11 lines · Jakub Kicinski

Build bot reports:

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c: In function 'fec_set_block_stats':
drivers/net/ethernet/mellanox/mlx5/core/en_stats.c:1235:48: error: 'outl' undeclared (first use in this function); did you mean 'out'?

   1235 |         if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))
        |                                                ^~~~
        |                                                out

Thanks For handling ! I have no clue how this happened.
I will check and improve my process, I Know I've manually changed a patch before submission, but i am sure i did it through my normal process.

Interestingly the series passed netdev/build_allmodconfig_warn. https://patchwork.kernel.org/project/netdevbpf/patch/[email protected]/

maintainer
#5 lore raw

Re: [PATCH net-next] net/mlx5e: Fix build error in fec_set_block_stats()

Quoted 13 lines · On Mon, 10 Jan 2022 12:33:54 -0800 Saeed Mahameed wrote:
Quoted 11 lines · Jakub Kicinski

Build bot reports:

drivers/net/ethernet/mellanox/mlx5/core/en_stats.c: In function 'fec_set_block_stats':
drivers/net/ethernet/mellanox/mlx5/core/en_stats.c:1235:48: error: 'outl' undeclared (first use in this function); did you mean 'out'?

   1235 |         if (mlx5_core_access_reg(mdev, in, sz, outl, sz, MLX5_REG_PPCNT, 0, 0))
        |                                                ^~~~
        |                                                out
Quoted 6 lines

Thanks For handling ! I have no clue how this happened.
I will check and improve my process, I Know I've manually changed a patch before submission, but i am sure i did it through my normal process.

Interestingly the series passed netdev/build_allmodconfig_warn.
https://patchwork.kernel.org/project/netdevbpf/patch/[email protected]/

And it built just fine for me as well with allmodconfig.

LMK if you figure out why, that's really strange.