Loading drivers/platform/msm/ipa/ipa_v3/ipa_dp.c +4 −1 Original line number Diff line number Diff line Loading @@ -3748,6 +3748,9 @@ static int ipa3_assign_policy(struct ipa_sys_connect_params *in, IPA_GENERIC_RX_BUFF_BASE_SZ); sys->get_skb = ipa3_get_skb_ipa_rx; sys->free_skb = ipa3_free_skb_rx; if (in->bypass_agg) in->ipa_ep_cfg.aggr.aggr_en = IPA_BYPASS_AGGR; else in->ipa_ep_cfg.aggr.aggr_en = IPA_ENABLE_AGGR; if (in->client == IPA_CLIENT_APPS_WAN_COAL_CONS) in->ipa_ep_cfg.aggr.aggr = IPA_COALESCE; Loading drivers/platform/msm/ipa/ipa_v3/rmnet_ipa.c +37 −14 Original line number Diff line number Diff line /* Copyright (c) 2014-2019, The Linux Foundation. All rights reserved. /* Copyright (c) 2014-2020, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -171,6 +171,7 @@ struct rmnet_ipa3_context { atomic_t ap_suspend; bool ipa_config_is_apq; bool ipa_mhi_aggr_formet_set; bool no_qmap_config; }; static struct rmnet_ipa3_context *rmnet_ipa3_ctx; Loading Loading @@ -1248,7 +1249,8 @@ static int ipa3_wwan_xmit(struct sk_buff *skb, struct net_device *dev) return NETDEV_TX_OK; } if (skb->protocol != htons(ETH_P_MAP)) { if (skb->protocol != htons(ETH_P_MAP) && (!rmnet_ipa3_ctx->no_qmap_config)) { IPAWANDBG_LOW ("SW filtering out none QMAP packet received from %s", current->comm); Loading @@ -1269,6 +1271,10 @@ static int ipa3_wwan_xmit(struct sk_buff *skb, struct net_device *dev) return NETDEV_TX_BUSY; } if (netif_queue_stopped(dev)) { if (rmnet_ipa3_ctx->no_qmap_config) { spin_unlock_irqrestore(&wwan_ptr->lock, flags); return NETDEV_TX_BUSY; } else { if (qmap_check && atomic_read(&wwan_ptr->outstanding_pkts) < outstanding_high_ctl) { Loading @@ -1282,6 +1288,7 @@ static int ipa3_wwan_xmit(struct sk_buff *skb, struct net_device *dev) return NETDEV_TX_BUSY; } } } /* checking High WM hit */ if (atomic_read(&wwan_ptr->outstanding_pkts) >= Loading Loading @@ -1450,6 +1457,7 @@ static void apps_ipa_packet_receive_notify(void *priv, IPAWANDBG_LOW("Rx packet was received"); skb->dev = IPA_NETDEV(); if (!rmnet_ipa3_ctx->no_qmap_config) skb->protocol = htons(ETH_P_MAP); if (ipa3_rmnet_res.ipa_napi_enable) { Loading Loading @@ -1524,6 +1532,12 @@ static int handle3_ingress_format(struct net_device *dev, IPAWANDBG("DL chksum set\n"); } if ((in->u.data) & RMNET_IOCTL_INGRESS_FORMAT_IP_ROUTE) { rmnet_ipa3_ctx->no_qmap_config = true; ipa_wan_ep_cfg->bypass_agg = true; } if ((in->u.data) & RMNET_IOCTL_INGRESS_FORMAT_AGG_DATA) { IPAWANDBG("get AGG size %d count %d\n", in->u.ingress_format.agg_size, Loading @@ -1546,8 +1560,11 @@ static int handle3_ingress_format(struct net_device *dev, ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 8; rmnet_ipa3_ctx->dl_csum_offload_enabled = true; } else { ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 4; rmnet_ipa3_ctx->dl_csum_offload_enabled = false; if (rmnet_ipa3_ctx->no_qmap_config) ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 0; else ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 4; } ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_ofst_metadata_valid = 1; Loading Loading @@ -1652,6 +1669,9 @@ static int handle3_egress_format(struct net_device *dev, return -EFAULT; } if ((e->u.data) & RMNET_IOCTL_EGRESS_FORMAT_IP_ROUTE) rmnet_ipa3_ctx->no_qmap_config = true; ipa_wan_ep_cfg = &rmnet_ipa3_ctx->apps_to_ipa_ep_cfg; if ((e->u.data) & RMNET_IOCTL_EGRESS_FORMAT_CHECKSUM) { IPAWANDBG("UL chksum set\n"); Loading @@ -1660,6 +1680,9 @@ static int handle3_egress_format(struct net_device *dev, IPA_ENABLE_CS_OFFLOAD_UL; ipa_wan_ep_cfg->ipa_ep_cfg.cfg.cs_metadata_hdr_offset = 1; } else { if (rmnet_ipa3_ctx->no_qmap_config) ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 0; else ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 4; } Loading include/linux/ipa.h +2 −0 Original line number Diff line number Diff line Loading @@ -682,6 +682,7 @@ struct ipa_ext_intf { * by IPA driver * @keep_ipa_awake: when true, IPA will not be clock gated * @napi_enabled: when true, IPA call client callback to start polling * @bypass_agg: when true, IPA bypasses the aggregation */ struct ipa_sys_connect_params { struct ipa_ep_cfg ipa_ep_cfg; Loading @@ -694,6 +695,7 @@ struct ipa_sys_connect_params { struct napi_struct *napi_obj; bool napi_enabled; bool recycle_enabled; bool bypass_agg; }; /** Loading Loading
drivers/platform/msm/ipa/ipa_v3/ipa_dp.c +4 −1 Original line number Diff line number Diff line Loading @@ -3748,6 +3748,9 @@ static int ipa3_assign_policy(struct ipa_sys_connect_params *in, IPA_GENERIC_RX_BUFF_BASE_SZ); sys->get_skb = ipa3_get_skb_ipa_rx; sys->free_skb = ipa3_free_skb_rx; if (in->bypass_agg) in->ipa_ep_cfg.aggr.aggr_en = IPA_BYPASS_AGGR; else in->ipa_ep_cfg.aggr.aggr_en = IPA_ENABLE_AGGR; if (in->client == IPA_CLIENT_APPS_WAN_COAL_CONS) in->ipa_ep_cfg.aggr.aggr = IPA_COALESCE; Loading
drivers/platform/msm/ipa/ipa_v3/rmnet_ipa.c +37 −14 Original line number Diff line number Diff line /* Copyright (c) 2014-2019, The Linux Foundation. All rights reserved. /* Copyright (c) 2014-2020, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -171,6 +171,7 @@ struct rmnet_ipa3_context { atomic_t ap_suspend; bool ipa_config_is_apq; bool ipa_mhi_aggr_formet_set; bool no_qmap_config; }; static struct rmnet_ipa3_context *rmnet_ipa3_ctx; Loading Loading @@ -1248,7 +1249,8 @@ static int ipa3_wwan_xmit(struct sk_buff *skb, struct net_device *dev) return NETDEV_TX_OK; } if (skb->protocol != htons(ETH_P_MAP)) { if (skb->protocol != htons(ETH_P_MAP) && (!rmnet_ipa3_ctx->no_qmap_config)) { IPAWANDBG_LOW ("SW filtering out none QMAP packet received from %s", current->comm); Loading @@ -1269,6 +1271,10 @@ static int ipa3_wwan_xmit(struct sk_buff *skb, struct net_device *dev) return NETDEV_TX_BUSY; } if (netif_queue_stopped(dev)) { if (rmnet_ipa3_ctx->no_qmap_config) { spin_unlock_irqrestore(&wwan_ptr->lock, flags); return NETDEV_TX_BUSY; } else { if (qmap_check && atomic_read(&wwan_ptr->outstanding_pkts) < outstanding_high_ctl) { Loading @@ -1282,6 +1288,7 @@ static int ipa3_wwan_xmit(struct sk_buff *skb, struct net_device *dev) return NETDEV_TX_BUSY; } } } /* checking High WM hit */ if (atomic_read(&wwan_ptr->outstanding_pkts) >= Loading Loading @@ -1450,6 +1457,7 @@ static void apps_ipa_packet_receive_notify(void *priv, IPAWANDBG_LOW("Rx packet was received"); skb->dev = IPA_NETDEV(); if (!rmnet_ipa3_ctx->no_qmap_config) skb->protocol = htons(ETH_P_MAP); if (ipa3_rmnet_res.ipa_napi_enable) { Loading Loading @@ -1524,6 +1532,12 @@ static int handle3_ingress_format(struct net_device *dev, IPAWANDBG("DL chksum set\n"); } if ((in->u.data) & RMNET_IOCTL_INGRESS_FORMAT_IP_ROUTE) { rmnet_ipa3_ctx->no_qmap_config = true; ipa_wan_ep_cfg->bypass_agg = true; } if ((in->u.data) & RMNET_IOCTL_INGRESS_FORMAT_AGG_DATA) { IPAWANDBG("get AGG size %d count %d\n", in->u.ingress_format.agg_size, Loading @@ -1546,8 +1560,11 @@ static int handle3_ingress_format(struct net_device *dev, ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 8; rmnet_ipa3_ctx->dl_csum_offload_enabled = true; } else { ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 4; rmnet_ipa3_ctx->dl_csum_offload_enabled = false; if (rmnet_ipa3_ctx->no_qmap_config) ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 0; else ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 4; } ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_ofst_metadata_valid = 1; Loading Loading @@ -1652,6 +1669,9 @@ static int handle3_egress_format(struct net_device *dev, return -EFAULT; } if ((e->u.data) & RMNET_IOCTL_EGRESS_FORMAT_IP_ROUTE) rmnet_ipa3_ctx->no_qmap_config = true; ipa_wan_ep_cfg = &rmnet_ipa3_ctx->apps_to_ipa_ep_cfg; if ((e->u.data) & RMNET_IOCTL_EGRESS_FORMAT_CHECKSUM) { IPAWANDBG("UL chksum set\n"); Loading @@ -1660,6 +1680,9 @@ static int handle3_egress_format(struct net_device *dev, IPA_ENABLE_CS_OFFLOAD_UL; ipa_wan_ep_cfg->ipa_ep_cfg.cfg.cs_metadata_hdr_offset = 1; } else { if (rmnet_ipa3_ctx->no_qmap_config) ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 0; else ipa_wan_ep_cfg->ipa_ep_cfg.hdr.hdr_len = 4; } Loading
include/linux/ipa.h +2 −0 Original line number Diff line number Diff line Loading @@ -682,6 +682,7 @@ struct ipa_ext_intf { * by IPA driver * @keep_ipa_awake: when true, IPA will not be clock gated * @napi_enabled: when true, IPA call client callback to start polling * @bypass_agg: when true, IPA bypasses the aggregation */ struct ipa_sys_connect_params { struct ipa_ep_cfg ipa_ep_cfg; Loading @@ -694,6 +695,7 @@ struct ipa_sys_connect_params { struct napi_struct *napi_obj; bool napi_enabled; bool recycle_enabled; bool bypass_agg; }; /** Loading