From 220be77c6e4302207c34afc78a98b4994f92f6e5 Mon Sep 17 00:00:00 2001 From: Devin Heitmueller Date: Wed, 11 Mar 2009 03:01:01 -0300 Subject: V4L/DVB (11078): au0828: properly handle non-existent analog inputs It is not valid to look for dev->board.input == NULL to detect an undefined analog configuration section, since it is a member of the struct and not a pointer (hence it will *always* be non-NULL). Do the check based on whether the first input is actually a valid input type instead. Thanks to Michael Krufky for providing sample hardware of various configurations to test with. Signed-off-by: Devin Heitmueller Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab --- drivers/media/video/au0828/au0828.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'drivers/media/video/au0828/au0828.h') diff --git a/drivers/media/video/au0828/au0828.h b/drivers/media/video/au0828/au0828.h index d2e54c8..590d15e 100644 --- a/drivers/media/video/au0828/au0828.h +++ b/drivers/media/video/au0828/au0828.h @@ -66,7 +66,8 @@ #define AU0828_MAX_INPUT 4 enum au0828_itype { - AU0828_VMUX_COMPOSITE = 1, + AU0828_VMUX_UNDEFINED = 0, + AU0828_VMUX_COMPOSITE, AU0828_VMUX_SVIDEO, AU0828_VMUX_CABLE, AU0828_VMUX_TELEVISION, -- cgit v1.1