]> git.baikalelectronics.ru Git - kernel.git/commit
V4L/DVB: em28xx-input: Don't generate one debug message for every get_key read
authorMauro Carvalho Chehab <mchehab@redhat.com>
Sun, 27 Jun 2010 11:32:11 +0000 (08:32 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Mon, 2 Aug 2010 17:53:30 +0000 (14:53 -0300)
commitf287983753babb9e780e3a77c545c304d2cdf1bf
treea643691f114b3b720a21b4f2eabb9acc4860bbf6
parent21a6232f306ffef3139a3485955eda2dbbad085f
V4L/DVB: em28xx-input: Don't generate one debug message for every get_key read

Instead of generating one printk for every IR read, prints it only when
count is different from the last count.

While here, as this code is called on every 100ms during the runtime
lifetime, do some performance optimization, assuming that, under normal
circumstances, it is unlikely that the driver would get a new key/key
repeat on every poll.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/em28xx/em28xx-input.c