Re: [PATCH 1/1] net: Allow all multicast packets to be received on a interface.

From: kernel test robot
Date: Thu Jun 17 2021 - 15:32:16 EST


Hi Callum,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on linus/master]
[also build test ERROR on v5.13-rc6 next-20210617]
[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]

url: https://github.com/0day-ci/linux/commits/Callum-Sinclair/Create-multicast-snooping-sysctl-option/20210617-175212
base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 70585216fe7730d9fb5453d3e2804e149d0fe201
config: x86_64-randconfig-r024-20210617 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 64720f57bea6a6bf033feef4a5751ab9c0c3b401)
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
# install x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
# https://github.com/0day-ci/linux/commit/4220b6837f4315ff557bd44f7aada23b69e181b6
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Callum-Sinclair/Create-multicast-snooping-sysctl-option/20210617-175212
git checkout 4220b6837f4315ff557bd44f7aada23b69e181b6
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

>> net/ipv4/devinet.c:2069:4: error: use of undeclared identifier 'IPV4_DEVCONF_NETCONFA_MC_SNOOPING'; did you mean 'IPV4_DEVCONF_MC_SNOOPING'?
IPV4_DEVCONF(*devconf, NETCONFA_MC_SNOOPING)) < 0)
^
include/linux/inetdevice.h:53:45: note: expanded from macro 'IPV4_DEVCONF'
#define IPV4_DEVCONF(cnf, attr) ((cnf).data[IPV4_DEVCONF_ ## attr - 1])
^
<scratch space>:121:1: note: expanded from here
IPV4_DEVCONF_NETCONFA_MC_SNOOPING
^
include/uapi/linux/ip.h:172:2: note: 'IPV4_DEVCONF_MC_SNOOPING' declared here
IPV4_DEVCONF_MC_SNOOPING,
^
1 error generated.


vim +2069 net/ipv4/devinet.c

2028
2029 static int inet_netconf_fill_devconf(struct sk_buff *skb, int ifindex,
2030 struct ipv4_devconf *devconf, u32 portid,
2031 u32 seq, int event, unsigned int flags,
2032 int type)
2033 {
2034 struct nlmsghdr *nlh;
2035 struct netconfmsg *ncm;
2036 bool all = false;
2037
2038 nlh = nlmsg_put(skb, portid, seq, event, sizeof(struct netconfmsg),
2039 flags);
2040 if (!nlh)
2041 return -EMSGSIZE;
2042
2043 if (type == NETCONFA_ALL)
2044 all = true;
2045
2046 ncm = nlmsg_data(nlh);
2047 ncm->ncm_family = AF_INET;
2048
2049 if (nla_put_s32(skb, NETCONFA_IFINDEX, ifindex) < 0)
2050 goto nla_put_failure;
2051
2052 if (!devconf)
2053 goto out;
2054
2055 if ((all || type == NETCONFA_FORWARDING) &&
2056 nla_put_s32(skb, NETCONFA_FORWARDING,
2057 IPV4_DEVCONF(*devconf, FORWARDING)) < 0)
2058 goto nla_put_failure;
2059 if ((all || type == NETCONFA_RP_FILTER) &&
2060 nla_put_s32(skb, NETCONFA_RP_FILTER,
2061 IPV4_DEVCONF(*devconf, RP_FILTER)) < 0)
2062 goto nla_put_failure;
2063 if ((all || type == NETCONFA_MC_FORWARDING) &&
2064 nla_put_s32(skb, NETCONFA_MC_FORWARDING,
2065 IPV4_DEVCONF(*devconf, MC_FORWARDING)) < 0)
2066 goto nla_put_failure;
2067 if ((all || type == NETCONFA_MC_SNOOPING) &&
2068 nla_put_s32(skb, NETCONFA_MC_SNOOPING,
> 2069 IPV4_DEVCONF(*devconf, NETCONFA_MC_SNOOPING)) < 0)
2070 goto nla_put_failure;
2071 if ((all || type == NETCONFA_BC_FORWARDING) &&
2072 nla_put_s32(skb, NETCONFA_BC_FORWARDING,
2073 IPV4_DEVCONF(*devconf, BC_FORWARDING)) < 0)
2074 goto nla_put_failure;
2075 if ((all || type == NETCONFA_PROXY_NEIGH) &&
2076 nla_put_s32(skb, NETCONFA_PROXY_NEIGH,
2077 IPV4_DEVCONF(*devconf, PROXY_ARP)) < 0)
2078 goto nla_put_failure;
2079 if ((all || type == NETCONFA_IGNORE_ROUTES_WITH_LINKDOWN) &&
2080 nla_put_s32(skb, NETCONFA_IGNORE_ROUTES_WITH_LINKDOWN,
2081 IPV4_DEVCONF(*devconf, IGNORE_ROUTES_WITH_LINKDOWN)) < 0)
2082 goto nla_put_failure;
2083
2084 out:
2085 nlmsg_end(skb, nlh);
2086 return 0;
2087
2088 nla_put_failure:
2089 nlmsg_cancel(skb, nlh);
2090 return -EMSGSIZE;
2091 }
2092

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

Attachment: .config.gz
Description: application/gzip