Merge tag 'trace-v5.2-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt...
[linux-2.6-block.git] / drivers / media / tuners / tea5761.h
CommitLineData
74ba9207 1/* SPDX-License-Identifier: GPL-2.0-or-later */
7ab10bf7 2/*
7ab10bf7
MK
3*/
4
5#ifndef __TEA5761_H__
6#define __TEA5761_H__
7
8#include <linux/i2c.h>
fada1935 9#include <media/dvb_frontend.h>
7ab10bf7 10
9b174527 11#if IS_REACHABLE(CONFIG_MEDIA_TUNER_TEA5761)
7ab10bf7 12extern int tea5761_autodetection(struct i2c_adapter* i2c_adap, u8 i2c_addr);
ca805d57 13
7ab10bf7
MK
14extern struct dvb_frontend *tea5761_attach(struct dvb_frontend *fe,
15 struct i2c_adapter* i2c_adap,
16 u8 i2c_addr);
ca805d57
MK
17#else
18static inline int tea5761_autodetection(struct i2c_adapter* i2c_adap,
19 u8 i2c_addr)
20{
21 printk(KERN_INFO "%s: not probed - driver disabled by Kconfig\n",
7e28adb2 22 __func__);
ca805d57
MK
23 return -EINVAL;
24}
25
26static inline struct dvb_frontend *tea5761_attach(struct dvb_frontend *fe,
27 struct i2c_adapter* i2c_adap,
28 u8 i2c_addr)
29{
7e28adb2 30 printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
ca805d57
MK
31 return NULL;
32}
33#endif
7ab10bf7
MK
34
35#endif /* __TEA5761_H__ */