From 40381cb02fb7fc0b46c55e3a71325b5d930580fa Mon Sep 17 00:00:00 2001 From: Mike Isely Date: Tue, 22 Apr 2008 14:45:42 -0300 Subject: V4L/DVB (7313): pvrusb2: Make LED control into a device-specific attribute The pvrusb2 driver has used hardcoded logic to control the LED on the device. However this is really Hauppauge-specific behavior. This change defines a new device attribute for LED control and sets things up appropriately for Hauppauge devices. Signed-off-by: Mike Isely Signed-off-by: Mauro Carvalho Chehab --- drivers/media/video/pvrusb2/pvrusb2-devattr.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'drivers/media/video/pvrusb2/pvrusb2-devattr.h') diff --git a/drivers/media/video/pvrusb2/pvrusb2-devattr.h b/drivers/media/video/pvrusb2/pvrusb2-devattr.h index 4e4798d6139f..ce4004978a92 100644 --- a/drivers/media/video/pvrusb2/pvrusb2-devattr.h +++ b/drivers/media/video/pvrusb2/pvrusb2-devattr.h @@ -43,6 +43,9 @@ struct pvr2_string_table { #define PVR2_DIGITAL_SCHEME_HAUPPAUGE 1 #define PVR2_DIGITAL_SCHEME_ONAIR 2 +#define PVR2_LED_SCHEME_NONE 0 +#define PVR2_LED_SCHEME_HAUPPAUGE 1 + /* This describes a particular hardware type (except for the USB device ID which must live in a separate structure due to environmental constraints). See the top of pvrusb2-hdw.c for where this is @@ -70,6 +73,11 @@ struct pvr2_device_desc { drivers (search for things which touch this field). */ unsigned int signal_routing_scheme; + /* Indicates scheme for controlling device's LED (if any). The + driver will turn on the LED when streaming is underway. This + contains one of PVR2_LED_SCHEME_XXX. */ + unsigned int led_scheme; + /* Control scheme to use if there is a digital tuner. This contains one of PVR2_DIGITAL_SCHEME_XXX. This is an arbitrary integer scheme id; its meaning is contained entirely within the -- cgit v1.2.3