]> git.baikalelectronics.ru Git - kernel.git/commit
[media] b2c2: flexcop: avoid unused function warnings
authorArnd Bergmann <arnd@arndb.de>
Tue, 26 Jan 2016 14:09:58 +0000 (12:09 -0200)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Mon, 1 Feb 2016 15:15:01 +0000 (13:15 -0200)
commit5f199b46fa132bf889ad6aca84643cf8616c2052
treef2821686b9360c61cf1d529559b2d2704910809d
parente19478ceaa1d29fdea538012a99728f55a1990e8
[media] b2c2: flexcop: avoid unused function warnings

The flexcop driver has two functions that are normally used, except
when multiple frontend drivers are disabled:

drivers/media/common/b2c2/flexcop-fe-tuner.c:42:12: warning: 'flexcop_set_voltage' defined but not used [-Wunused-function]
drivers/media/common/b2c2/flexcop-fe-tuner.c:71:12: warning: 'flexcop_sleep' defined but not used [-Wunused-function]

This avoids the build warning by updating the #ifdef for flexcop_set_voltage
to the exact condition under which it is used. For flexcop_sleep, the
condition is rather complex, so I resort to marking it as __maybe_unused,
so the compiler can silently drop it.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
drivers/media/common/b2c2/flexcop-fe-tuner.c