[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202511220109.1PvI00Sr-lkp@intel.com>
Date: Sat, 22 Nov 2025 02:07:20 +0800
From: kernel test robot <lkp@...el.com>
To: Ma Ke <make24@...as.ac.cn>, andrew@...n.ch, olteanv@...il.com,
davem@...emloft.net, edumazet@...gle.com, kuba@...nel.org,
pabeni@...hat.com, horms@...nel.org, florian.fainelli@...adcom.com,
stephen@...workplumber.org, robh@...nel.org
Cc: llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
akpm@...ux-foundation.org, Ma Ke <make24@...as.ac.cn>,
stable@...r.kernel.org
Subject: Re: [PATCH] net: dsa: Fix error handling in dsa_port_parse_of
Hi Ma,
kernel test robot noticed the following build errors:
[auto build test ERROR on net-next/main]
[also build test ERROR on net/main linus/master v6.18-rc6 next-20251121]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Ma-Ke/net-dsa-Fix-error-handling-in-dsa_port_parse_of/20251121-115449
base: net-next/main
patch link: https://lore.kernel.org/r/20251121035130.16020-1-make24%40iscas.ac.cn
patch subject: [PATCH] net: dsa: Fix error handling in dsa_port_parse_of
config: i386-randconfig-004-20251121 (https://download.01.org/0day-ci/archive/20251122/202511220109.1PvI00Sr-lkp@intel.com/config)
compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251122/202511220109.1PvI00Sr-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202511220109.1PvI00Sr-lkp@intel.com/
All errors (new ones prefixed by >>):
>> net/dsa/dsa.c:1265:15: error: incompatible pointer types passing 'struct net_device *' to parameter of type 'struct device *' [-Werror,-Wincompatible-pointer-types]
1265 | put_device(conduit);
| ^~~~~~~
include/linux/device.h:1181:32: note: passing argument to parameter 'dev' here
1181 | void put_device(struct device *dev);
| ^
1 error generated.
vim +1265 net/dsa/dsa.c
1243
1244 static int dsa_port_parse_of(struct dsa_port *dp, struct device_node *dn)
1245 {
1246 struct device_node *ethernet = of_parse_phandle(dn, "ethernet", 0);
1247 const char *name = of_get_property(dn, "label", NULL);
1248 bool link = of_property_read_bool(dn, "link");
1249 int err;
1250
1251 dp->dn = dn;
1252
1253 if (ethernet) {
1254 struct net_device *conduit;
1255 const char *user_protocol;
1256
1257 conduit = of_find_net_device_by_node(ethernet);
1258 of_node_put(ethernet);
1259 if (!conduit)
1260 return -EPROBE_DEFER;
1261
1262 user_protocol = of_get_property(dn, "dsa-tag-protocol", NULL);
1263 err = dsa_port_parse_cpu(dp, conduit, user_protocol);
1264 if (err) {
> 1265 put_device(conduit);
1266 return err;
1267 }
1268
1269 return 0;
1270 }
1271
1272 if (link)
1273 return dsa_port_parse_dsa(dp);
1274
1275 return dsa_port_parse_user(dp, name);
1276 }
1277
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists