net: ipa: kill ipa_power_modem_queue_active()
All ipa_power_modem_queue_active() does now is call netif_wake_queue(). Just call netif_wake_queue() in the two places it's needed, and get rid of ipa_power_modem_queue_active(). Signed-off-by: Alex Elder <elder@linaro.org> Link: https://lore.kernel.org/r/20240130192305.250915-7-elder@linaro.org Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
30cdaea236
commit
2acf5fc8da
@ -163,7 +163,7 @@ ipa_start_xmit(struct sk_buff *skb, struct net_device *netdev)
|
||||
if (ret < 1) {
|
||||
/* If a resume won't happen, just drop the packet */
|
||||
if (ret < 0 && ret != -EINPROGRESS) {
|
||||
ipa_power_modem_queue_active(ipa);
|
||||
netif_wake_queue(netdev);
|
||||
pm_runtime_put_noidle(dev);
|
||||
goto err_drop_skb;
|
||||
}
|
||||
@ -173,7 +173,7 @@ ipa_start_xmit(struct sk_buff *skb, struct net_device *netdev)
|
||||
return NETDEV_TX_BUSY;
|
||||
}
|
||||
|
||||
ipa_power_modem_queue_active(ipa);
|
||||
netif_wake_queue(netdev);
|
||||
|
||||
ret = ipa_endpoint_skb_tx(endpoint, skb);
|
||||
|
||||
|
@ -227,30 +227,19 @@ void ipa_power_suspend_handler(struct ipa *ipa, enum ipa_irq_id irq_id)
|
||||
ipa_interrupt_suspend_clear_all(ipa->interrupt);
|
||||
}
|
||||
|
||||
/* The next two functions are used when stopping and starting the modem
|
||||
* network device transmit queue.
|
||||
*
|
||||
* Transmit can run concurrent with power resume. When transmitting,
|
||||
/* Transmit can run concurrent with power resume. When transmitting,
|
||||
* we disable further transmits until we can determine whether power
|
||||
* is ACTIVE. If it is, future transmits are re-enabled and the buffer
|
||||
* gets sent (or dropped). If power is not ACTIVE, it will eventually
|
||||
* be, and transmits stay disabled until after it is.
|
||||
*
|
||||
* The first function starts the transmit queue and is used in the power
|
||||
* resume path after power has become ACTIVE. The second function also
|
||||
* enables transmits again, and is used by ipa_start_xmit() once it
|
||||
* knows power is active.
|
||||
* be, and transmits stay disabled until after it is. This function
|
||||
* starts the transmit queue and is used in the power resume path after
|
||||
* power has become ACTIVE.
|
||||
*/
|
||||
void ipa_power_modem_queue_wake(struct ipa *ipa)
|
||||
{
|
||||
netif_wake_queue(ipa->modem_netdev);
|
||||
}
|
||||
|
||||
void ipa_power_modem_queue_active(struct ipa *ipa)
|
||||
{
|
||||
netif_wake_queue(ipa->modem_netdev);
|
||||
}
|
||||
|
||||
static int ipa_power_retention_init(struct ipa_power *power)
|
||||
{
|
||||
struct qmp *qmp = qmp_get(power->dev);
|
||||
|
@ -29,12 +29,6 @@ u32 ipa_core_clock_rate(struct ipa *ipa);
|
||||
*/
|
||||
void ipa_power_modem_queue_wake(struct ipa *ipa);
|
||||
|
||||
/**
|
||||
* ipa_power_modem_queue_active() - Report modem netdev TX queue active
|
||||
* @ipa: IPA pointer
|
||||
*/
|
||||
void ipa_power_modem_queue_active(struct ipa *ipa);
|
||||
|
||||
/**
|
||||
* ipa_power_retention() - Control register retention on power collapse
|
||||
* @ipa: IPA pointer
|
||||
|
Loading…
x
Reference in New Issue
Block a user