[<prev] [next>] [day] [month] [year] [list]
Message-ID: <201704091302.vVZHXX84%fengguang.wu@intel.com>
Date: Sun, 9 Apr 2017 13:40:04 +0800
From: kbuild test robot <fengguang.wu@...el.com>
To: Steffen Klassert <steffen.klassert@...unet.com>
Cc: kbuild-all@...org, linux-kernel@...r.kernel.org
Subject: net/core/dev.c:4508:19-26: ERROR: PTR_ERR applied after
initialization to constant on line 4452
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 78d91a75b40fcf6a08506d308abf2413a29b7e30
commit: 25393d3fc055b76587fcc91627aee8c345400c3a net: Prepare gro for packet consuming gro callbacks
date: 8 weeks ago
coccinelle warnings: (new ones prefixed by >>)
>> net/core/dev.c:4508:19-26: ERROR: PTR_ERR applied after initialization to constant on line 4452
vim +4508 net/core/dev.c
4446 --pinfo->nr_frags * sizeof(pinfo->frags[0]));
4447 }
4448 }
4449
4450 static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff *skb)
4451 {
> 4452 struct sk_buff **pp = NULL;
4453 struct packet_offload *ptype;
4454 __be16 type = skb->protocol;
4455 struct list_head *head = &offload_base;
4456 int same_flow;
4457 enum gro_result ret;
4458 int grow;
4459
4460 if (!(skb->dev->features & NETIF_F_GRO))
4461 goto normal;
4462
4463 if (skb->csum_bad)
4464 goto normal;
4465
4466 gro_list_prepare(napi, skb);
4467
4468 rcu_read_lock();
4469 list_for_each_entry_rcu(ptype, head, list) {
4470 if (ptype->type != type || !ptype->callbacks.gro_receive)
4471 continue;
4472
4473 skb_set_network_header(skb, skb_gro_offset(skb));
4474 skb_reset_mac_len(skb);
4475 NAPI_GRO_CB(skb)->same_flow = 0;
4476 NAPI_GRO_CB(skb)->flush = skb_is_gso(skb) || skb_has_frag_list(skb);
4477 NAPI_GRO_CB(skb)->free = 0;
4478 NAPI_GRO_CB(skb)->encap_mark = 0;
4479 NAPI_GRO_CB(skb)->recursion_counter = 0;
4480 NAPI_GRO_CB(skb)->is_fou = 0;
4481 NAPI_GRO_CB(skb)->is_atomic = 1;
4482 NAPI_GRO_CB(skb)->gro_remcsum_start = 0;
4483
4484 /* Setup for GRO checksum validation */
4485 switch (skb->ip_summed) {
4486 case CHECKSUM_COMPLETE:
4487 NAPI_GRO_CB(skb)->csum = skb->csum;
4488 NAPI_GRO_CB(skb)->csum_valid = 1;
4489 NAPI_GRO_CB(skb)->csum_cnt = 0;
4490 break;
4491 case CHECKSUM_UNNECESSARY:
4492 NAPI_GRO_CB(skb)->csum_cnt = skb->csum_level + 1;
4493 NAPI_GRO_CB(skb)->csum_valid = 0;
4494 break;
4495 default:
4496 NAPI_GRO_CB(skb)->csum_cnt = 0;
4497 NAPI_GRO_CB(skb)->csum_valid = 0;
4498 }
4499
4500 pp = ptype->callbacks.gro_receive(&napi->gro_list, skb);
4501 break;
4502 }
4503 rcu_read_unlock();
4504
4505 if (&ptype->list == head)
4506 goto normal;
4507
> 4508 if (IS_ERR(pp) && PTR_ERR(pp) == -EINPROGRESS) {
4509 ret = GRO_CONSUMED;
4510 goto ok;
4511 }
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
Powered by blists - more mailing lists