[PATCH 3/3] af903x: add new USB VID/PID IDs and move definitions to dvb-usb-ids.h

Signed-off-by: Gianluca Gennari <gennarone@gmail.com>
---
 drivers/media/dvb/dvb-usb/af903x-devices.c |   72 +++++++++++++++++++++++-----
 drivers/media/dvb/dvb-usb/dvb-usb-ids.h    |   16 ++++++
 2 files changed, 76 insertions(+), 12 deletions(-)

diff --git a/drivers/media/dvb/dvb-usb/af903x-devices.c b/drivers/media/dvb/dvb-usb/af903x-devices.c
index 21ece97..06e96f4 100644
--- a/drivers/media/dvb/dvb-usb/af903x-devices.c
+++ b/drivers/media/dvb/dvb-usb/af903x-devices.c
@@ -1216,18 +1216,50 @@ enum af903x_table_entry {
 	AFATECH_AF9035,
 	TERRATEC_T6,		/* Terratec T6 */
 	TERRATEC_T5_REV2,	/* Terratec T5 Rev.2 */
+	AVERMEDIA_TWINSTAR,	/* Avermedia TwinStar */
 	AVERMEDIA_A867,		/* Avermedia HD Volar / A867 */
+	AVERMEDIA_A333,		/* Avermedia A333 */
+	AVERMEDIA_B867,
+	AVERMEDIA_1867,
+	AVERMEDIA_0337,
+	AVERMEDIA_0867,
+	AVERMEDIA_F337,
+	AVERMEDIA_3867,
 };
 
 struct usb_device_id af903x_usb_table[] = {
-	[AFATECH_1000] = { USB_DEVICE(0x15A4,0x1000) },
-	[AFATECH_1001] = { USB_DEVICE(0x15A4,0x1001) },
-	[AFATECH_1002] = { USB_DEVICE(0x15A4,0x1002) },
-	[AFATECH_1003] = { USB_DEVICE(0x15A4,0x1003) },
-	[AFATECH_AF9035] = { USB_DEVICE(0x15A4,0x9035) },
-	[TERRATEC_T6] = { USB_DEVICE(0x0ccd,0x10b3) },
-	[TERRATEC_T5_REV2] = { USB_DEVICE(0x0ccd,0x10b7) },
-	[AVERMEDIA_A867] = { USB_DEVICE(0x07ca,0x1867) },
+	[AFATECH_1000] = {USB_DEVICE(USB_VID_AFATECH,
+				USB_PID_AFATECH_AF9035_1000)},
+	[AFATECH_1001] = {USB_DEVICE(USB_VID_AFATECH,
+				USB_PID_AFATECH_AF9035_1001)},
+	[AFATECH_1002] = {USB_DEVICE(USB_VID_AFATECH,
+				USB_PID_AFATECH_AF9035_1002)},
+	[AFATECH_1003] = {USB_DEVICE(USB_VID_AFATECH,
+				USB_PID_AFATECH_AF9035_1003)},
+	[AFATECH_AF9035] = {USB_DEVICE(USB_VID_AFATECH,
+				USB_PID_AFATECH_AF9035_9035)},
+	[TERRATEC_T6] = {USB_DEVICE(USB_VID_TERRATEC,
+				USB_PID_TERRATEC_T6)},
+	[TERRATEC_T5_REV2] = {USB_DEVICE(USB_VID_TERRATEC,
+				USB_PID_TERRATEC_T5_REV2)},
+	[AVERMEDIA_TWINSTAR] = {USB_DEVICE(USB_VID_AVERMEDIA,
+				USB_PID_AVERMEDIA_A825)},
+	[AVERMEDIA_A333] = {USB_DEVICE(USB_VID_AVERMEDIA,
+				USB_PID_AVERMEDIA_A333)},
+	[AVERMEDIA_B867] = {USB_DEVICE(USB_VID_AVERMEDIA,
+				USB_PID_AVERMEDIA_B867)},
+	[AVERMEDIA_1867] = {USB_DEVICE(USB_VID_AVERMEDIA,
+				USB_PID_AVERMEDIA_1867)},
+	[AVERMEDIA_0337] = {USB_DEVICE(USB_VID_AVERMEDIA,
+				USB_PID_AVERMEDIA_0337)},
+	[AVERMEDIA_A867] = {USB_DEVICE(USB_VID_AVERMEDIA,
+				USB_PID_AVERMEDIA_A867)},
+	[AVERMEDIA_0867] = {USB_DEVICE(USB_VID_AVERMEDIA,
+				USB_PID_AVERMEDIA_0867)},
+	[AVERMEDIA_F337] = {USB_DEVICE(USB_VID_AVERMEDIA,
+				USB_PID_AVERMEDIA_F337)},
+	[AVERMEDIA_3867] = {USB_DEVICE(USB_VID_AVERMEDIA,
+				USB_PID_AVERMEDIA_3867)},
 	{ 0},		/* Terminating entry */
 };
 MODULE_DEVICE_TABLE(usb, af903x_usb_table);
