]> git.baikalelectronics.ru Git - kernel.git/commit
[media] dvb: earth-pt1: stop polling data when no one accesses the device
authorAkihiro Tsukada <tskd2@yahoo.co.jp>
Sat, 10 Mar 2012 14:38:13 +0000 (11:38 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Mon, 19 Mar 2012 18:46:36 +0000 (15:46 -0300)
commit3aac4d9a64c3c2a1fb7695f5090fdaddd945567a
treeb9929128874639472b0892e58ab10eddc8db71e0
parent23e2d0ea7932cf0e58b6500f79de532423832792
[media] dvb: earth-pt1: stop polling data when no one accesses the device

The driver started a kthread to poll the DMA buffers soon after probing,
which relsuleted in 1000/sec sleeps and wakeups of the thread doing nothing
useful until someone started feeding.
This patch changes the creation and destruction of the kthread depending on the number of users.

Signed-off-by: Akihiro Tsukada <tskd2@yahoo.co.jp>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/dvb/pt1/pt1.c