]> 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)
commit96d4943da3c2bad54f89814a7f519cdff41d6d2d
treef2821686b9360c61cf1d529559b2d2704910809d
parent3a7b3ea55c942fe6585cbbc720bf0917c1f56291
[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