@@ -1310,9 +1342,9 @@ struct dvb_usb_device_properties af903x_properties[] = {
 			.rc_codes	= NULL, /* will be set in
 						   af903x_identify_state */
 		},
-		.num_device_descs =4,
+		.num_device_descs = 6,
 		.devices =  {
-			{   	"ITEtech USB2.0 DVB-T Recevier",
+			{   	"ITEtech AF903x USB2.0 DVB-T Receiver",
 				{ &af903x_usb_table[AFATECH_1000],
 				  &af903x_usb_table[AFATECH_1001],
 				  &af903x_usb_table[AFATECH_1002], 
@@ -1329,8 +1361,24 @@ struct dvb_usb_device_properties af903x_properties[] = {
 				{ NULL },
 			},
 			{
-				"AVerMedia A867 DVB-T Recevier",
-				{ &af903x_usb_table[AVERMEDIA_A867], NULL},
+				"Avermedia TwinStar",
+				{ &af903x_usb_table[AVERMEDIA_TWINSTAR], NULL},
+				{ NULL },
+			},
+			{
+				"AVerMedia A333 DVB-T Receiver",
+				{ &af903x_usb_table[AVERMEDIA_A333],
+				  &af903x_usb_table[AVERMEDIA_B867], NULL},
+                            	{ NULL },
+			},
+			{
+				"AVerMedia A867 DVB-T Receiver",
+				{ &af903x_usb_table[AVERMEDIA_1867],
+				  &af903x_usb_table[AVERMEDIA_0337],
+				  &af903x_usb_table[AVERMEDIA_A867],
+				  &af903x_usb_table[AVERMEDIA_0867],
+				  &af903x_usb_table[AVERMEDIA_F337],
+				  &af903x_usb_table[AVERMEDIA_3867], NULL},
                             	{ NULL },
 			},
 			{NULL},
diff --git a/drivers/media/dvb/dvb-usb/dvb-usb-ids.h b/drivers/media/dvb/dvb-usb/dvb-usb-ids.h
index 9c3dae1..6ed83fd 100644
--- a/drivers/media/dvb/dvb-usb/dvb-usb-ids.h
+++ b/drivers/media/dvb/dvb-usb/dvb-usb-ids.h
@@ -75,6 +75,11 @@
 #define USB_PID_AFATECH_AF9005				0x9020
 #define USB_PID_AFATECH_AF9015_9015			0x9015
 #define USB_PID_AFATECH_AF9015_9016			0x9016
+#define USB_PID_AFATECH_AF9035_1000			0x1000
+#define USB_PID_AFATECH_AF9035_1001			0x1001
+#define USB_PID_AFATECH_AF9035_1002			0x1002
+#define USB_PID_AFATECH_AF9035_1003			0x1003
+#define USB_PID_AFATECH_AF9035_9035			0x9035
 #define USB_PID_TREKSTOR_DVBT				0x901b
 #define USB_VID_ALINK_DTU				0xf170
 #define USB_PID_ANSONIC_DVBT_USB			0x6000
@@ -218,6 +223,15 @@
 #define USB_PID_AVERMEDIA_A850T				0x850b
 #define USB_PID_AVERMEDIA_A805				0xa805
 #define USB_PID_AVERMEDIA_A815M				0x815a
+#define USB_PID_AVERMEDIA_A825				0x0825
+#define USB_PID_AVERMEDIA_A333				0xa333
+#define USB_PID_AVERMEDIA_B867				0xb867
+#define USB_PID_AVERMEDIA_1867				0x1867
+#define USB_PID_AVERMEDIA_0337				0x0337
+#define USB_PID_AVERMEDIA_A867				0xa867
+#define USB_PID_AVERMEDIA_0867				0x0867
+#define USB_PID_AVERMEDIA_F337				0xf337
+#define USB_PID_AVERMEDIA_3867				0x3867
 #define USB_PID_TECHNOTREND_CONNECT_S2400               0x3006
 #define USB_PID_TECHNOTREND_CONNECT_CT3650		0x300d
 #define USB_PID_TERRATEC_CINERGY_DT_XS_DIVERSITY	0x005a
@@ -231,6 +245,8 @@
 #define USB_PID_TERRATEC_H7_2				0x10a3
 #define USB_PID_TERRATEC_T3				0x10a0
 #define USB_PID_TERRATEC_T5				0x10a1
+#define USB_PID_TERRATEC_T5_REV2			0x10b7
+#define USB_PID_TERRATEC_T6				0x10b3
 #define USB_PID_PINNACLE_EXPRESSCARD_320CX		0x022e
 #define USB_PID_PINNACLE_PCTV2000E			0x022c
 #define USB_PID_PINNACLE_PCTV_DVB_T_FLASH		0x0228
-- 
1.7.0.4

