summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin Peng <robinpeng@google.com>2020-06-22 13:06:16 +0800
committerRobin Peng <robinpeng@google.com>2020-06-22 13:06:16 +0800
commit3019559a83db91887615015444e9110a4d6a1a5d (patch)
tree415afdafaaeac654214f5223bbfbca4e27b1b533
parent07e360796e13ec4dd54752a5d83e7a79e4ca528e (diff)
parentbed5043e1a84c58915b5e715dcf8346eb0ab0fe1 (diff)
downloaddata-kernel-3019559a83db91887615015444e9110a4d6a1a5d.tar.gz
Merge branch 'LA.UM.9.12.R2.10.00.00.685.017' into qcom-msm-4.19-7250
Change-Id: I9bf8f2c67b3b75976c91a3f059aed4df9b2899c2
-rw-r--r--drivers/rmnet/shs/rmnet_shs_config.h1
-rwxr-xr-xdrivers/rmnet/shs/rmnet_shs_main.c6
-rw-r--r--drivers/rmnet/shs/rmnet_shs_wq.c4
3 files changed, 7 insertions, 4 deletions
diff --git a/drivers/rmnet/shs/rmnet_shs_config.h b/drivers/rmnet/shs/rmnet_shs_config.h
index 10b8f58..8d318c1 100644
--- a/drivers/rmnet/shs/rmnet_shs_config.h
+++ b/drivers/rmnet/shs/rmnet_shs_config.h
@@ -48,6 +48,7 @@ enum rmnet_shs_crit_err_e {
RMNET_SHS_WQ_NL_SOCKET_ERR,
RMNET_SHS_CPU_FLOWS_BNDS_ERR,
RMNET_SHS_OUT_OF_MEM_ERR,
+ RMNET_SHS_UDP_SEGMENT,
RMNET_SHS_CRIT_ERR_MAX
};
diff --git a/drivers/rmnet/shs/rmnet_shs_main.c b/drivers/rmnet/shs/rmnet_shs_main.c
index dec38c4..36ba75d 100755
--- a/drivers/rmnet/shs/rmnet_shs_main.c
+++ b/drivers/rmnet/shs/rmnet_shs_main.c
@@ -1012,6 +1012,8 @@ void rmnet_shs_flush_node(struct rmnet_shs_skbn_s *node, u8 ctext)
skb_bytes_delivered += skb->len;
if (segs_per_skb > 0) {
+ if (node->skb_tport_proto == IPPROTO_UDP)
+ rmnet_shs_crit_err[RMNET_SHS_UDP_SEGMENT]++;
rmnet_shs_deliver_skb_segmented(skb, ctext,
segs_per_skb);
} else {
@@ -1511,7 +1513,7 @@ int rmnet_shs_drop_backlog(struct sk_buff_head *list, int cpu)
return 0;
}
-
+/* This will run in process context, avoid disabling bh */
static int rmnet_shs_oom_notify(struct notifier_block *self,
unsigned long emtpy, void *free)
{
@@ -1520,7 +1522,6 @@ static int rmnet_shs_oom_notify(struct notifier_block *self,
struct sk_buff_head *process_q;
struct sk_buff_head *input_q;
- local_bh_disable();
for_each_possible_cpu(cpu) {
process_q = &GET_PQUEUE(cpu);
@@ -1541,7 +1542,6 @@ static int rmnet_shs_oom_notify(struct notifier_block *self,
(*nfree)++;
}
}
- local_bh_enable();
return 0;
}
diff --git a/drivers/rmnet/shs/rmnet_shs_wq.c b/drivers/rmnet/shs/rmnet_shs_wq.c
index 6b2a31e..3445519 100644
--- a/drivers/rmnet/shs/rmnet_shs_wq.c
+++ b/drivers/rmnet/shs/rmnet_shs_wq.c
@@ -296,6 +296,7 @@ void rmnet_shs_wq_hstat_reset_node(struct rmnet_shs_wq_hstat_s *hnode)
hnode->hash = 0;
hnode->suggested_cpu = 0;
hnode->current_cpu = 0;
+ hnode->segs_per_skb = 0;
hnode->skb_tport_proto = 0;
hnode->stat_idx = -1;
INIT_LIST_HEAD(&hnode->cpu_node_id);
@@ -409,7 +410,8 @@ void rmnet_shs_wq_create_new_flow(struct rmnet_shs_skbn_s *node_p)
node_p->hstats->skb_tport_proto = node_p->skb_tport_proto;
node_p->hstats->current_cpu = node_p->map_cpu;
node_p->hstats->suggested_cpu = node_p->map_cpu;
-
+ /* Set egmentation off by default */
+ node_p->hstats->segs_per_skb = 0;
/* Start TCP flows with segmentation if userspace connected */
if (rmnet_shs_userspace_connected &&
node_p->hstats->skb_tport_proto == IPPROTO_TCP)