aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Wahren <stefan.wahren@i2se.com>2018-07-18 08:31:44 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-08-24 13:27:00 +0200
commite77b1523b93cbc8863cfe656ca0c9e82f7ba43c9 (patch)
treea3703d9d55cfd50a6780155141bb467932e2fe1b
parent8621e69878ba41ed24987a487eaf01a6505223c6 (diff)
downloadlinux-e77b1523b93cbc8863cfe656ca0c9e82f7ba43c9.tar.gz
net: qca_spi: Make sure the QCA7000 reset is triggered
[ Upstream commit 711c62dfa6bdb4326ca6c587f295ea5c4f7269de ] In case the SPI thread is not running, a simple reset of sync state won't fix the transmit timeout. We also need to wake up the kernel thread. Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com> Fixes: ed7d42e24eff ("net: qca_spi: fix transmit queue timeout handling") Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <alexander.levin@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/net/ethernet/qualcomm/qca_spi.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/qualcomm/qca_spi.c b/drivers/net/ethernet/qualcomm/qca_spi.c
index 7b903af19e5735..25f673059c655a 100644
--- a/drivers/net/ethernet/qualcomm/qca_spi.c
+++ b/drivers/net/ethernet/qualcomm/qca_spi.c
@@ -739,6 +739,9 @@ qcaspi_netdev_tx_timeout(struct net_device *dev)
qca->net_dev->stats.tx_errors++;
/* Trigger tx queue flush and QCA7000 reset */
qca->sync = QCASPI_SYNC_UNKNOWN;
+
+ if (qca->spi_thread)
+ wake_up_process(qca->spi_thread);
}
static int