Commit 9cddeb88 authored by Bradford Love's avatar Bradford Love Committed by Hans Verkuil
Browse files

media: si2157: Analog format fixes



Updates to support PAL-N and PAL-Nc
Verifies PAL-I and PAL-DK standards are working
Fixes and verifies SECAM-L now works

Signed-off-by: default avatarBradford Love <brad@nextdimension.cc>
Signed-off-by: default avatarHans Verkuil <hverkuil+cisco@kernel.org>
parent 24ae633a
Loading
Loading
Loading
Loading
+11 −4
Original line number Diff line number Diff line
@@ -638,20 +638,27 @@ static int si2157_set_analog_params(struct dvb_frontend *fe,
				color = 0x10;
			}
		}
	} else if (params->std & V4L2_STD_MN) {
	} else if (params->std & (V4L2_STD_MN | V4L2_STD_NTSC_443)) {
		std = "MN";
		bandwidth = 6000000;
		if_frequency = 5400000;
		system = 2;
		if (params->std & V4L2_STD_PAL_N) {
			std = "palN";
			color = 0x10;
		} else if (params->std & V4L2_STD_PAL_Nc) {
			std = "palNc";
			color = 0x10;
		}
	} else if (params->std & V4L2_STD_PAL_I) {
		std = "palI";
		bandwidth = 8000000;
		if_frequency = 7250000; /* TODO: does not work yet */
		if_frequency = 7250000;
		system = 4;
	} else if (params->std & V4L2_STD_DK) {
		std = "palDK";
		bandwidth = 8000000;
		if_frequency = 6900000; /* TODO: does not work yet */
		if_frequency = 6900000;
		system = 5;
		if (params->std & V4L2_STD_SECAM_DK) {
			std = "secamDK";
@@ -660,7 +667,7 @@ static int si2157_set_analog_params(struct dvb_frontend *fe,
	} else if (params->std & V4L2_STD_SECAM_L) {
		std = "secamL";
		bandwidth = 8000000;
		if_frequency = 6750000; /* TODO: untested */
		if_frequency = 6900000;
		system = 6;
		color = 0x10;
	} else if (params->std & V4L2_STD_SECAM_LC) {