mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 2/2] video/tuner: add VIDEO_G_FREQUENCY and freq range to VIDIOC_G_TUNER
@ 2005-05-06 14:15 Jiri Benc
  0 siblings, 0 replies; only message in thread
From: Jiri Benc @ 2005-05-06 14:15 UTC (permalink / raw)
  To: v4l; +Cc: LKML

This patch adds a VIDIOC_G_FREQUENCY command to tuner-core.c and sets
lowest and highest tunable frequencies in v4l2_tuner structure returned
by VIDIOC_G_TUNER command.


Signed-off-by: Jiri Benc <jbenc@suse.cz>

--- a/drivers/media/video/tuner-core.c
+++ b/drivers/media/video/tuner-core.c
@@ -360,6 +360,15 @@
 		set_freq(client,f->frequency);
 		break;
 	}
+	case VIDIOC_G_FREQUENCY:
+	{
+		struct v4l2_frequency *f = arg;
+
+		SWITCH_V4L2;
+		f->type = t->mode;
+		f->frequency = t->freq;
+		break;
+	}
 	case VIDIOC_G_TUNER:
 	{
 		struct v4l2_tuner *tuner = arg;
@@ -367,6 +376,8 @@
 		SWITCH_V4L2;
 		if (V4L2_TUNER_RADIO == t->mode  &&  t->has_signal)
 			tuner->signal = t->has_signal(client);
+		tuner->rangelow = tv_range[0] * 16;
+		tuner->rangehigh = tv_range[1] * 16;
 		break;
 	}
 	default:


--
Jiri Benc
SUSE Labs

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2005-05-06 14:15 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-05-06 14:15 [PATCH 2/2] video/tuner: add VIDEO_G_FREQUENCY and freq range to VIDIOC_G_TUNER Jiri Benc

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®