Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions arch/arm64/configs/rockchip_linux_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -817,6 +817,7 @@ CONFIG_DVB_USB=m
CONFIG_DVB_USB_A800=m
CONFIG_DVB_USB_DIBUSB_MB=m
CONFIG_DVB_USB_DIBUSB_MC=m
CONFIG_DVB_USB_DIB0700=m
CONFIG_DVB_USB_UMT_010=m
CONFIG_DVB_USB_CXUSB=m
CONFIG_DVB_USB_M920X=m
Expand Down
146 changes: 73 additions & 73 deletions drivers/media/usb/dvb-usb/dib0700_devices.c
Original file line number Diff line number Diff line change
Expand Up @@ -519,7 +519,7 @@ static u8 rc_request[] = { REQUEST_POLL_RC, 0 };
static int dib0700_rc_query_old_firmware(struct dvb_usb_device *d)
{
u8 key[4];
enum rc_type protocol;
enum rc_proto protocol;
u32 scancode;
u8 toggle;
int i;
Expand Down Expand Up @@ -548,22 +548,22 @@ static int dib0700_rc_query_old_firmware(struct dvb_usb_device *d)
dib0700_rc_setup(d, NULL); /* reset ir sensor data to prevent false events */

switch (d->props.rc.core.protocol) {
case RC_BIT_NEC:
case RC_PROTO_BIT_NEC:
/* NEC protocol sends repeat code as 0 0 0 FF */
if ((key[3-2] == 0x00) && (key[3-3] == 0x00) &&
(key[3] == 0xff)) {
rc_repeat(d->rc_dev);
return 0;
}

protocol = RC_TYPE_NEC;
protocol = RC_PROTO_NEC;
scancode = RC_SCANCODE_NEC(key[3-2], key[3-3]);
toggle = 0;
break;

default:
/* RC-5 protocol changes toggle bit on new keypress */
protocol = RC_TYPE_RC5;
protocol = RC_PROTO_RC5;
scancode = RC_SCANCODE_RC5(key[3-2], key[3-3]);
toggle = key[3-1];
break;
Expand Down Expand Up @@ -3887,9 +3887,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_interval = DEFAULT_RC_INTERVAL,
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -3927,9 +3927,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_interval = DEFAULT_RC_INTERVAL,
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -3992,9 +3992,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_interval = DEFAULT_RC_INTERVAL,
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4037,9 +4037,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4118,9 +4118,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4163,9 +4163,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4220,9 +4220,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4286,9 +4286,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4335,9 +4335,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_NEC_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4404,9 +4404,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4440,9 +4440,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4516,9 +4516,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4560,9 +4560,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_NEC_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4609,9 +4609,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4646,9 +4646,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4683,9 +4683,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4720,9 +4720,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4757,9 +4757,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4794,9 +4794,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4845,9 +4845,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4880,9 +4880,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4917,9 +4917,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
}, { DIB0700_DEFAULT_DEVICE_PROPERTIES,
Expand Down Expand Up @@ -4955,9 +4955,9 @@ struct dvb_usb_device_properties dib0700_devices[] = {
.rc_codes = RC_MAP_DIB0700_RC5_TABLE,
.module_name = "dib0700",
.rc_query = dib0700_rc_query_old_firmware,
.allowed_protos = RC_BIT_RC5 |
RC_BIT_RC6_MCE |
RC_BIT_NEC,
.allowed_protos = RC_PROTO_BIT_RC5 |
RC_PROTO_BIT_RC6_MCE |
RC_PROTO_BIT_NEC,
.change_protocol = dib0700_change_protocol,
},
},
Expand Down