⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tuner-types.c

📁 trident tm5600的linux驱动
💻 C
📖 第 1 页 / 共 4 页
字号:
/* * * i2c tv tuner chip device type database. * */#include <linux/i2c.h>#include <media/tuner.h>#include <media/tuner-types.h>#include "compat.h"/* ---------------------------------------------------------------------- *//* *	The floats in the tuner struct are computed at compile time *	by gcc and cast back to integers. Thus we don't violate the *	"no float in kernel" rule. * *	A tuner_range may be referenced by multiple tuner_params structs. *	There are many duplicates in here. Reusing tuner_range structs, *	rather than defining new ones for each tuner, will cut down on *	memory usage, and is preferred when possible. * *	Each tuner_params array may contain one or more elements, one *	for each video standard. * *	FIXME: tuner_params struct contains an element, tda988x. We must *	set this for all tuners that contain a tda988x chip, and then we *	can remove this setting from the various card structs. * *	FIXME: Right now, all tuners are using the first tuner_params[] *	array element for analog mode. In the future, we will be merging *	similar tuner definitions together, such that each tuner definition *	will have a tuner_params struct for each available video standard. *	At that point, the tuner_params[] array element will be chosen *	based on the video standard in use. *//* The following was taken from dvb-pll.c: *//* Set AGC TOP value to 103 dBuV: *	0x80 = Control Byte *	0x40 = 250 uA charge pump (irrelevant) *	0x18 = Aux Byte to follow *	0x06 = 64.5 kHz divider (irrelevant) *	0x01 = Disable Vt (aka sleep) * *	0x00 = AGC Time constant 2s Iagc = 300 nA (vs 0x80 = 9 nA) *	0x50 = AGC Take over point = 103 dBuV */static u8 tua603x_agc103[] = { 2, 0x80|0x40|0x18|0x06|0x01, 0x00|0x50 };/*	0x04 = 166.67 kHz divider * *	0x80 = AGC Time constant 50ms Iagc = 9 uA *	0x20 = AGC Take over point = 112 dBuV */static u8 tua603x_agc112[] = { 2, 0x80|0x40|0x18|0x04|0x01, 0x80|0x20 };/* 0-9 *//* ------------ TUNER_TEMIC_PAL - TEMIC PAL ------------ */static struct tuner_range tuner_temic_pal_ranges[] = {	{ 16 * 140.25 /*MHz*/, 0x8e, 0x02, },	{ 16 * 463.25 /*MHz*/, 0x8e, 0x04, },	{ 16 * 999.99        , 0x8e, 0x01, },};static struct tuner_params tuner_temic_pal_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_temic_pal_ranges,		.count  = ARRAY_SIZE(tuner_temic_pal_ranges),	},};/* ------------ TUNER_PHILIPS_PAL_I - Philips PAL_I ------------ */static struct tuner_range tuner_philips_pal_i_ranges[] = {	{ 16 * 140.25 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 463.25 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_philips_pal_i_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_philips_pal_i_ranges,		.count  = ARRAY_SIZE(tuner_philips_pal_i_ranges),	},};/* ------------ TUNER_PHILIPS_NTSC - Philips NTSC ------------ */static struct tuner_range tuner_philips_ntsc_ranges[] = {	{ 16 * 157.25 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 451.25 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_philips_ntsc_params[] = {	{		.type   = TUNER_PARAM_TYPE_NTSC,		.ranges = tuner_philips_ntsc_ranges,		.count  = ARRAY_SIZE(tuner_philips_ntsc_ranges),		.cb_first_if_lower_freq = 1,	},};/* ------------ TUNER_PHILIPS_SECAM - Philips SECAM ------------ */static struct tuner_range tuner_philips_secam_ranges[] = {	{ 16 * 168.25 /*MHz*/, 0x8e, 0xa7, },	{ 16 * 447.25 /*MHz*/, 0x8e, 0x97, },	{ 16 * 999.99        , 0x8e, 0x37, },};static struct tuner_params tuner_philips_secam_params[] = {	{		.type   = TUNER_PARAM_TYPE_SECAM,		.ranges = tuner_philips_secam_ranges,		.count  = ARRAY_SIZE(tuner_philips_secam_ranges),		.cb_first_if_lower_freq = 1,	},};/* ------------ TUNER_PHILIPS_PAL - Philips PAL ------------ */static struct tuner_range tuner_philips_pal_ranges[] = {	{ 16 * 168.25 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 447.25 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_philips_pal_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_philips_pal_ranges,		.count  = ARRAY_SIZE(tuner_philips_pal_ranges),		.cb_first_if_lower_freq = 1,	},};/* ------------ TUNER_TEMIC_NTSC - TEMIC NTSC ------------ */static struct tuner_range tuner_temic_ntsc_ranges[] = {	{ 16 * 157.25 /*MHz*/, 0x8e, 0x02, },	{ 16 * 463.25 /*MHz*/, 0x8e, 0x04, },	{ 16 * 999.99        , 0x8e, 0x01, },};static struct tuner_params tuner_temic_ntsc_params[] = {	{		.type   = TUNER_PARAM_TYPE_NTSC,		.ranges = tuner_temic_ntsc_ranges,		.count  = ARRAY_SIZE(tuner_temic_ntsc_ranges),	},};/* ------------ TUNER_TEMIC_PAL_I - TEMIC PAL_I ------------ */static struct tuner_range tuner_temic_pal_i_ranges[] = {	{ 16 * 170.00 /*MHz*/, 0x8e, 0x02, },	{ 16 * 450.00 /*MHz*/, 0x8e, 0x04, },	{ 16 * 999.99        , 0x8e, 0x01, },};static struct tuner_params tuner_temic_pal_i_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_temic_pal_i_ranges,		.count  = ARRAY_SIZE(tuner_temic_pal_i_ranges),	},};/* ------------ TUNER_TEMIC_4036FY5_NTSC - TEMIC NTSC ------------ */static struct tuner_range tuner_temic_4036fy5_ntsc_ranges[] = {	{ 16 * 157.25 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 463.25 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_temic_4036fy5_ntsc_params[] = {	{		.type   = TUNER_PARAM_TYPE_NTSC,		.ranges = tuner_temic_4036fy5_ntsc_ranges,		.count  = ARRAY_SIZE(tuner_temic_4036fy5_ntsc_ranges),	},};/* ------------ TUNER_ALPS_TSBH1_NTSC - TEMIC NTSC ------------ */static struct tuner_range tuner_alps_tsb_1_ranges[] = {	{ 16 * 137.25 /*MHz*/, 0x8e, 0x01, },	{ 16 * 385.25 /*MHz*/, 0x8e, 0x02, },	{ 16 * 999.99        , 0x8e, 0x08, },};static struct tuner_params tuner_alps_tsbh1_ntsc_params[] = {	{		.type   = TUNER_PARAM_TYPE_NTSC,		.ranges = tuner_alps_tsb_1_ranges,		.count  = ARRAY_SIZE(tuner_alps_tsb_1_ranges),	},};/* 10-19 *//* ------------ TUNER_ALPS_TSBE1_PAL - TEMIC PAL ------------ */static struct tuner_params tuner_alps_tsb_1_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_alps_tsb_1_ranges,		.count  = ARRAY_SIZE(tuner_alps_tsb_1_ranges),	},};/* ------------ TUNER_ALPS_TSBB5_PAL_I - Alps PAL_I ------------ */static struct tuner_range tuner_alps_tsb_5_pal_ranges[] = {	{ 16 * 133.25 /*MHz*/, 0x8e, 0x01, },	{ 16 * 351.25 /*MHz*/, 0x8e, 0x02, },	{ 16 * 999.99        , 0x8e, 0x08, },};static struct tuner_params tuner_alps_tsbb5_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_alps_tsb_5_pal_ranges,		.count  = ARRAY_SIZE(tuner_alps_tsb_5_pal_ranges),	},};/* ------------ TUNER_ALPS_TSBE5_PAL - Alps PAL ------------ */static struct tuner_params tuner_alps_tsbe5_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_alps_tsb_5_pal_ranges,		.count  = ARRAY_SIZE(tuner_alps_tsb_5_pal_ranges),	},};/* ------------ TUNER_ALPS_TSBC5_PAL - Alps PAL ------------ */static struct tuner_params tuner_alps_tsbc5_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_alps_tsb_5_pal_ranges,		.count  = ARRAY_SIZE(tuner_alps_tsb_5_pal_ranges),	},};/* ------------ TUNER_TEMIC_4006FH5_PAL - TEMIC PAL ------------ */static struct tuner_range tuner_lg_pal_ranges[] = {	{ 16 * 170.00 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 450.00 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_temic_4006fh5_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_lg_pal_ranges,		.count  = ARRAY_SIZE(tuner_lg_pal_ranges),	},};/* ------------ TUNER_ALPS_TSHC6_NTSC - Alps NTSC ------------ */static struct tuner_range tuner_alps_tshc6_ntsc_ranges[] = {	{ 16 * 137.25 /*MHz*/, 0x8e, 0x14, },	{ 16 * 385.25 /*MHz*/, 0x8e, 0x12, },	{ 16 * 999.99        , 0x8e, 0x11, },};static struct tuner_params tuner_alps_tshc6_params[] = {	{		.type   = TUNER_PARAM_TYPE_NTSC,		.ranges = tuner_alps_tshc6_ntsc_ranges,		.count  = ARRAY_SIZE(tuner_alps_tshc6_ntsc_ranges),	},};/* ------------ TUNER_TEMIC_PAL_DK - TEMIC PAL ------------ */static struct tuner_range tuner_temic_pal_dk_ranges[] = {	{ 16 * 168.25 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 456.25 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_temic_pal_dk_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_temic_pal_dk_ranges,		.count  = ARRAY_SIZE(tuner_temic_pal_dk_ranges),	},};/* ------------ TUNER_PHILIPS_NTSC_M - Philips NTSC ------------ */static struct tuner_range tuner_philips_ntsc_m_ranges[] = {	{ 16 * 160.00 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 454.00 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_philips_ntsc_m_params[] = {	{		.type   = TUNER_PARAM_TYPE_NTSC,		.ranges = tuner_philips_ntsc_m_ranges,		.count  = ARRAY_SIZE(tuner_philips_ntsc_m_ranges),	},};/* ------------ TUNER_TEMIC_4066FY5_PAL_I - TEMIC PAL_I ------------ */static struct tuner_range tuner_temic_40x6f_5_pal_ranges[] = {	{ 16 * 169.00 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 454.00 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_temic_4066fy5_pal_i_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_temic_40x6f_5_pal_ranges,		.count  = ARRAY_SIZE(tuner_temic_40x6f_5_pal_ranges),	},};/* ------------ TUNER_TEMIC_4006FN5_MULTI_PAL - TEMIC PAL ------------ */static struct tuner_params tuner_temic_4006fn5_multi_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_temic_40x6f_5_pal_ranges,		.count  = ARRAY_SIZE(tuner_temic_40x6f_5_pal_ranges),	},};/* 20-29 *//* ------------ TUNER_TEMIC_4009FR5_PAL - TEMIC PAL ------------ */static struct tuner_range tuner_temic_4009f_5_pal_ranges[] = {	{ 16 * 141.00 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 464.00 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_temic_4009f_5_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_temic_4009f_5_pal_ranges,		.count  = ARRAY_SIZE(tuner_temic_4009f_5_pal_ranges),	},};/* ------------ TUNER_TEMIC_4039FR5_NTSC - TEMIC NTSC ------------ */static struct tuner_range tuner_temic_4x3x_f_5_ntsc_ranges[] = {	{ 16 * 158.00 /*MHz*/, 0x8e, 0xa0, },	{ 16 * 453.00 /*MHz*/, 0x8e, 0x90, },	{ 16 * 999.99        , 0x8e, 0x30, },};static struct tuner_params tuner_temic_4039fr5_params[] = {	{		.type   = TUNER_PARAM_TYPE_NTSC,		.ranges = tuner_temic_4x3x_f_5_ntsc_ranges,		.count  = ARRAY_SIZE(tuner_temic_4x3x_f_5_ntsc_ranges),	},};/* ------------ TUNER_TEMIC_4046FM5 - TEMIC PAL ------------ */static struct tuner_params tuner_temic_4046fm5_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_temic_40x6f_5_pal_ranges,		.count  = ARRAY_SIZE(tuner_temic_40x6f_5_pal_ranges),	},};/* ------------ TUNER_PHILIPS_PAL_DK - Philips PAL ------------ */static struct tuner_params tuner_philips_pal_dk_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_lg_pal_ranges,		.count  = ARRAY_SIZE(tuner_lg_pal_ranges),	},};/* ------------ TUNER_PHILIPS_FQ1216ME - Philips PAL ------------ */static struct tuner_params tuner_philips_fq1216me_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_lg_pal_ranges,		.count  = ARRAY_SIZE(tuner_lg_pal_ranges),		.has_tda9887 = 1,		.port1_active = 1,		.port2_active = 1,		.port2_invert_for_secam_lc = 1,	},};/* ------------ TUNER_LG_PAL_I_FM - LGINNOTEK PAL_I ------------ */static struct tuner_params tuner_lg_pal_i_fm_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_lg_pal_ranges,		.count  = ARRAY_SIZE(tuner_lg_pal_ranges),	},};/* ------------ TUNER_LG_PAL_I - LGINNOTEK PAL_I ------------ */static struct tuner_params tuner_lg_pal_i_params[] = {	{		.type   = TUNER_PARAM_TYPE_PAL,		.ranges = tuner_lg_pal_ranges,

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -