Content-Type: multipart/mixed; boundary="===============3017868928955777116==" MIME-Version: 1.0 From: Michael S. Tsirkin To: kbuild-all@lists.01.org Subject: Re: [PATCH v4 3/4] drivers/net/virtio_net: Added RSS hash report. Date: Fri, 04 Mar 2022 03:08:04 -0500 Message-ID: <20220304030742-mutt-send-email-mst@kernel.org> In-Reply-To: <202202230342.HPYe6dHA-lkp@intel.com> List-Id: --===============3017868928955777116== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable On Wed, Feb 23, 2022 at 03:15:28AM +0800, kernel test robot wrote: > Hi Andrew, > = > Thank you for the patch! Perhaps something to improve: > = > [auto build test WARNING on mst-vhost/linux-next] > [also build test WARNING on net/master horms-ipvs/master net-next/master = linus/master v5.17-rc5 next-20220217] > [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] Andrew, do you plan to fix this? > url: https://github.com/0day-ci/linux/commits/Andrew-Melnychenko/RSS-s= upport-for-VirtioNet/20220222-200334 > base: https://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost.git lin= ux-next > config: i386-randconfig-s002-20220221 (https://download.01.org/0day-ci/ar= chive/20220223/202202230342.HPYe6dHA-lkp(a)intel.com/config) > compiler: gcc-9 (Debian 9.3.0-22) 9.3.0 > reproduce: > # apt-get install sparse > # sparse version: v0.6.4-dirty > # https://github.com/0day-ci/linux/commit/4fda71c17afd24d8afb675b= aa0bb14dbbc6cd23c > git remote add linux-review https://github.com/0day-ci/linux > git fetch --no-tags linux-review Andrew-Melnychenko/RSS-support-f= or-VirtioNet/20220222-200334 > git checkout 4fda71c17afd24d8afb675baa0bb14dbbc6cd23c > # save the config file to linux build tree > mkdir build_dir > make W=3D1 C=3D1 CF=3D'-fdiagnostic-prefix -D__CHECK_ENDIAN__' O= =3Dbuild_dir ARCH=3Di386 SHELL=3D/bin/bash > = > If you fix the issue, kindly add following tag as appropriate > Reported-by: kernel test robot > = > = > sparse warnings: (new ones prefixed by >>) > drivers/net/virtio_net.c:1160:25: sparse: sparse: restricted __le16 de= grades to integer > drivers/net/virtio_net.c:1160:25: sparse: sparse: restricted __le16 de= grades to integer > drivers/net/virtio_net.c:1160:25: sparse: sparse: restricted __le16 de= grades to integer > drivers/net/virtio_net.c:1160:25: sparse: sparse: restricted __le16 de= grades to integer > drivers/net/virtio_net.c:1160:25: sparse: sparse: restricted __le16 de= grades to integer > drivers/net/virtio_net.c:1160:25: sparse: sparse: restricted __le16 de= grades to integer > drivers/net/virtio_net.c:1160:25: sparse: sparse: restricted __le16 de= grades to integer > drivers/net/virtio_net.c:1160:25: sparse: sparse: restricted __le16 de= grades to integer > drivers/net/virtio_net.c:1160:25: sparse: sparse: restricted __le16 de= grades to integer > >> drivers/net/virtio_net.c:1178:35: sparse: sparse: incorrect type in ar= gument 2 (different base types) @@ expected unsigned int [usertype] has= h @@ got restricted __le32 const [usertype] hash_value @@ > drivers/net/virtio_net.c:1178:35: sparse: expected unsigned int [u= sertype] hash > drivers/net/virtio_net.c:1178:35: sparse: got restricted __le32 co= nst [usertype] hash_value > = > vim +1178 drivers/net/virtio_net.c > = > 1151 = > 1152 static void virtio_skb_set_hash(const struct virtio_net_hdr_v1_has= h *hdr_hash, > 1153 struct sk_buff *skb) > 1154 { > 1155 enum pkt_hash_types rss_hash_type; > 1156 = > 1157 if (!hdr_hash || !skb) > 1158 return; > 1159 = > 1160 switch (hdr_hash->hash_report) { > 1161 case VIRTIO_NET_HASH_REPORT_TCPv4: > 1162 case VIRTIO_NET_HASH_REPORT_UDPv4: > 1163 case VIRTIO_NET_HASH_REPORT_TCPv6: > 1164 case VIRTIO_NET_HASH_REPORT_UDPv6: > 1165 case VIRTIO_NET_HASH_REPORT_TCPv6_EX: > 1166 case VIRTIO_NET_HASH_REPORT_UDPv6_EX: > 1167 rss_hash_type =3D PKT_HASH_TYPE_L4; > 1168 break; > 1169 case VIRTIO_NET_HASH_REPORT_IPv4: > 1170 case VIRTIO_NET_HASH_REPORT_IPv6: > 1171 case VIRTIO_NET_HASH_REPORT_IPv6_EX: > 1172 rss_hash_type =3D PKT_HASH_TYPE_L3; > 1173 break; > 1174 case VIRTIO_NET_HASH_REPORT_NONE: > 1175 default: > 1176 rss_hash_type =3D PKT_HASH_TYPE_NONE; > 1177 } > > 1178 skb_set_hash(skb, hdr_hash->hash_value, rss_hash_type); > 1179 } > 1180 = > = > --- > 0-DAY CI Kernel Test Service, Intel Corporation > https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org --===============3017868928955777116==--