History

[media] v4l2: rename V4L2_TUNER_ADC to V4L2_TUNER_SDR

SDR receiver has ADC (Analog-to-Digital Converter) and SDR transmitter has DAC (Digital-to-Analog Converter). Originally I though it could be good idea to have own type for receiver and transmitter, but now I feel one common type for SDR is enough. So lets rename it. Signed-off-by: Antti Palosaari <crope@iki.fi> Acked-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> [hans.verkuil@cisco.com: this was added in 4.4, so update 4.2 to 4.4]

Antti Palosaari committed 11 years ago

Commit f3c3ece1 parent eda98795 files · +29 −7Browse files

Unified · Split

5 files
  1. Documentation/DocBook/media/v4l/compat.xml +12 −0
  2. Documentation/DocBook/media/v4l/dev-sdr.xml +3 −3
  3. Documentation/DocBook/media/v4l/v4l2.xml +7 −0
  4. drivers/media/v4l2-core/v4l2-ioctl.c +3 −3
  5. include/uapi/linux/videodev2.h +4 −1
Documentation/DocBook/media/v4l/compat.xml+12−0
@@ -2591,6 +2591,18 @@ and &v4l2-mbus-framefmt;. · 2590 unmodified lines
25912591 </orderedlist>
25922592 </section>
25932593
2594+ <section>
2595+ <title>V4L2 in Linux 4.4</title>
2596+ <orderedlist>
2597+ <listitem>
2598+ <para>Renamed <constant>V4L2_TUNER_ADC</constant> to
2599+<constant>V4L2_TUNER_SDR</constant>. The use of
2600+<constant>V4L2_TUNER_ADC</constant> is deprecated now.
2601+ </para>
2602+ </listitem>
2603+ </orderedlist>
2604+ </section>
2605+
25942606 <section id="other">
25952607 <title>Relation of V4L2 to other Linux multimedia APIs</title>
25962608
Documentation/DocBook/media/v4l/dev-sdr.xml+3−3
@@ -44,10 +44,10 @@ frequency. · 43 unmodified lines
4444 </para>
4545
4646 <para>
47−The <constant>V4L2_TUNER_ADC</constant> tuner type is used for ADC tuners, and
47+The <constant>V4L2_TUNER_SDR</constant> tuner type is used for SDR tuners, and
4848 the <constant>V4L2_TUNER_RF</constant> tuner type is used for RF tuners. The
49−tuner index of the RF tuner (if any) must always follow the ADC tuner index.
50−Normally the ADC tuner is #0 and the RF tuner is #1.
49+tuner index of the RF tuner (if any) must always follow the SDR tuner index.
50+Normally the SDR tuner is #0 and the RF tuner is #1.
5151 </para>
5252
5353 <para>
Documentation/DocBook/media/v4l/v4l2.xml+7−0
@@ -151,6 +151,13 @@ Rubli, Andy Walls, Muralidharan Karicheri, Mauro Carvalho Chehab, · 150 unmodified lines
151151 structs, ioctls) must be noted in more detail in the history chapter
152152 (compat.xml), along with the possible impact on existing drivers and
153153 applications. -->
154+ <revision>
155+ <revnumber>4.4</revnumber>
156+ <date>2015-05-26</date>
157+ <authorinitials>ap</authorinitials>
158+ <revremark>Renamed V4L2_TUNER_ADC to V4L2_TUNER_SDR.
159+ </revremark>
160+ </revision>
154161
155162 <revision>
156163 <revnumber>3.21</revnumber>
drivers/media/v4l2-core/v4l2-ioctl.c+3−3
@@ -1637,7 +1637,7 @@ static int v4l_g_frequency(const struct v4l2_ioctl_ops *ops, · 1636 unmodified lines
16371637 struct v4l2_frequency *p = arg;
16381638
16391639 if (vfd->vfl_type == VFL_TYPE_SDR)
1640− p->type = V4L2_TUNER_ADC;
1640+ p->type = V4L2_TUNER_SDR;
16411641 else
16421642 p->type = (vfd->vfl_type == VFL_TYPE_RADIO) ?
16431643 V4L2_TUNER_RADIO : V4L2_TUNER_ANALOG_TV;
@@ -1652,7 +1652,7 @@ static int v4l_s_frequency(const struct v4l2_ioctl_ops *ops, · 8 unmodified lines
16521652 enum v4l2_tuner_type type;
16531653
16541654 if (vfd->vfl_type == VFL_TYPE_SDR) {
1655− if (p->type != V4L2_TUNER_ADC && p->type != V4L2_TUNER_RF)
1655+ if (p->type != V4L2_TUNER_SDR && p->type != V4L2_TUNER_RF)
16561656 return -EINVAL;
16571657 } else {
16581658 type = (vfd->vfl_type == VFL_TYPE_RADIO) ?
@@ -2277,7 +2277,7 @@ static int v4l_enum_freq_bands(const struct v4l2_ioctl_ops *ops, · 618 unmodified lines
22772277 int err;
22782278
22792279 if (vfd->vfl_type == VFL_TYPE_SDR) {
2280− if (p->type != V4L2_TUNER_ADC && p->type != V4L2_TUNER_RF)
2280+ if (p->type != V4L2_TUNER_SDR && p->type != V4L2_TUNER_RF)
22812281 return -EINVAL;
22822282 type = p->type;
22832283 } else {
include/uapi/linux/videodev2.h+4−1
@@ -165,10 +165,13 @@ enum v4l2_tuner_type { · 164 unmodified lines
165165 V4L2_TUNER_RADIO = 1,
166166 V4L2_TUNER_ANALOG_TV = 2,
167167 V4L2_TUNER_DIGITAL_TV = 3,
168− V4L2_TUNER_ADC = 4,
168+ V4L2_TUNER_SDR = 4,
169169 V4L2_TUNER_RF = 5,
170170 };
171171
172+/* Deprecated, do not use */
173+#define V4L2_TUNER_ADC V4L2_TUNER_SDR
174+
172175 enum v4l2_memory {
173176 V4L2_MEMORY_MMAP = 1,
174177 V4L2_MEMORY_USERPTR = 2,

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t