Message ID | 1342021658-27821-2-git-send-email-hdegoede@redhat.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Hi Hans, Thanks for the patch. I've CC-ed Halli as well. On Wed July 11 2012 17:47:34 Hans de Goede wrote: > To allow apps to limit a hw-freq-seek to a specific band, for further > info see the documentation this patch adds for these new fields. > > Signed-off-by: Hans de Goede <hdegoede@redhat.com> > --- > .../DocBook/media/v4l/vidioc-s-hw-freq-seek.xml | 44 ++++++++++++++++---- > include/linux/videodev2.h | 5 ++- > 2 files changed, 40 insertions(+), 9 deletions(-) > > diff --git a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml > index f4db44d..50dc9f8 100644 > --- a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml > +++ b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml > @@ -52,11 +52,21 @@ > <para>Start a hardware frequency seek from the current frequency. > To do this applications initialize the <structfield>tuner</structfield>, > <structfield>type</structfield>, <structfield>seek_upward</structfield>, > -<structfield>spacing</structfield> and > -<structfield>wrap_around</structfield> fields, and zero out the > -<structfield>reserved</structfield> array of a &v4l2-hw-freq-seek; and > -call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> ioctl with a pointer > -to this structure.</para> > +<structfield>wrap_around</structfield>, <structfield>spacing</structfield>, > +<structfield>rangelow</structfield> and <structfield>rangehigh</structfield> > +fields, and zero out the <structfield>reserved</structfield> array of a > +&v4l2-hw-freq-seek; and call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> > +ioctl with a pointer to this structure.</para> > + > + <para>The <structfield>rangelow</structfield> and > +<structfield>rangehigh</structfield> fields can be set to a non-zero value to > +tell the driver to search a specific band. If the &v4l2-tuner; > +<structfield>capability</structfield> field has the > +<constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag set, these values > +must fall within one of the bands returned by &VIDIOC-ENUM-FREQ-BANDS;. If > +the <constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag is not set, > +then these values must exactly match those of one of the bands returned by > +&VIDIOC-ENUM-FREQ-BANDS;.</para> OK, I have some questions here: 1) If you have a multiband tuner, what should happen if both low and high are zero? Currently it is undefined, other than that the seek should start from the current frequency until it reaches some limit. Halli, what does your hardware do? In particular, is the hwseek limited by the US/Europe or Japan band range or can it do the full range? If I'm not mistaken it is the former, right? If it is the former, then you need to explicitly set low + high to ensure that the hwseek uses the correct range because the driver can't guess which of the overlapping bands to use. 2) What happens if the current frequency is outside the low/high range? The hwseek spec says that the seek starts from the current frequency, so that might mean that hwseek returns -ERANGE in this case. Regards, Hans -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi Hans, On 07/11/2012 08:01 PM, Hans Verkuil wrote: > Hi Hans, > > Thanks for the patch. > > I've CC-ed Halli as well. > > On Wed July 11 2012 17:47:34 Hans de Goede wrote: >> To allow apps to limit a hw-freq-seek to a specific band, for further >> info see the documentation this patch adds for these new fields. >> >> Signed-off-by: Hans de Goede <hdegoede@redhat.com> >> --- >> .../DocBook/media/v4l/vidioc-s-hw-freq-seek.xml | 44 ++++++++++++++++---- >> include/linux/videodev2.h | 5 ++- >> 2 files changed, 40 insertions(+), 9 deletions(-) >> >> diff --git a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml >> index f4db44d..50dc9f8 100644 >> --- a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml >> +++ b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml >> @@ -52,11 +52,21 @@ >> <para>Start a hardware frequency seek from the current frequency. >> To do this applications initialize the <structfield>tuner</structfield>, >> <structfield>type</structfield>, <structfield>seek_upward</structfield>, >> -<structfield>spacing</structfield> and >> -<structfield>wrap_around</structfield> fields, and zero out the >> -<structfield>reserved</structfield> array of a &v4l2-hw-freq-seek; and >> -call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> ioctl with a pointer >> -to this structure.</para> >> +<structfield>wrap_around</structfield>, <structfield>spacing</structfield>, >> +<structfield>rangelow</structfield> and <structfield>rangehigh</structfield> >> +fields, and zero out the <structfield>reserved</structfield> array of a >> +&v4l2-hw-freq-seek; and call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> >> +ioctl with a pointer to this structure.</para> >> + >> + <para>The <structfield>rangelow</structfield> and >> +<structfield>rangehigh</structfield> fields can be set to a non-zero value to >> +tell the driver to search a specific band. If the &v4l2-tuner; >> +<structfield>capability</structfield> field has the >> +<constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag set, these values >> +must fall within one of the bands returned by &VIDIOC-ENUM-FREQ-BANDS;. If >> +the <constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag is not set, >> +then these values must exactly match those of one of the bands returned by >> +&VIDIOC-ENUM-FREQ-BANDS;.</para> > > OK, I have some questions here: > > 1) If you have a multiband tuner, what should happen if both low and high are > zero? Currently it is undefined, other than that the seek should start from > the current frequency until it reaches some limit. That would be driver specific, we could add the same "If rangelow/high is zero a reasonable default value is used." language as used for the spacing. For example for the si470x if both are zero I simply switch to the "Japan wide" band which covers all frequencies handled by the other bands, but if there is no such covers all ranges band, then the logical thing todo would just keep the band as is (so as determined by the last s_freq). > Halli, what does your hardware do? In particular, is the hwseek limited by the > US/Europe or Japan band range or can it do the full range? If I'm not mistaken > it is the former, right? > > If it is the former, then you need to explicitly set low + high to ensure that > the hwseek uses the correct range because the driver can't guess which of the > overlapping bands to use. > > 2) What happens if the current frequency is outside the low/high range? The > hwseek spec says that the seek starts from the current frequency, so that might > mean that hwseek returns -ERANGE in this case. What the si470x code currently does is just clamp the frequency to the new range before seeking, but -ERANGE works for me too. Regards, Hans -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Wed, Jul 11, 2012 at 1:01 PM, Hans Verkuil <hverkuil@xs4all.nl> wrote: > Hi Hans, > > Thanks for the patch. > > I've CC-ed Halli as well. > > On Wed July 11 2012 17:47:34 Hans de Goede wrote: >> To allow apps to limit a hw-freq-seek to a specific band, for further >> info see the documentation this patch adds for these new fields. >> >> Signed-off-by: Hans de Goede <hdegoede@redhat.com> >> --- >> .../DocBook/media/v4l/vidioc-s-hw-freq-seek.xml | 44 ++++++++++++++++---- >> include/linux/videodev2.h | 5 ++- >> 2 files changed, 40 insertions(+), 9 deletions(-) >> >> diff --git a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml >> index f4db44d..50dc9f8 100644 >> --- a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml >> +++ b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml >> @@ -52,11 +52,21 @@ >> <para>Start a hardware frequency seek from the current frequency. >> To do this applications initialize the <structfield>tuner</structfield>, >> <structfield>type</structfield>, <structfield>seek_upward</structfield>, >> -<structfield>spacing</structfield> and >> -<structfield>wrap_around</structfield> fields, and zero out the >> -<structfield>reserved</structfield> array of a &v4l2-hw-freq-seek; and >> -call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> ioctl with a pointer >> -to this structure.</para> >> +<structfield>wrap_around</structfield>, <structfield>spacing</structfield>, >> +<structfield>rangelow</structfield> and <structfield>rangehigh</structfield> >> +fields, and zero out the <structfield>reserved</structfield> array of a >> +&v4l2-hw-freq-seek; and call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> >> +ioctl with a pointer to this structure.</para> >> + >> + <para>The <structfield>rangelow</structfield> and >> +<structfield>rangehigh</structfield> fields can be set to a non-zero value to >> +tell the driver to search a specific band. If the &v4l2-tuner; >> +<structfield>capability</structfield> field has the >> +<constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag set, these values >> +must fall within one of the bands returned by &VIDIOC-ENUM-FREQ-BANDS;. If >> +the <constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag is not set, >> +then these values must exactly match those of one of the bands returned by >> +&VIDIOC-ENUM-FREQ-BANDS;.</para> > > OK, I have some questions here: > > 1) If you have a multiband tuner, what should happen if both low and high are > zero? Currently it is undefined, other than that the seek should start from > the current frequency until it reaches some limit. > > Halli, what does your hardware do? In particular, is the hwseek limited by the > US/Europe or Japan band range or can it do the full range? If I'm not mistaken > it is the former, right? You are right... my hardware seek is limited by the japan/US band range.... > If it is the former, then you need to explicitly set low + high to ensure that > the hwseek uses the correct range because the driver can't guess which of the > overlapping bands to use. Yes in my driver I will take care of this :).... > > 2) What happens if the current frequency is outside the low/high range? The > hwseek spec says that the seek starts from the current frequency, so that might > mean that hwseek returns -ERANGE in this case. > > Regards, > > Hans
On Wed 11 July 2012 20:37:14 Hans de Goede wrote: > Hi Hans, > > On 07/11/2012 08:01 PM, Hans Verkuil wrote: > > Hi Hans, > > > > Thanks for the patch. > > > > I've CC-ed Halli as well. > > > > On Wed July 11 2012 17:47:34 Hans de Goede wrote: > >> To allow apps to limit a hw-freq-seek to a specific band, for further > >> info see the documentation this patch adds for these new fields. > >> > >> Signed-off-by: Hans de Goede <hdegoede@redhat.com> > >> --- > >> .../DocBook/media/v4l/vidioc-s-hw-freq-seek.xml | 44 ++++++++++++++++---- > >> include/linux/videodev2.h | 5 ++- > >> 2 files changed, 40 insertions(+), 9 deletions(-) > >> > >> diff --git a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml > >> index f4db44d..50dc9f8 100644 > >> --- a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml > >> +++ b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml > >> @@ -52,11 +52,21 @@ > >> <para>Start a hardware frequency seek from the current frequency. > >> To do this applications initialize the <structfield>tuner</structfield>, > >> <structfield>type</structfield>, <structfield>seek_upward</structfield>, > >> -<structfield>spacing</structfield> and > >> -<structfield>wrap_around</structfield> fields, and zero out the > >> -<structfield>reserved</structfield> array of a &v4l2-hw-freq-seek; and > >> -call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> ioctl with a pointer > >> -to this structure.</para> > >> +<structfield>wrap_around</structfield>, <structfield>spacing</structfield>, > >> +<structfield>rangelow</structfield> and <structfield>rangehigh</structfield> > >> +fields, and zero out the <structfield>reserved</structfield> array of a > >> +&v4l2-hw-freq-seek; and call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> > >> +ioctl with a pointer to this structure.</para> > >> + > >> + <para>The <structfield>rangelow</structfield> and > >> +<structfield>rangehigh</structfield> fields can be set to a non-zero value to > >> +tell the driver to search a specific band. If the &v4l2-tuner; > >> +<structfield>capability</structfield> field has the > >> +<constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag set, these values > >> +must fall within one of the bands returned by &VIDIOC-ENUM-FREQ-BANDS;. If > >> +the <constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag is not set, > >> +then these values must exactly match those of one of the bands returned by > >> +&VIDIOC-ENUM-FREQ-BANDS;.</para> > > > > OK, I have some questions here: > > > > 1) If you have a multiband tuner, what should happen if both low and high are > > zero? Currently it is undefined, other than that the seek should start from > > the current frequency until it reaches some limit. > > That would be driver specific, we could add the same "If rangelow/high is zero > a reasonable default value is used." language as used for the spacing. For > example for the si470x if both are zero I simply switch to the "Japan wide" > band which covers all frequencies handled by the other bands, but if there > is no such covers all ranges band, then the logical thing todo would just keep > the band as is (so as determined by the last s_freq). > > > Halli, what does your hardware do? In particular, is the hwseek limited by the > > US/Europe or Japan band range or can it do the full range? If I'm not mistaken > > it is the former, right? > > > > If it is the former, then you need to explicitly set low + high to ensure that > > the hwseek uses the correct range because the driver can't guess which of the > > overlapping bands to use. > > > > 2) What happens if the current frequency is outside the low/high range? The > > hwseek spec says that the seek starts from the current frequency, so that might > > mean that hwseek returns -ERANGE in this case. > > What the si470x code currently does is just clamp the frequency to the new > range before seeking, but -ERANGE works for me too. Clamping is a better idea IMHO as long as it is documented. Regards, Hans -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi, On 07/11/2012 08:37 PM, halli manjunatha wrote: > On Wed, Jul 11, 2012 at 1:01 PM, Hans Verkuil <hverkuil@xs4all.nl> wrote: >> Hi Hans, >> >> Thanks for the patch. >> >> I've CC-ed Halli as well. >> >> On Wed July 11 2012 17:47:34 Hans de Goede wrote: >>> To allow apps to limit a hw-freq-seek to a specific band, for further >>> info see the documentation this patch adds for these new fields. >>> >>> Signed-off-by: Hans de Goede <hdegoede@redhat.com> >>> --- >>> .../DocBook/media/v4l/vidioc-s-hw-freq-seek.xml | 44 ++++++++++++++++---- >>> include/linux/videodev2.h | 5 ++- >>> 2 files changed, 40 insertions(+), 9 deletions(-) >>> >>> diff --git a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml >>> index f4db44d..50dc9f8 100644 >>> --- a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml >>> +++ b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml >>> @@ -52,11 +52,21 @@ >>> <para>Start a hardware frequency seek from the current frequency. >>> To do this applications initialize the <structfield>tuner</structfield>, >>> <structfield>type</structfield>, <structfield>seek_upward</structfield>, >>> -<structfield>spacing</structfield> and >>> -<structfield>wrap_around</structfield> fields, and zero out the >>> -<structfield>reserved</structfield> array of a &v4l2-hw-freq-seek; and >>> -call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> ioctl with a pointer >>> -to this structure.</para> >>> +<structfield>wrap_around</structfield>, <structfield>spacing</structfield>, >>> +<structfield>rangelow</structfield> and <structfield>rangehigh</structfield> >>> +fields, and zero out the <structfield>reserved</structfield> array of a >>> +&v4l2-hw-freq-seek; and call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> >>> +ioctl with a pointer to this structure.</para> >>> + >>> + <para>The <structfield>rangelow</structfield> and >>> +<structfield>rangehigh</structfield> fields can be set to a non-zero value to >>> +tell the driver to search a specific band. If the &v4l2-tuner; >>> +<structfield>capability</structfield> field has the >>> +<constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag set, these values >>> +must fall within one of the bands returned by &VIDIOC-ENUM-FREQ-BANDS;. If >>> +the <constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag is not set, >>> +then these values must exactly match those of one of the bands returned by >>> +&VIDIOC-ENUM-FREQ-BANDS;.</para> >> >> OK, I have some questions here: >> >> 1) If you have a multiband tuner, what should happen if both low and high are >> zero? Currently it is undefined, other than that the seek should start from >> the current frequency until it reaches some limit. >> >> Halli, what does your hardware do? In particular, is the hwseek limited by the >> US/Europe or Japan band range or can it do the full range? If I'm not mistaken >> it is the former, right? > > You are right... my hardware seek is limited by the japan/US band range.... > >> If it is the former, then you need to explicitly set low + high to ensure that >> the hwseek uses the correct range because the driver can't guess which of the >> overlapping bands to use. > > Yes in my driver I will take care of this :).... I think you misunderstood Hans here, not the driver but userspace will need to fill in the rangelow / rangehigh fields of struct v4l2_hw_freq_seek, because if the current freq is in the overlapping area of the bands, the driver cannot know which band to seek, so it will just have to guess, I think it is best to just leave the band at its current setting in that case. The way the new API works (which was done this way to preserve backward compat) is that the bands returned from ENUM_BANDS are there as information only. userspace never explicitly sets a band, so an old app will just see the entire 76-108 MHZ range in the tuner struct and may do a S_FREQUENCY for any of those frequencies, and the driver must automatically switch bands when necessary. With S_HW_FREQ_SEEK we've the 2 new fields to indicate the band to seek for new apps, but with old apps these fields will be 0, and the driver needs to just pick a band to search on a best effort basis, for the si470x IE, if no band is specified in struct v4l2_hw_freq_seek, I simply always switch to the "Japan wide" band of 76-108 Mhz as that includes all other bands supported by the si470x. Regards, Hans -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi, On 07/12/2012 11:27 AM, Hans Verkuil wrote: > On Wed 11 July 2012 20:37:14 Hans de Goede wrote: <snip> >>> 2) What happens if the current frequency is outside the low/high range? The >>> hwseek spec says that the seek starts from the current frequency, so that might >>> mean that hwseek returns -ERANGE in this case. >> >> What the si470x code currently does is just clamp the frequency to the new >> range before seeking, but -ERANGE works for me too. > > Clamping is a better idea IMHO as long as it is documented. Ok, I've respun this patch to improve the documentation in various parts, I'm resending the entire set right after this email. Regards, Hans p.s. Tomorrow morning I'm leaving for a week of vacation, during which I won't be reading my mail. If everybody agrees on the 2nd revision of this patchset please add it to your bands2 branch, and if you agree that this seems to be it wrt the API for tuner-bands, you could also consider sending a pull-req for it to Mauro for 3.6 :) -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml index f4db44d..50dc9f8 100644 --- a/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml +++ b/Documentation/DocBook/media/v4l/vidioc-s-hw-freq-seek.xml @@ -52,11 +52,21 @@ <para>Start a hardware frequency seek from the current frequency. To do this applications initialize the <structfield>tuner</structfield>, <structfield>type</structfield>, <structfield>seek_upward</structfield>, -<structfield>spacing</structfield> and -<structfield>wrap_around</structfield> fields, and zero out the -<structfield>reserved</structfield> array of a &v4l2-hw-freq-seek; and -call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> ioctl with a pointer -to this structure.</para> +<structfield>wrap_around</structfield>, <structfield>spacing</structfield>, +<structfield>rangelow</structfield> and <structfield>rangehigh</structfield> +fields, and zero out the <structfield>reserved</structfield> array of a +&v4l2-hw-freq-seek; and call the <constant>VIDIOC_S_HW_FREQ_SEEK</constant> +ioctl with a pointer to this structure.</para> + + <para>The <structfield>rangelow</structfield> and +<structfield>rangehigh</structfield> fields can be set to a non-zero value to +tell the driver to search a specific band. If the &v4l2-tuner; +<structfield>capability</structfield> field has the +<constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag set, these values +must fall within one of the bands returned by &VIDIOC-ENUM-FREQ-BANDS;. If +the <constant>V4L2_TUNER_CAP_HWSEEK_PROG_LIM</constant> flag is not set, +then these values must exactly match those of one of the bands returned by +&VIDIOC-ENUM-FREQ-BANDS;.</para> <para>If an error is returned, then the original frequency will be restored.</para> @@ -102,7 +112,23 @@ field and the &v4l2-tuner; <structfield>index</structfield> field.</entry> </row> <row> <entry>__u32</entry> - <entry><structfield>reserved</structfield>[7]</entry> + <entry><structfield>rangelow</structfield></entry> + <entry>If non-zero, the lowest tunable frequency of the band to +search in units of 62.5 kHz, or if the &v4l2-tuner; +<structfield>capability</structfield> field has the +<constant>V4L2_TUNER_CAP_LOW</constant> flag set, in units of 62.5 Hz.</entry> + </row> + <row> + <entry>__u32</entry> + <entry><structfield>rangehigh</structfield></entry> + <entry>If non-zero, the highest tunable frequency of the band to +search in units of 62.5 kHz, or if the &v4l2-tuner; +<structfield>capability</structfield> field has the +<constant>V4L2_TUNER_CAP_LOW</constant> flag set, in units of 62.5 Hz.</entry> + </row> + <row> + <entry>__u32</entry> + <entry><structfield>reserved</structfield>[5]</entry> <entry>Reserved for future extensions. Applications must set the array to zero.</entry> </row> @@ -119,8 +145,10 @@ field and the &v4l2-tuner; <structfield>index</structfield> field.</entry> <term><errorcode>EINVAL</errorcode></term> <listitem> <para>The <structfield>tuner</structfield> index is out of -bounds, the wrap_around value is not supported or the value in the <structfield>type</structfield> field is -wrong.</para> +bounds, the <structfield>wrap_around</structfield> value is not supported or +one of the values in the <structfield>type</structfield>, +<structfield>rangelow</structfield> or <structfield>rangehigh</structfield> +fields is wrong.</para> </listitem> </varlistentry> <varlistentry> diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index 9fa822a..1c6aa63 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h @@ -2029,6 +2029,7 @@ struct v4l2_modulator { #define V4L2_TUNER_CAP_RDS_BLOCK_IO 0x0100 #define V4L2_TUNER_CAP_RDS_CONTROLS 0x0200 #define V4L2_TUNER_CAP_FREQ_BANDS 0x0400 +#define V4L2_TUNER_CAP_HWSEEK_PROG_LIM 0x0800 /* Flags for the 'rxsubchans' field */ #define V4L2_TUNER_SUB_MONO 0x0001 @@ -2074,7 +2075,9 @@ struct v4l2_hw_freq_seek { __u32 seek_upward; __u32 wrap_around; __u32 spacing; - __u32 reserved[7]; + __u32 rangelow; + __u32 rangehigh; + __u32 reserved[5]; }; /*
To allow apps to limit a hw-freq-seek to a specific band, for further info see the documentation this patch adds for these new fields. Signed-off-by: Hans de Goede <hdegoede@redhat.com> --- .../DocBook/media/v4l/vidioc-s-hw-freq-seek.xml | 44 ++++++++++++++++---- include/linux/videodev2.h | 5 ++- 2 files changed, 40 insertions(+), 9 deletions(-)