mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-13 08:07:32 -04:00
Merge "neuron: block_client: Wait for channel to init"
This commit is contained in:
commit
4bf21f22ca
1 changed files with 8 additions and 3 deletions
|
|
@ -178,8 +178,8 @@ static int protocol_block_client_thread(void *data)
|
|||
skb_req = NULL;
|
||||
|
||||
/* Wait for the channels to start */
|
||||
wakeup_mask = 0;
|
||||
while (!kthread_should_stop()) {
|
||||
wakeup_mask = 0;
|
||||
if (!channel_dev->max_size || !channel_dev->queue_length)
|
||||
wakeup_mask |= CHANNEL_BIT(C_IN);
|
||||
|
||||
|
|
@ -190,8 +190,13 @@ static int protocol_block_client_thread(void *data)
|
|||
break;
|
||||
|
||||
wait_event_killable(kdata->wait_q,
|
||||
kthread_should_stop() ||
|
||||
(kdata->wakeups & wakeup_mask));
|
||||
(kdata->wakeups &&
|
||||
channel_dev->max_size &&
|
||||
channel_dev->queue_length &&
|
||||
channel_dev_r->max_size &&
|
||||
channel_dev_r->queue_length) ||
|
||||
kthread_should_stop());
|
||||
wakeup_mask = 0;
|
||||
}
|
||||
if (kthread_should_stop())
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Reference in a new issue