summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/tuner-xc2028.h
diff options
context:
space:
mode:
authorMichael Krufky <mkrufky@linuxtv.org>2007-12-21 14:12:09 -0500
committerMichael Krufky <mkrufky@linuxtv.org>2007-12-21 14:12:09 -0500
commit4bf4fe7960ba0df383a5a6346ebeb9c04817a7ba (patch)
tree6ab0ce2a99174f9d43e1eb3fe82f459235919857 /linux/drivers/media/video/tuner-xc2028.h
parent69927456203b70ac223f763be826cd6f3facde3f (diff)
downloadmediapointer-dvb-s2-4bf4fe7960ba0df383a5a6346ebeb9c04817a7ba.tar.gz
mediapointer-dvb-s2-4bf4fe7960ba0df383a5a6346ebeb9c04817a7ba.tar.bz2
tuner-xc2028: fix xc2028_attach function
From: Michael Krufky <mkrufky@linuxtv.org> xc2028_attach was returning an integer when disabled from the build, where it should instead be returning NULL. Declare xc2028_attach as type dvb_frontend * instead of void *. The prototype declaration must be marked as extern in the header. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Diffstat (limited to 'linux/drivers/media/video/tuner-xc2028.h')
-rw-r--r--linux/drivers/media/video/tuner-xc2028.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/linux/drivers/media/video/tuner-xc2028.h b/linux/drivers/media/video/tuner-xc2028.h
index 7462629b9..3eb842037 100644
--- a/linux/drivers/media/video/tuner-xc2028.h
+++ b/linux/drivers/media/video/tuner-xc2028.h
@@ -48,14 +48,15 @@ struct xc2028_config {
#define XC2028_RESET_CLK 1
#if defined(CONFIG_TUNER_XC2028) || (defined(CONFIG_TUNER_XC2028_MODULE) && defined(MODULE))
-void *xc2028_attach(struct dvb_frontend *fe, struct xc2028_config *cfg);
+extern struct dvb_frontend *xc2028_attach(struct dvb_frontend *fe,
+ struct xc2028_config *cfg);
#else
-void *xc2028_attach(struct dvb_frontend *fe,
- struct xc2028_config *cfg)
+static inline struct dvb_frontend *xc2028_attach(struct dvb_frontend *fe,
+ struct xc2028_config *cfg)
{
printk(KERN_INFO "%s: not probed - driver disabled by Kconfig\n",
__FUNCTION__);
- return -EINVAL;
+ return NULL;
}
#endif