sim/hcitty: remove the poll lock to avoid invalid wait

it it unnecessary to protect pollnotify() since the wakeup
source comes from idle thread

Signed-off-by: chao.an <anchao@xiaomi.com>
This commit is contained in:
chao.an 2021-01-19 17:27:15 +08:00 committed by Xiang Xiao
parent 76cc5c36e4
commit a32856f965
1 changed files with 0 additions and 8 deletions

View File

@ -126,15 +126,8 @@ static inline void bthcitty_post(FAR sem_t *sem)
static void bthcitty_pollnotify(FAR struct bthcitty_s *dev,
pollevent_t eventset)
{
int ret;
int i;
ret = nxsem_wait_uninterruptible(&dev->fdslock);
if (ret < 0)
{
return;
}
for (i = 0; i < CONFIG_HCI_NPOLLWAITERS; i++)
{
FAR struct pollfd *fds = dev->fds[i];
@ -150,7 +143,6 @@ static void bthcitty_pollnotify(FAR struct bthcitty_s *dev,
}
}
nxsem_post(&dev->fdslock);
bthcitty_post(&dev->recvsem);
}