Loading drivers/soc/qcom/dfc_qmi.c +18 −7 Original line number Diff line number Diff line Loading @@ -989,7 +989,8 @@ static u32 dfc_adjust_grant(struct rmnet_bearer_map *bearer, static int dfc_update_fc_map(struct net_device *dev, struct qos_info *qos, u8 ack_req, u32 ancillary, struct dfc_flow_status_info_type_v01 *fc_info, bool is_query) bool is_query, int index) { struct rmnet_bearer_map *itm = NULL; int rc = 0; Loading @@ -1010,9 +1011,16 @@ static int dfc_update_fc_map(struct net_device *dev, struct qos_info *qos, if (itm->rat_switch) return 0; /* If TX is OFF but we received grant, ignore it */ if (itm->tx_off && fc_info->num_bytes > 0) /* If TX is OFF but we received grant from the same modem, * ignore it. If the grant is from a different modem, * assume TX had become ON. */ if (itm->tx_off && fc_info->num_bytes > 0) { if (itm->tx_status_index == index) return 0; itm->tx_off = false; itm->tx_status_index = index; } /* Adjuste grant for query */ if (dfc_qmap && is_query) { Loading Loading @@ -1120,7 +1128,7 @@ void dfc_do_burst_flow_control(struct dfc_qmi_data *dfc, else dfc_update_fc_map( dev, qos, ack_req, ancillary, flow_status, is_query); is_query, dfc->index); spin_unlock_bh(&qos->qos_lock); } Loading @@ -1131,7 +1139,8 @@ void dfc_do_burst_flow_control(struct dfc_qmi_data *dfc, static void dfc_update_tx_link_status(struct net_device *dev, struct qos_info *qos, u8 tx_status, struct dfc_bearer_info_type_v01 *binfo) struct dfc_bearer_info_type_v01 *binfo, int index) { struct rmnet_bearer_map *itm = NULL; Loading @@ -1139,6 +1148,8 @@ static void dfc_update_tx_link_status(struct net_device *dev, if (!itm) return; itm->tx_status_index = index; /* If no change in tx status, ignore */ if (itm->tx_off == !tx_status) return; Loading Loading @@ -1190,7 +1201,7 @@ void dfc_handle_tx_link_status_ind(struct dfc_qmi_data *dfc, spin_lock_bh(&qos->qos_lock); dfc_update_tx_link_status( dev, qos, ind->tx_status, bearer_info); dev, qos, ind->tx_status, bearer_info, dfc->index); spin_unlock_bh(&qos->qos_lock); } Loading drivers/soc/qcom/qmi_rmnet_i.h +1 −0 Original line number Diff line number Diff line Loading @@ -51,6 +51,7 @@ struct rmnet_bearer_map { bool tcp_bidir; bool rat_switch; bool tx_off; int tx_status_index; u32 ack_txid; u32 mq_idx; u32 ack_mq_idx; Loading Loading
drivers/soc/qcom/dfc_qmi.c +18 −7 Original line number Diff line number Diff line Loading @@ -989,7 +989,8 @@ static u32 dfc_adjust_grant(struct rmnet_bearer_map *bearer, static int dfc_update_fc_map(struct net_device *dev, struct qos_info *qos, u8 ack_req, u32 ancillary, struct dfc_flow_status_info_type_v01 *fc_info, bool is_query) bool is_query, int index) { struct rmnet_bearer_map *itm = NULL; int rc = 0; Loading @@ -1010,9 +1011,16 @@ static int dfc_update_fc_map(struct net_device *dev, struct qos_info *qos, if (itm->rat_switch) return 0; /* If TX is OFF but we received grant, ignore it */ if (itm->tx_off && fc_info->num_bytes > 0) /* If TX is OFF but we received grant from the same modem, * ignore it. If the grant is from a different modem, * assume TX had become ON. */ if (itm->tx_off && fc_info->num_bytes > 0) { if (itm->tx_status_index == index) return 0; itm->tx_off = false; itm->tx_status_index = index; } /* Adjuste grant for query */ if (dfc_qmap && is_query) { Loading Loading @@ -1120,7 +1128,7 @@ void dfc_do_burst_flow_control(struct dfc_qmi_data *dfc, else dfc_update_fc_map( dev, qos, ack_req, ancillary, flow_status, is_query); is_query, dfc->index); spin_unlock_bh(&qos->qos_lock); } Loading @@ -1131,7 +1139,8 @@ void dfc_do_burst_flow_control(struct dfc_qmi_data *dfc, static void dfc_update_tx_link_status(struct net_device *dev, struct qos_info *qos, u8 tx_status, struct dfc_bearer_info_type_v01 *binfo) struct dfc_bearer_info_type_v01 *binfo, int index) { struct rmnet_bearer_map *itm = NULL; Loading @@ -1139,6 +1148,8 @@ static void dfc_update_tx_link_status(struct net_device *dev, if (!itm) return; itm->tx_status_index = index; /* If no change in tx status, ignore */ if (itm->tx_off == !tx_status) return; Loading Loading @@ -1190,7 +1201,7 @@ void dfc_handle_tx_link_status_ind(struct dfc_qmi_data *dfc, spin_lock_bh(&qos->qos_lock); dfc_update_tx_link_status( dev, qos, ind->tx_status, bearer_info); dev, qos, ind->tx_status, bearer_info, dfc->index); spin_unlock_bh(&qos->qos_lock); } Loading
drivers/soc/qcom/qmi_rmnet_i.h +1 −0 Original line number Diff line number Diff line Loading @@ -51,6 +51,7 @@ struct rmnet_bearer_map { bool tcp_bidir; bool rat_switch; bool tx_off; int tx_status_index; u32 ack_txid; u32 mq_idx; u32 ack_mq_idx; Loading