提交 92717c23 编写于 作者: S Stefan Wahren 提交者: David S. Miller

net: qca_spi: Avoid high load if QCA7000 is not available

In case the QCA7000 is not available via SPI (e.g. in reset),
the driver will cause a high load. The reason for this is
that the synchronization is never finished and schedule()
is never called. Since the synchronization is not timing
critical, it's safe to drop this from the scheduling condition.
Signed-off-by: NStefan Wahren <stefan.wahren@i2se.com>
Fixes: 291ab06e ("net: qualcomm: new Ethernet over SPI driver for QCA7000")
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 c938ab4d
...@@ -582,8 +582,7 @@ qcaspi_spi_thread(void *data) ...@@ -582,8 +582,7 @@ qcaspi_spi_thread(void *data)
while (!kthread_should_stop()) { while (!kthread_should_stop()) {
set_current_state(TASK_INTERRUPTIBLE); set_current_state(TASK_INTERRUPTIBLE);
if ((qca->intr_req == qca->intr_svc) && if ((qca->intr_req == qca->intr_svc) &&
(qca->txr.skb[qca->txr.head] == NULL) && !qca->txr.skb[qca->txr.head])
(qca->sync == QCASPI_SYNC_READY))
schedule(); schedule();
set_current_state(TASK_RUNNING); set_current_state(TASK_RUNNING);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册