Commit 864a6b81 authored by Michael Krufky's avatar Michael Krufky Committed by Mauro Carvalho Chehab
Browse files

V4L/DVB (6787): tuner: bug-fix: default mode was set to bogus value



Fix type inconsistency in t->mode value, causing the following:

tuner' 1-0043: freq set: unknown mode: 0x0004!

(only visible with tuner debug enabled)

Signed-off-by: default avatarMichael Krufky <mkrufky@linuxtv.org>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@infradead.org>
parent a55db8cd
Loading
Loading
Loading
Loading
+3 −3
Original line number Original line Diff line number Diff line
@@ -1138,11 +1138,11 @@ static int tuner_probe(struct i2c_client *client)


	/* Sets a default mode */
	/* Sets a default mode */
	if (t->mode_mask & T_ANALOG_TV) {
	if (t->mode_mask & T_ANALOG_TV) {
		t->mode = T_ANALOG_TV;
		t->mode = V4L2_TUNER_ANALOG_TV;
	} else  if (t->mode_mask & T_RADIO) {
	} else  if (t->mode_mask & T_RADIO) {
		t->mode = T_RADIO;
		t->mode = V4L2_TUNER_RADIO;
	} else {
	} else {
		t->mode = T_DIGITAL_TV;
		t->mode = V4L2_TUNER_DIGITAL_TV;
	}
	}
	set_type(client, t->type, t->mode_mask, t->config, t->tuner_callback);
	set_type(client, t->type, t->mode_mask, t->config, t->tuner_callback);
	list_add_tail(&t->list, &tuner_list);
	list_add_tail(&t->list, &tuner_list);