diff options
-rw-r--r-- | drivers/media/v4l2-core/v4l2-common.c | 5 | ||||
-rw-r--r-- | drivers/media/v4l2-core/v4l2-dev.c | 5 | ||||
-rw-r--r-- | drivers/media/v4l2-core/v4l2-ioctl.c | 115 | ||||
-rw-r--r-- | include/media/v4l2-ioctl.h | 3 | ||||
-rw-r--r-- | include/uapi/linux/videodev2.h | 34 |
5 files changed, 146 insertions, 16 deletions
diff --git a/drivers/media/v4l2-core/v4l2-common.c b/drivers/media/v4l2-core/v4l2-common.c index a9e7703560ad..f8fac9cefc3c 100644 --- a/drivers/media/v4l2-core/v4l2-common.c +++ b/drivers/media/v4l2-core/v4l2-common.c | |||
@@ -230,7 +230,7 @@ EXPORT_SYMBOL(v4l2_ctrl_next); | |||
230 | int v4l2_chip_match_host(const struct v4l2_dbg_match *match) | 230 | int v4l2_chip_match_host(const struct v4l2_dbg_match *match) |
231 | { | 231 | { |
232 | switch (match->type) { | 232 | switch (match->type) { |
233 | case V4L2_CHIP_MATCH_HOST: | 233 | case V4L2_CHIP_MATCH_BRIDGE: |
234 | return match->addr == 0; | 234 | return match->addr == 0; |
235 | default: | 235 | default: |
236 | return 0; | 236 | return 0; |
@@ -254,6 +254,9 @@ int v4l2_chip_match_i2c_client(struct i2c_client *c, const struct v4l2_dbg_match | |||
254 | return len && !strncmp(c->driver->driver.name, match->name, len); | 254 | return len && !strncmp(c->driver->driver.name, match->name, len); |
255 | case V4L2_CHIP_MATCH_I2C_ADDR: | 255 | case V4L2_CHIP_MATCH_I2C_ADDR: |
256 | return c->addr == match->addr; | 256 | return c->addr == match->addr; |
257 | case V4L2_CHIP_MATCH_SUBDEV_IDX: | ||
258 | case V4L2_CHIP_MATCH_SUBDEV_NAME: | ||
259 | return 1; | ||
257 | default: | 260 | default: |
258 | return 0; | 261 | return 0; |
259 | } | 262 | } |
diff --git a/drivers/media/v4l2-core/v4l2-dev.c b/drivers/media/v4l2-core/v4l2-dev.c index 1fbd95755e75..670b9ca8ecbe 100644 --- a/drivers/media/v4l2-core/v4l2-dev.c +++ b/drivers/media/v4l2-core/v4l2-dev.c | |||
@@ -591,9 +591,10 @@ static void determine_valid_ioctls(struct video_device *vdev) | |||
591 | SET_VALID_IOCTL(ops, VIDIOC_G_FREQUENCY, vidioc_g_frequency); | 591 | SET_VALID_IOCTL(ops, VIDIOC_G_FREQUENCY, vidioc_g_frequency); |
592 | SET_VALID_IOCTL(ops, VIDIOC_S_FREQUENCY, vidioc_s_frequency); | 592 | SET_VALID_IOCTL(ops, VIDIOC_S_FREQUENCY, vidioc_s_frequency); |
593 | SET_VALID_IOCTL(ops, VIDIOC_LOG_STATUS, vidioc_log_status); | 593 | SET_VALID_IOCTL(ops, VIDIOC_LOG_STATUS, vidioc_log_status); |
594 | set_bit(_IOC_NR(VIDIOC_DBG_G_CHIP_NAME), valid_ioctls); | ||
594 | #ifdef CONFIG_VIDEO_ADV_DEBUG | 595 | #ifdef CONFIG_VIDEO_ADV_DEBUG |
595 | SET_VALID_IOCTL(ops, VIDIOC_DBG_G_REGISTER, vidioc_g_register); | 596 | set_bit(_IOC_NR(VIDIOC_DBG_G_REGISTER), valid_ioctls); |
596 | SET_VALID_IOCTL(ops, VIDIOC_DBG_S_REGISTER, vidioc_s_register); | 597 | set_bit(_IOC_NR(VIDIOC_DBG_S_REGISTER), valid_ioctls); |
597 | #endif | 598 | #endif |
598 | SET_VALID_IOCTL(ops, VIDIOC_DBG_G_CHIP_IDENT, vidioc_g_chip_ident); | 599 | SET_VALID_IOCTL(ops, VIDIOC_DBG_G_CHIP_IDENT, vidioc_g_chip_ident); |
599 | /* yes, really vidioc_subscribe_event */ | 600 | /* yes, really vidioc_subscribe_event */ |
diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c index 83aa39dfe07c..336ed2dd607c 100644 --- a/drivers/media/v4l2-core/v4l2-ioctl.c +++ b/drivers/media/v4l2-core/v4l2-ioctl.c | |||
@@ -629,7 +629,8 @@ static void v4l_print_dbg_chip_ident(const void *arg, bool write_only) | |||
629 | const struct v4l2_dbg_chip_ident *p = arg; | 629 | const struct v4l2_dbg_chip_ident *p = arg; |
630 | 630 | ||
631 | pr_cont("type=%u, ", p->match.type); | 631 | pr_cont("type=%u, ", p->match.type); |
632 | if (p->match.type == V4L2_CHIP_MATCH_I2C_DRIVER) | 632 | if (p->match.type == V4L2_CHIP_MATCH_I2C_DRIVER || |
633 | p->match.type == V4L2_CHIP_MATCH_SUBDEV_NAME) | ||
633 | pr_cont("name=%.*s, ", | 634 | pr_cont("name=%.*s, ", |
634 | (int)sizeof(p->match.name), p->match.name); | 635 | (int)sizeof(p->match.name), p->match.name); |
635 | else | 636 | else |
@@ -638,12 +639,27 @@ static void v4l_print_dbg_chip_ident(const void *arg, bool write_only) | |||
638 | p->ident, p->revision); | 639 | p->ident, p->revision); |
639 | } | 640 | } |
640 | 641 | ||
642 | static void v4l_print_dbg_chip_name(const void *arg, bool write_only) | ||
643 | { | ||
644 | const struct v4l2_dbg_chip_name *p = arg; | ||
645 | |||
646 | pr_cont("type=%u, ", p->match.type); | ||
647 | if (p->match.type == V4L2_CHIP_MATCH_I2C_DRIVER || | ||
648 | p->match.type == V4L2_CHIP_MATCH_SUBDEV_NAME) | ||
649 | pr_cont("name=%.*s, ", | ||
650 | (int)sizeof(p->match.name), p->match.name); | ||
651 | else | ||
652 | pr_cont("addr=%u, ", p->match.addr); | ||
653 | pr_cont("name=%.*s\n", (int)sizeof(p->name), p->name); | ||
654 | } | ||
655 | |||
641 | static void v4l_print_dbg_register(const void *arg, bool write_only) | 656 | static void v4l_print_dbg_register(const void *arg, bool write_only) |
642 | { | 657 | { |
643 | const struct v4l2_dbg_register *p = arg; | 658 | const struct v4l2_dbg_register *p = arg; |
644 | 659 | ||
645 | pr_cont("type=%u, ", p->match.type); | 660 | pr_cont("type=%u, ", p->match.type); |
646 | if (p->match.type == V4L2_CHIP_MATCH_I2C_DRIVER) | 661 | if (p->match.type == V4L2_CHIP_MATCH_I2C_DRIVER || |
662 | p->match.type == V4L2_CHIP_MATCH_SUBDEV_NAME) | ||
647 | pr_cont("name=%.*s, ", | 663 | pr_cont("name=%.*s, ", |
648 | (int)sizeof(p->match.name), p->match.name); | 664 | (int)sizeof(p->match.name), p->match.name); |
649 | else | 665 | else |
@@ -1775,15 +1791,38 @@ static int v4l_log_status(const struct v4l2_ioctl_ops *ops, | |||
1775 | return ret; | 1791 | return ret; |
1776 | } | 1792 | } |
1777 | 1793 | ||
1794 | static bool v4l_dbg_found_match(const struct v4l2_dbg_match *match, | ||
1795 | struct v4l2_subdev *sd, int idx) | ||
1796 | { | ||
1797 | if (match->type == V4L2_CHIP_MATCH_SUBDEV_IDX) | ||
1798 | return match->addr == idx; | ||
1799 | return !strcmp(match->name, sd->name); | ||
1800 | } | ||
1801 | |||
1778 | static int v4l_dbg_g_register(const struct v4l2_ioctl_ops *ops, | 1802 | static int v4l_dbg_g_register(const struct v4l2_ioctl_ops *ops, |
1779 | struct file *file, void *fh, void *arg) | 1803 | struct file *file, void *fh, void *arg) |
1780 | { | 1804 | { |
1781 | #ifdef CONFIG_VIDEO_ADV_DEBUG | 1805 | #ifdef CONFIG_VIDEO_ADV_DEBUG |
1782 | struct v4l2_dbg_register *p = arg; | 1806 | struct v4l2_dbg_register *p = arg; |
1807 | struct video_device *vfd = video_devdata(file); | ||
1808 | struct v4l2_subdev *sd; | ||
1809 | int idx = 0; | ||
1783 | 1810 | ||
1784 | if (!capable(CAP_SYS_ADMIN)) | 1811 | if (!capable(CAP_SYS_ADMIN)) |
1785 | return -EPERM; | 1812 | return -EPERM; |
1786 | return ops->vidioc_g_register(file, fh, p); | 1813 | if (p->match.type == V4L2_CHIP_MATCH_SUBDEV_IDX || |
1814 | p->match.type == V4L2_CHIP_MATCH_SUBDEV_NAME) { | ||
1815 | if (vfd->v4l2_dev == NULL) | ||
1816 | return -EINVAL; | ||
1817 | v4l2_device_for_each_subdev(sd, vfd->v4l2_dev) { | ||
1818 | if (v4l_dbg_found_match(&p->match, sd, idx++)) | ||
1819 | return v4l2_subdev_call(sd, core, g_register, p); | ||
1820 | } | ||
1821 | return -EINVAL; | ||
1822 | } | ||
1823 | if (ops->vidioc_g_register) | ||
1824 | return ops->vidioc_g_register(file, fh, p); | ||
1825 | return -EINVAL; | ||
1787 | #else | 1826 | #else |
1788 | return -ENOTTY; | 1827 | return -ENOTTY; |
1789 | #endif | 1828 | #endif |
@@ -1794,10 +1833,25 @@ static int v4l_dbg_s_register(const struct v4l2_ioctl_ops *ops, | |||
1794 | { | 1833 | { |
1795 | #ifdef CONFIG_VIDEO_ADV_DEBUG | 1834 | #ifdef CONFIG_VIDEO_ADV_DEBUG |
1796 | const struct v4l2_dbg_register *p = arg; | 1835 | const struct v4l2_dbg_register *p = arg; |
1836 | struct video_device *vfd = video_devdata(file); | ||
1837 | struct v4l2_subdev *sd; | ||
1838 | int idx = 0; | ||
1797 | 1839 | ||
1798 | if (!capable(CAP_SYS_ADMIN)) | 1840 | if (!capable(CAP_SYS_ADMIN)) |
1799 | return -EPERM; | 1841 | return -EPERM; |
1800 | return ops->vidioc_s_register(file, fh, p); | 1842 | if (p->match.type == V4L2_CHIP_MATCH_SUBDEV_IDX || |
1843 | p->match.type == V4L2_CHIP_MATCH_SUBDEV_NAME) { | ||
1844 | if (vfd->v4l2_dev == NULL) | ||
1845 | return -EINVAL; | ||
1846 | v4l2_device_for_each_subdev(sd, vfd->v4l2_dev) { | ||
1847 | if (v4l_dbg_found_match(&p->match, sd, idx++)) | ||
1848 | return v4l2_subdev_call(sd, core, s_register, p); | ||
1849 | } | ||
1850 | return -EINVAL; | ||
1851 | } | ||
1852 | if (ops->vidioc_s_register) | ||
1853 | return ops->vidioc_s_register(file, fh, p); | ||
1854 | return -EINVAL; | ||
1801 | #else | 1855 | #else |
1802 | return -ENOTTY; | 1856 | return -ENOTTY; |
1803 | #endif | 1857 | #endif |
@@ -1810,9 +1864,61 @@ static int v4l_dbg_g_chip_ident(const struct v4l2_ioctl_ops *ops, | |||
1810 | 1864 | ||
1811 | p->ident = V4L2_IDENT_NONE; | 1865 | p->ident = V4L2_IDENT_NONE; |
1812 | p->revision = 0; | 1866 | p->revision = 0; |
1867 | if (p->match.type == V4L2_CHIP_MATCH_SUBDEV_NAME || | ||
1868 | p->match.type == V4L2_CHIP_MATCH_SUBDEV_IDX) | ||
1869 | return -EINVAL; | ||
1813 | return ops->vidioc_g_chip_ident(file, fh, p); | 1870 | return ops->vidioc_g_chip_ident(file, fh, p); |
1814 | } | 1871 | } |
1815 | 1872 | ||
1873 | static int v4l_dbg_g_chip_name(const struct v4l2_ioctl_ops *ops, | ||
1874 | struct file *file, void *fh, void *arg) | ||
1875 | { | ||
1876 | struct video_device *vfd = video_devdata(file); | ||
1877 | struct v4l2_dbg_chip_name *p = arg; | ||
1878 | struct v4l2_subdev *sd; | ||
1879 | int idx = 0; | ||
1880 | |||
1881 | switch (p->match.type) { | ||
1882 | case V4L2_CHIP_MATCH_BRIDGE: | ||
1883 | #ifdef CONFIG_VIDEO_ADV_DEBUG | ||
1884 | if (ops->vidioc_s_register) | ||
1885 | p->flags |= V4L2_CHIP_FL_WRITABLE; | ||
1886 | if (ops->vidioc_g_register) | ||
1887 | p->flags |= V4L2_CHIP_FL_READABLE; | ||
1888 | #endif | ||
1889 | if (ops->vidioc_g_chip_name) | ||
1890 | return ops->vidioc_g_chip_name(file, fh, arg); | ||
1891 | if (p->match.addr) | ||
1892 | return -EINVAL; | ||
1893 | if (vfd->v4l2_dev) | ||
1894 | strlcpy(p->name, vfd->v4l2_dev->name, sizeof(p->name)); | ||
1895 | else if (vfd->parent) | ||
1896 | strlcpy(p->name, vfd->parent->driver->name, sizeof(p->name)); | ||
1897 | else | ||
1898 | strlcpy(p->name, "bridge", sizeof(p->name)); | ||
1899 | return 0; | ||
1900 | |||
1901 | case V4L2_CHIP_MATCH_SUBDEV_IDX: | ||
1902 | case V4L2_CHIP_MATCH_SUBDEV_NAME: | ||
1903 | if (vfd->v4l2_dev == NULL) | ||
1904 | break; | ||
1905 | v4l2_device_for_each_subdev(sd, vfd->v4l2_dev) { | ||
1906 | if (v4l_dbg_found_match(&p->match, sd, idx++)) { | ||
1907 | #ifdef CONFIG_VIDEO_ADV_DEBUG | ||
1908 | if (sd->ops->core && sd->ops->core->s_register) | ||
1909 | p->flags |= V4L2_CHIP_FL_WRITABLE; | ||
1910 | if (sd->ops->core && sd->ops->core->g_register) | ||
1911 | p->flags |= V4L2_CHIP_FL_READABLE; | ||
1912 | #endif | ||
1913 | strlcpy(p->name, sd->name, sizeof(p->name)); | ||
1914 | return 0; | ||
1915 | } | ||
1916 | } | ||
1917 | break; | ||
1918 | } | ||
1919 | return -EINVAL; | ||
1920 | } | ||
1921 | |||
1816 | static int v4l_dqevent(const struct v4l2_ioctl_ops *ops, | 1922 | static int v4l_dqevent(const struct v4l2_ioctl_ops *ops, |
1817 | struct file *file, void *fh, void *arg) | 1923 | struct file *file, void *fh, void *arg) |
1818 | { | 1924 | { |
@@ -2027,6 +2133,7 @@ static struct v4l2_ioctl_info v4l2_ioctls[] = { | |||
2027 | IOCTL_INFO_STD(VIDIOC_QUERY_DV_TIMINGS, vidioc_query_dv_timings, v4l_print_dv_timings, 0), | 2133 | IOCTL_INFO_STD(VIDIOC_QUERY_DV_TIMINGS, vidioc_query_dv_timings, v4l_print_dv_timings, 0), |
2028 | IOCTL_INFO_STD(VIDIOC_DV_TIMINGS_CAP, vidioc_dv_timings_cap, v4l_print_dv_timings_cap, INFO_FL_CLEAR(v4l2_dv_timings_cap, type)), | 2134 | IOCTL_INFO_STD(VIDIOC_DV_TIMINGS_CAP, vidioc_dv_timings_cap, v4l_print_dv_timings_cap, INFO_FL_CLEAR(v4l2_dv_timings_cap, type)), |
2029 | IOCTL_INFO_FNC(VIDIOC_ENUM_FREQ_BANDS, v4l_enum_freq_bands, v4l_print_freq_band, 0), | 2135 | IOCTL_INFO_FNC(VIDIOC_ENUM_FREQ_BANDS, v4l_enum_freq_bands, v4l_print_freq_band, 0), |
2136 | IOCTL_INFO_FNC(VIDIOC_DBG_G_CHIP_NAME, v4l_dbg_g_chip_name, v4l_print_dbg_chip_name, INFO_FL_CLEAR(v4l2_dbg_chip_name, match)), | ||
2030 | }; | 2137 | }; |
2031 | #define V4L2_IOCTLS ARRAY_SIZE(v4l2_ioctls) | 2138 | #define V4L2_IOCTLS ARRAY_SIZE(v4l2_ioctls) |
2032 | 2139 | ||
diff --git a/include/media/v4l2-ioctl.h b/include/media/v4l2-ioctl.h index e10c2432f902..75a7dfc07dec 100644 --- a/include/media/v4l2-ioctl.h +++ b/include/media/v4l2-ioctl.h | |||
@@ -247,6 +247,9 @@ struct v4l2_ioctl_ops { | |||
247 | int (*vidioc_g_chip_ident) (struct file *file, void *fh, | 247 | int (*vidioc_g_chip_ident) (struct file *file, void *fh, |
248 | struct v4l2_dbg_chip_ident *chip); | 248 | struct v4l2_dbg_chip_ident *chip); |
249 | 249 | ||
250 | int (*vidioc_g_chip_name) (struct file *file, void *fh, | ||
251 | struct v4l2_dbg_chip_name *chip); | ||
252 | |||
250 | int (*vidioc_enum_framesizes) (struct file *file, void *fh, | 253 | int (*vidioc_enum_framesizes) (struct file *file, void *fh, |
251 | struct v4l2_frmsizeenum *fsize); | 254 | struct v4l2_frmsizeenum *fsize); |
252 | 255 | ||
diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h index 9d57dba27412..e9c49c5e6416 100644 --- a/include/uapi/linux/videodev2.h +++ b/include/uapi/linux/videodev2.h | |||
@@ -1807,10 +1807,13 @@ struct v4l2_event_subscription { | |||
1807 | 1807 | ||
1808 | /* VIDIOC_DBG_G_REGISTER and VIDIOC_DBG_S_REGISTER */ | 1808 | /* VIDIOC_DBG_G_REGISTER and VIDIOC_DBG_S_REGISTER */ |
1809 | 1809 | ||
1810 | #define V4L2_CHIP_MATCH_HOST 0 /* Match against chip ID on host (0 for the host) */ | 1810 | #define V4L2_CHIP_MATCH_BRIDGE 0 /* Match against chip ID on the bridge (0 for the bridge) */ |
1811 | #define V4L2_CHIP_MATCH_I2C_DRIVER 1 /* Match against I2C driver name */ | 1811 | #define V4L2_CHIP_MATCH_HOST V4L2_CHIP_MATCH_BRIDGE |
1812 | #define V4L2_CHIP_MATCH_I2C_ADDR 2 /* Match against I2C 7-bit address */ | 1812 | #define V4L2_CHIP_MATCH_I2C_DRIVER 1 /* Match against I2C driver name */ |
1813 | #define V4L2_CHIP_MATCH_AC97 3 /* Match against anciliary AC97 chip */ | 1813 | #define V4L2_CHIP_MATCH_I2C_ADDR 2 /* Match against I2C 7-bit address */ |
1814 | #define V4L2_CHIP_MATCH_AC97 3 /* Match against anciliary AC97 chip */ | ||
1815 | #define V4L2_CHIP_MATCH_SUBDEV_NAME 4 /* Match against subdev name */ | ||
1816 | #define V4L2_CHIP_MATCH_SUBDEV_IDX 5 /* Match against subdev index */ | ||
1814 | 1817 | ||
1815 | struct v4l2_dbg_match { | 1818 | struct v4l2_dbg_match { |
1816 | __u32 type; /* Match type */ | 1819 | __u32 type; /* Match type */ |
@@ -1834,6 +1837,17 @@ struct v4l2_dbg_chip_ident { | |||
1834 | __u32 revision; /* chip revision, chip specific */ | 1837 | __u32 revision; /* chip revision, chip specific */ |
1835 | } __attribute__ ((packed)); | 1838 | } __attribute__ ((packed)); |
1836 | 1839 | ||
1840 | #define V4L2_CHIP_FL_READABLE (1 << 0) | ||
1841 | #define V4L2_CHIP_FL_WRITABLE (1 << 1) | ||
1842 | |||
1843 | /* VIDIOC_DBG_G_CHIP_NAME */ | ||
1844 | struct v4l2_dbg_chip_name { | ||
1845 | struct v4l2_dbg_match match; | ||
1846 | char name[32]; | ||
1847 | __u32 flags; | ||
1848 | __u32 reserved[8]; | ||
1849 | } __attribute__ ((packed)); | ||
1850 | |||
1837 | /** | 1851 | /** |
1838 | * struct v4l2_create_buffers - VIDIOC_CREATE_BUFS argument | 1852 | * struct v4l2_create_buffers - VIDIOC_CREATE_BUFS argument |
1839 | * @index: on return, index of the first created buffer | 1853 | * @index: on return, index of the first created buffer |
@@ -1911,15 +1925,12 @@ struct v4l2_create_buffers { | |||
1911 | #define VIDIOC_G_EXT_CTRLS _IOWR('V', 71, struct v4l2_ext_controls) | 1925 | #define VIDIOC_G_EXT_CTRLS _IOWR('V', 71, struct v4l2_ext_controls) |
1912 | #define VIDIOC_S_EXT_CTRLS _IOWR('V', 72, struct v4l2_ext_controls) | 1926 | #define VIDIOC_S_EXT_CTRLS _IOWR('V', 72, struct v4l2_ext_controls) |
1913 | #define VIDIOC_TRY_EXT_CTRLS _IOWR('V', 73, struct v4l2_ext_controls) | 1927 | #define VIDIOC_TRY_EXT_CTRLS _IOWR('V', 73, struct v4l2_ext_controls) |
1914 | #if 1 | ||
1915 | #define VIDIOC_ENUM_FRAMESIZES _IOWR('V', 74, struct v4l2_frmsizeenum) | 1928 | #define VIDIOC_ENUM_FRAMESIZES _IOWR('V', 74, struct v4l2_frmsizeenum) |
1916 | #define VIDIOC_ENUM_FRAMEINTERVALS _IOWR('V', 75, struct v4l2_frmivalenum) | 1929 | #define VIDIOC_ENUM_FRAMEINTERVALS _IOWR('V', 75, struct v4l2_frmivalenum) |
1917 | #define VIDIOC_G_ENC_INDEX _IOR('V', 76, struct v4l2_enc_idx) | 1930 | #define VIDIOC_G_ENC_INDEX _IOR('V', 76, struct v4l2_enc_idx) |
1918 | #define VIDIOC_ENCODER_CMD _IOWR('V', 77, struct v4l2_encoder_cmd) | 1931 | #define VIDIOC_ENCODER_CMD _IOWR('V', 77, struct v4l2_encoder_cmd) |
1919 | #define VIDIOC_TRY_ENCODER_CMD _IOWR('V', 78, struct v4l2_encoder_cmd) | 1932 | #define VIDIOC_TRY_ENCODER_CMD _IOWR('V', 78, struct v4l2_encoder_cmd) |
1920 | #endif | ||
1921 | 1933 | ||
1922 | #if 1 | ||
1923 | /* Experimental, meant for debugging, testing and internal use. | 1934 | /* Experimental, meant for debugging, testing and internal use. |
1924 | Only implemented if CONFIG_VIDEO_ADV_DEBUG is defined. | 1935 | Only implemented if CONFIG_VIDEO_ADV_DEBUG is defined. |
1925 | You must be root to use these ioctls. Never use these in applications! */ | 1936 | You must be root to use these ioctls. Never use these in applications! */ |
@@ -1927,9 +1938,10 @@ struct v4l2_create_buffers { | |||
1927 | #define VIDIOC_DBG_G_REGISTER _IOWR('V', 80, struct v4l2_dbg_register) | 1938 | #define VIDIOC_DBG_G_REGISTER _IOWR('V', 80, struct v4l2_dbg_register) |
1928 | 1939 | ||
1929 | /* Experimental, meant for debugging, testing and internal use. | 1940 | /* Experimental, meant for debugging, testing and internal use. |
1930 | Never use this ioctl in applications! */ | 1941 | Never use this ioctl in applications! |
1942 | Note: this ioctl is deprecated in favor of VIDIOC_DBG_G_CHIP_NAME and | ||
1943 | will go away in the future. */ | ||
1931 | #define VIDIOC_DBG_G_CHIP_IDENT _IOWR('V', 81, struct v4l2_dbg_chip_ident) | 1944 | #define VIDIOC_DBG_G_CHIP_IDENT _IOWR('V', 81, struct v4l2_dbg_chip_ident) |
1932 | #endif | ||
1933 | 1945 | ||
1934 | #define VIDIOC_S_HW_FREQ_SEEK _IOW('V', 82, struct v4l2_hw_freq_seek) | 1946 | #define VIDIOC_S_HW_FREQ_SEEK _IOW('V', 82, struct v4l2_hw_freq_seek) |
1935 | 1947 | ||
@@ -1963,6 +1975,10 @@ struct v4l2_create_buffers { | |||
1963 | versions. */ | 1975 | versions. */ |
1964 | #define VIDIOC_ENUM_FREQ_BANDS _IOWR('V', 101, struct v4l2_frequency_band) | 1976 | #define VIDIOC_ENUM_FREQ_BANDS _IOWR('V', 101, struct v4l2_frequency_band) |
1965 | 1977 | ||
1978 | /* Experimental, meant for debugging, testing and internal use. | ||
1979 | Never use these in applications! */ | ||
1980 | #define VIDIOC_DBG_G_CHIP_NAME _IOWR('V', 102, struct v4l2_dbg_chip_name) | ||
1981 | |||
1966 | /* Reminder: when adding new ioctls please add support for them to | 1982 | /* Reminder: when adding new ioctls please add support for them to |
1967 | drivers/media/video/v4l2-compat-ioctl32.c as well! */ | 1983 | drivers/media/video/v4l2-compat-ioctl32.c as well! */ |
1968 | 1984 | ||