[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202202042319.XtC6P0wx-lkp@intel.com>
Date: Fri, 4 Feb 2022 23:46:24 +0800
From: kernel test robot <lkp@...el.com>
To: Hector Martin <marcan@...can.st>
Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: [asahilinux:smc/work 9/11] drivers/platform/apple/smc_core.c:135:1:
error: expected ';' before 'struct'
tree: https://github.com/AsahiLinux/linux smc/work
head: fc848a39b71518ca1661de7057b87cb0e8cac9f9
commit: a429c9bbeba2b08856339793bd4a0d1a65a730a1 [9/11] platform/apple: Add new Apple Mac SMC driver
config: arm64-randconfig-r024-20220130 (https://download.01.org/0day-ci/archive/20220204/202202042319.XtC6P0wx-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 11.2.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/AsahiLinux/linux/commit/a429c9bbeba2b08856339793bd4a0d1a65a730a1
git remote add asahilinux https://github.com/AsahiLinux/linux
git fetch --no-tags asahilinux smc/work
git checkout a429c9bbeba2b08856339793bd4a0d1a65a730a1
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arm64 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
All errors (new ones prefixed by >>):
>> drivers/platform/apple/smc_core.c:135:1: error: expected ';' before 'struct'
135 | struct apple_smc *apple_smc_probe(struct device *dev, const struct apple_smc_backend_ops *ops, void *cookie)
| ^~~~~~
drivers/platform/apple/smc_core.c:25:30: warning: 'apple_smc_devs' defined but not used [-Wunused-const-variable=]
25 | static const struct mfd_cell apple_smc_devs[] = {
| ^~~~~~~~~~~~~~
vim +135 drivers/platform/apple/smc_core.c
134
> 135 struct apple_smc *apple_smc_probe(struct device *dev, const struct apple_smc_backend_ops *ops, void *cookie)
136 {
137 struct apple_smc *smc;
138 u32 count;
139 int ret;
140
141 smc = devm_kzalloc(dev, sizeof(*smc), GFP_KERNEL);
142 if (!smc)
143 return ERR_PTR(-ENOMEM);
144
145 smc->dev = dev;
146 smc->be_cookie = cookie;
147 smc->be = ops;
148 mutex_init(&smc->mutex);
149
150 ret = apple_smc_read_u32(smc, SMC_KEY(#KEY), &count);
151 if (ret)
152 return ERR_PTR(dev_err_probe(dev, ret, "Failed to get key count"));
153 smc->key_count = be32_to_cpu(count);
154
155 ret = apple_smc_get_key_by_index(smc, 0, &smc->first_key);
156 if (ret)
157 return ERR_PTR(dev_err_probe(dev, ret, "Failed to get first key"));
158
159 ret = apple_smc_get_key_by_index(smc, smc->key_count - 1, &smc->last_key);
160 if (ret)
161 return ERR_PTR(dev_err_probe(dev, ret, "Failed to get last key"));
162
163 dev_info(dev, "Initialized (%d keys %p4ch..%p4ch)\n",
164 smc->key_count, &smc->first_key, &smc->last_key);
165
166 dev_set_drvdata(dev, smc);
167
168 ret = mfd_add_devices(dev, -1, apple_smc_devs, ARRAY_SIZE(apple_smc_devs), NULL, 0, NULL);
169 if (ret)
170 return ERR_PTR(dev_err_probe(dev, ret, "Subdevice initialization failed"));
171
172 return smc;
173 }
174 EXPORT_SYMBOL(apple_smc_probe);
175
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Powered by blists - more mailing lists