Hi Yunke, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on media-tree/master] [also build test WARNING on linus/master v6.1-rc2 next-20221025] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Yunke-Cao/media-Implement-UVC-v1-5-ROI/20221025-135821 base: git://linuxtv.org/media_tree.git master patch link: https://lore.kernel.org/r/20221025055528.1117251-6-yunkec%40google.com patch subject: [PATCH v9 05/11] media: uvcvideo: Add support for compound controls config: m68k-allyesconfig (attached as .config) compiler: m68k-linux-gcc (GCC) 12.1.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # https://github.com/intel-lab-lkp/linux/commit/732343da19acba5e984f7e545a40c08e40000fc3 git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review Yunke-Cao/media-Implement-UVC-v1-5-ROI/20221025-135821 git checkout 732343da19acba5e984f7e545a40c08e40000fc3 # save the config file mkdir build_dir && cp config build_dir/.config COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=m68k SHELL=/bin/bash drivers/media/usb/uvc/ If you fix the issue, kindly add following tag where applicable | Reported-by: kernel test robot All warnings (new ones prefixed by >>): drivers/media/usb/uvc/uvc_ctrl.c:1847:5: warning: no previous prototype for '__uvc_ctrl_get_boundary_std' [-Wmissing-prototypes] 1847 | int __uvc_ctrl_get_boundary_std(struct uvc_video_chain *chain, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ >> drivers/media/usb/uvc/uvc_ctrl.c:1909:5: warning: no previous prototype for '__uvc_ctrl_set_compound' [-Wmissing-prototypes] 1909 | int __uvc_ctrl_set_compound(struct uvc_control_mapping *mapping, | ^~~~~~~~~~~~~~~~~~~~~~~ vim +/__uvc_ctrl_set_compound +1909 drivers/media/usb/uvc/uvc_ctrl.c 1846 > 1847 int __uvc_ctrl_get_boundary_std(struct uvc_video_chain *chain, 1848 struct uvc_control *ctrl, 1849 struct uvc_control_mapping *mapping, 1850 struct v4l2_ext_control *xctrl) 1851 { 1852 struct v4l2_queryctrl qc = { .id = xctrl->id }; 1853 1854 int ret = __uvc_query_v4l2_ctrl(chain, ctrl, mapping, &qc); 1855 1856 if (ret < 0) 1857 return ret; 1858 1859 xctrl->value = qc.default_value; 1860 return 0; 1861 } 1862 1863 static int __uvc_ctrl_get_boundary_compound(struct uvc_video_chain *chain, 1864 struct uvc_control *ctrl, 1865 struct uvc_control_mapping *mapping, 1866 struct v4l2_ext_control *xctrl) 1867 { 1868 int ret; 1869 1870 if (!uvc_ctrl_mapping_is_compound(mapping)) 1871 return -EINVAL; 1872 1873 if (!ctrl->cached) { 1874 ret = uvc_ctrl_populate_cache(chain, ctrl); 1875 if (ret < 0) 1876 return ret; 1877 } 1878 1879 return __uvc_ctrl_get_compound(mapping, ctrl, UVC_CTRL_DATA_DEF, xctrl); 1880 } 1881 1882 int uvc_ctrl_get_boundary(struct uvc_video_chain *chain, 1883 struct v4l2_ext_control *xctrl) 1884 { 1885 struct uvc_control *ctrl; 1886 struct uvc_control_mapping *mapping; 1887 int ret; 1888 1889 if (mutex_lock_interruptible(&chain->ctrl_mutex)) 1890 return -ERESTARTSYS; 1891 1892 ctrl = uvc_find_control(chain, xctrl->id, &mapping); 1893 if (!ctrl) { 1894 ret = -EINVAL; 1895 goto done; 1896 } 1897 1898 if (uvc_ctrl_mapping_is_compound(mapping)) 1899 ret = __uvc_ctrl_get_boundary_compound(chain, ctrl, mapping, 1900 xctrl); 1901 else 1902 ret = __uvc_ctrl_get_boundary_std(chain, ctrl, mapping, xctrl); 1903 1904 done: 1905 mutex_unlock(&chain->ctrl_mutex); 1906 return ret; 1907 } 1908 > 1909 int __uvc_ctrl_set_compound(struct uvc_control_mapping *mapping, 1910 struct v4l2_ext_control *xctrl, 1911 struct uvc_control *ctrl) 1912 { 1913 u8 *data; 1914 int ret; 1915 1916 if (xctrl->size != mapping->v4l2_size / 8) 1917 return -EINVAL; 1918 1919 data = kmalloc(xctrl->size, GFP_KERNEL); 1920 if (!data) 1921 return -ENOMEM; 1922 1923 ret = copy_from_user(data, xctrl->ptr, xctrl->size); 1924 if (ret < 0) 1925 goto out; 1926 1927 ret = mapping->set_compound(mapping, data, 1928 uvc_ctrl_data(ctrl, UVC_CTRL_DATA_CURRENT)); 1929 1930 __uvc_ctrl_get_compound(mapping, ctrl, UVC_CTRL_DATA_CURRENT, xctrl); 1931 1932 out: 1933 kfree(data); 1934 return ret; 1935 } 1936 -- 0-DAY CI Kernel Test Service https://01.org/lkp