Hi Sakari,
I love your patch! Yet something to improve:
[auto build test ERROR on linuxtv-media/master]
[also build test ERROR on next-20210212]
[cannot apply to v5.11]
[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]
url:
https://github.com/0day-ci/linux/commits/Sakari-Ailus/v4l-async-Fix-kerne...
base:
git://linuxtv.org/media_tree.git master
config: x86_64-randconfig-r035-20210215 (attached as .config)
compiler: clang version 12.0.0 (
https://github.com/llvm/llvm-project
c9439ca36342fb6013187d0a69aef92736951476)
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
# install x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
#
https://github.com/0day-ci/linux/commit/8e8c47cba531c1706847f07a4af5cd19a...
git remote add linux-review
https://github.com/0day-ci/linux
git fetch --no-tags linux-review
Sakari-Ailus/v4l-async-Fix-kerneldoc-documentation-for-async-functions/20210215-204146
git checkout 8e8c47cba531c1706847f07a4af5cd19aa33f351
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
> drivers/media/v4l2-core/v4l2-fwnode.c:945:9: error: expected
expression
asd = v4l2_async_notifier_add_fwnode_subdev(notifier,
^
include/media/v4l2-async.h:179:12: note: expanded from macro
'v4l2_async_notifier_add_fwnode_subdev'
((__type *)__v4l2_async_notifier_add_fwnode_subdev(notifier, fwnode, \
^
> drivers/media/v4l2-core/v4l2-fwnode.c:945:9: error: use of
undeclared identifier '__type'; did you mean '_ctype'?
include/media/v4l2-async.h:179:4: note: expanded from macro
'v4l2_async_notifier_add_fwnode_subdev'
((__type *)__v4l2_async_notifier_add_fwnode_subdev(notifier, fwnode, \
^
include/linux/ctype.h:21:28: note: '_ctype' declared here
extern const unsigned char _ctype[];
^
drivers/media/v4l2-core/v4l2-fwnode.c:1246:9: error: expected expression
asd = v4l2_async_notifier_add_fwnode_subdev(notifier, fwnode,
^
include/media/v4l2-async.h:179:12: note: expanded from macro
'v4l2_async_notifier_add_fwnode_subdev'
((__type *)__v4l2_async_notifier_add_fwnode_subdev(notifier, fwnode, \
^
drivers/media/v4l2-core/v4l2-fwnode.c:1246:9: error: use of undeclared identifier
'__type'; did you mean '_ctype'?
include/media/v4l2-async.h:179:4: note: expanded from macro
'v4l2_async_notifier_add_fwnode_subdev'
((__type *)__v4l2_async_notifier_add_fwnode_subdev(notifier, fwnode, \
^
include/linux/ctype.h:21:28: note: '_ctype' declared here
extern const unsigned char _ctype[];
^
4 errors generated.
vim +945 drivers/media/v4l2-core/v4l2-fwnode.c
9ca46531213295 Sakari Ailus 2017-08-17 902
d84285390f0722 Sakari Ailus 2017-06-20 903 /*
d84285390f0722 Sakari Ailus 2017-06-20 904 * v4l2_fwnode_reference_parse -
parse references for async sub-devices
d84285390f0722 Sakari Ailus 2017-06-20 905 * @dev: the device node the
properties of which are parsed for references
d84285390f0722 Sakari Ailus 2017-06-20 906 * @notifier: the async notifier
where the async subdevs will be added
d84285390f0722 Sakari Ailus 2017-06-20 907 * @prop: the name of the property
d84285390f0722 Sakari Ailus 2017-06-20 908 *
d84285390f0722 Sakari Ailus 2017-06-20 909 * Return: 0 on success
d84285390f0722 Sakari Ailus 2017-06-20 910 * -ENOENT if no entries were
found
d84285390f0722 Sakari Ailus 2017-06-20 911 * -ENOMEM if memory allocation
failed
d84285390f0722 Sakari Ailus 2017-06-20 912 * -EINVAL if property parsing
failed
d84285390f0722 Sakari Ailus 2017-06-20 913 */
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 914 static int
v4l2_fwnode_reference_parse(struct device *dev,
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 915 struct
v4l2_async_notifier *notifier,
d84285390f0722 Sakari Ailus 2017-06-20 916 const char *prop)
d84285390f0722 Sakari Ailus 2017-06-20 917 {
d84285390f0722 Sakari Ailus 2017-06-20 918 struct fwnode_reference_args args;
d84285390f0722 Sakari Ailus 2017-06-20 919 unsigned int index;
d84285390f0722 Sakari Ailus 2017-06-20 920 int ret;
d84285390f0722 Sakari Ailus 2017-06-20 921
d84285390f0722 Sakari Ailus 2017-06-20 922 for (index = 0;
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 923 !(ret =
fwnode_property_get_reference_args(dev_fwnode(dev),
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 924 prop, NULL, 0,
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 925 index, &args));
d84285390f0722 Sakari Ailus 2017-06-20 926 index++)
d84285390f0722 Sakari Ailus 2017-06-20 927 fwnode_handle_put(args.fwnode);
d84285390f0722 Sakari Ailus 2017-06-20 928
d84285390f0722 Sakari Ailus 2017-06-20 929 if (!index)
d84285390f0722 Sakari Ailus 2017-06-20 930 return -ENOENT;
d84285390f0722 Sakari Ailus 2017-06-20 931
d84285390f0722 Sakari Ailus 2017-06-20 932 /*
d84285390f0722 Sakari Ailus 2017-06-20 933 * Note that right now both
-ENODATA and -ENOENT may signal
d84285390f0722 Sakari Ailus 2017-06-20 934 * out-of-bounds access. Return the
error in cases other than that.
d84285390f0722 Sakari Ailus 2017-06-20 935 */
d84285390f0722 Sakari Ailus 2017-06-20 936 if (ret != -ENOENT && ret
!= -ENODATA)
d84285390f0722 Sakari Ailus 2017-06-20 937 return ret;
d84285390f0722 Sakari Ailus 2017-06-20 938
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 939 for (index = 0;
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 940
!fwnode_property_get_reference_args(dev_fwnode(dev), prop, NULL,
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 941 0, index, &args);
d84285390f0722 Sakari Ailus 2017-06-20 942 index++) {
d84285390f0722 Sakari Ailus 2017-06-20 943 struct v4l2_async_subdev *asd;
d84285390f0722 Sakari Ailus 2017-06-20 944
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 @945 asd =
v4l2_async_notifier_add_fwnode_subdev(notifier,
6087b21533fed7 Mauro Carvalho Chehab 2018-10-04 946 args.fwnode,
b01edcbd409cf7 Laurent Pinchart 2021-01-18 947 struct
v4l2_async_subdev);
016413d967061f Sakari Ailus 2019-04-04 948 fwnode_handle_put(args.fwnode);
eae2aed1eab9bf Steve Longerbeam 2018-09-29 949 if (IS_ERR(asd)) {
eae2aed1eab9bf Steve Longerbeam 2018-09-29 950 /* not an error if asd already
exists */
016413d967061f Sakari Ailus 2019-04-04 951 if (PTR_ERR(asd) == -EEXIST)
eae2aed1eab9bf Steve Longerbeam 2018-09-29 952 continue;
d84285390f0722 Sakari Ailus 2017-06-20 953
016413d967061f Sakari Ailus 2019-04-04 954 return PTR_ERR(asd);
d84285390f0722 Sakari Ailus 2017-06-20 955 }
d84285390f0722 Sakari Ailus 2017-06-20 956 }
d84285390f0722 Sakari Ailus 2017-06-20 957
d84285390f0722 Sakari Ailus 2017-06-20 958 return 0;
d84285390f0722 Sakari Ailus 2017-06-20 959 }
d84285390f0722 Sakari Ailus 2017-06-20 960
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org