mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-08-06 17:37:52 +00:00
media_build: drop linux-222-stb0899_signal_quality.patch
This commit is contained in:
parent
cb923633f5
commit
cb774ad705
@ -1,12 +1,11 @@
|
||||
--- a/backports/backports.txt
|
||||
+++ b/backports/backports.txt
|
||||
@@ -25,6 +25,16 @@
|
||||
@@ -25,6 +25,15 @@
|
||||
add pr_fmt.patch
|
||||
add debug.patch
|
||||
add drx39xxj.patch
|
||||
+add linux-202-lnbp22_patch_for_more_power_if_rotor.patch
|
||||
+add linux-203-stb0899_enable_low_symbol_rate.patch
|
||||
+add linux-222-stb0899_signal_quality.patch
|
||||
+add linux-052-XBOX_remote_support.patch
|
||||
+add linux-054-nuvoton_revert_d7b290a1056c5564eec8a1b169c6e84ff3.6.114c13.patch
|
||||
+add linux-057-Removed-MCE-customer-code-restriction-in-rc6-decode.patch
|
||||
|
@ -1,61 +0,0 @@
|
||||
--- a/drivers/media/dvb-frontends/stb0899_drv.c
|
||||
+++ b/drivers/media/dvb-frontends/stb0899_drv.c
|
||||
@@ -976,6 +976,16 @@ static int stb0899_read_signal_strength(struct dvb_frontend *fe, u16 *strength)
|
||||
|
||||
*strength = stb0899_table_lookup(stb0899_dvbsrf_tab, ARRAY_SIZE(stb0899_dvbsrf_tab) - 1, val);
|
||||
*strength += 750;
|
||||
+
|
||||
+ const int MIN_STRENGTH_DVBS = 0;
|
||||
+ const int MAX_STRENGTH_DVBS = 680;
|
||||
+ if (*strength < MIN_STRENGTH_DVBS)
|
||||
+ *strength = 0;
|
||||
+ else if(*strength > MAX_STRENGTH_DVBS)
|
||||
+ *strength = 0xFFFF;
|
||||
+ else
|
||||
+ *strength = (*strength - MIN_STRENGTH_DVBS) * 0xFFFF / (MAX_STRENGTH_DVBS - MIN_STRENGTH_DVBS);
|
||||
+
|
||||
dprintk(state->verbose, FE_DEBUG, 1, "AGCIQVALUE = 0x%02x, C = %d * 0.1 dBm",
|
||||
val & 0xff, *strength);
|
||||
}
|
||||
@@ -988,6 +998,7 @@ static int stb0899_read_signal_strength(struct dvb_frontend *fe, u16 *strength)
|
||||
|
||||
*strength = stb0899_table_lookup(stb0899_dvbs2rf_tab, ARRAY_SIZE(stb0899_dvbs2rf_tab) - 1, val);
|
||||
*strength += 950;
|
||||
+ *strength = *strength << 4;
|
||||
dprintk(state->verbose, FE_DEBUG, 1, "IF_AGC_GAIN = 0x%04x, C = %d * 0.1 dBm",
|
||||
val & 0x3fff, *strength);
|
||||
}
|
||||
@@ -1021,6 +1032,16 @@ static int stb0899_read_snr(struct dvb_frontend *fe, u16 *snr)
|
||||
val = MAKEWORD16(buf[0], buf[1]);
|
||||
|
||||
*snr = stb0899_table_lookup(stb0899_cn_tab, ARRAY_SIZE(stb0899_cn_tab) - 1, val);
|
||||
+
|
||||
+ const int MIN_SNR_DVBS = 0;
|
||||
+ const int MAX_SNR_DVBS = 200;
|
||||
+ if (*snr < MIN_SNR_DVBS)
|
||||
+ *snr = 0;
|
||||
+ else if(*snr > MAX_SNR_DVBS)
|
||||
+ *snr = 0xFFFF;
|
||||
+ else
|
||||
+ *snr = (*snr - MIN_SNR_DVBS) * 0xFFFF / (MAX_SNR_DVBS - MIN_SNR_DVBS);
|
||||
+
|
||||
dprintk(state->verbose, FE_DEBUG, 1, "NIR = 0x%02x%02x = %u, C/N = %d * 0.1 dBm\n",
|
||||
buf[0], buf[1], val, *snr);
|
||||
}
|
||||
@@ -1045,6 +1066,16 @@ static int stb0899_read_snr(struct dvb_frontend *fe, u16 *snr)
|
||||
val = (quantn - estn) / 10;
|
||||
}
|
||||
*snr = val;
|
||||
+
|
||||
+ const int MIN_SNR_DVBS2 = 10;
|
||||
+ const int MAX_SNR_DVBS2 = 70;
|
||||
+ if (*snr < MIN_SNR_DVBS2)
|
||||
+ *snr = 0;
|
||||
+ else if(*snr > MAX_SNR_DVBS2)
|
||||
+ *snr = 0xFFFF;
|
||||
+ else
|
||||
+ *snr = (*snr - MIN_SNR_DVBS2) * 0xFFFF / (MAX_SNR_DVBS2 - MIN_SNR_DVBS2);
|
||||
+
|
||||
dprintk(state->verbose, FE_DEBUG, 1, "Es/N0 quant = %d (%d) estimate = %u (%d), C/N = %d * 0.1 dBm",
|
||||
quant, quantn, est, estn, val);
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user