V4L/DVB (4533): Tda9887: add configuration setting for L standard PLL gating

Add a tuner config parameter for TDA9887, default_pll_gating_18, that
changes the L standard PLL gating value from 36% to 0% (datasheet says
0%, tda9887 code says 18%).
Turn this on for Microtune 4049FM5, as recomended by tuner datasheet.

Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
diff --git a/drivers/media/video/tda9887.c b/drivers/media/video/tda9887.c
index 8dab481..87ffb0e 100644
--- a/drivers/media/video/tda9887.c
+++ b/drivers/media/video/tda9887.c
@@ -480,6 +480,8 @@
 	}
 	if ((t->tda9887_config & TDA9887_INTERCARRIER_NTSC) && (t->std & V4L2_STD_NTSC))
 		buf[1] &= ~cQSS;
+	if (t->tda9887_config & TDA9887_GATING_18)
+		buf[3] &= ~cGating_36;
 	return 0;
 }
 
diff --git a/drivers/media/video/tuner-simple.c b/drivers/media/video/tuner-simple.c
index 4cfe71b..63db4e9 100644
--- a/drivers/media/video/tuner-simple.c
+++ b/drivers/media/video/tuner-simple.c
@@ -331,6 +331,8 @@
 			else if (params->default_top_high)
 				config |= TDA9887_TOP(params->default_top_high);
 		}
+		if (params->default_pll_gating_18)
+			config |= TDA9887_GATING_18;
 		i2c_clients_command(c->adapter, TDA9887_SET_CONFIG, &config);
 	}
 	tuner_dbg("tv 0x%02x 0x%02x 0x%02x 0x%02x\n",
diff --git a/drivers/media/video/tuner-types.c b/drivers/media/video/tuner-types.c
index 8b54259..8fff642 100644
--- a/drivers/media/video/tuner-types.c
+++ b/drivers/media/video/tuner-types.c
@@ -650,6 +650,7 @@
 		.count  = ARRAY_SIZE(tuner_temic_4009f_5_pal_ranges),
 		.has_tda9887 = 1,
 		.port1_invert_for_secam_lc = 1,
+		.default_pll_gating_18 = 1,
 	},
 };