[mcgrof-next:20211118-sysctl-cleanups-set-04-v2 9/36] fs/notify/dnotify/dnotify.c:36:70: error: macro "register_sysctl_init" passed 3 arguments, but takes just 2
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git 20211118-sysctl-cleanups-set-04-v2
head: 3110d41a56792588bd2f64621080948b0fceb6ab
commit: eff0b1a581f42e5d41c54bb94c590d48774cfbd2 [9/36] dnotify: move dnotify sysctl to dnotify.c
config: m68k-defconfig (attached as .config)
compiler: m68k-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://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git/com...
git remote add mcgrof-next https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git
git fetch --no-tags mcgrof-next 20211118-sysctl-cleanups-set-04-v2
git checkout eff0b1a581f42e5d41c54bb94c590d48774cfbd2
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=m68k SHELL=/bin/bash
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 >>):
fs/notify/dnotify/dnotify.c: In function 'dnotify_sysctl_init':
>> fs/notify/dnotify/dnotify.c:36:70: error: macro "register_sysctl_init" passed 3 arguments, but takes just 2
36 | register_sysctl_init("fs", dnotify_sysctls, "dnotify_sysctls");
| ^
In file included from include/linux/key.h:17,
from include/linux/cred.h:13,
from include/linux/sched/signal.h:10,
from include/linux/rcuwait.h:6,
from include/linux/percpu-rwsem.h:7,
from include/linux/fs.h:33,
from fs/notify/dnotify/dnotify.c:10:
include/linux/sysctl.h:210: note: macro "register_sysctl_init" defined here
210 | #define register_sysctl_init(path, table) __register_sysctl_init(path, table, #table)
|
>> fs/notify/dnotify/dnotify.c:36:9: error: 'register_sysctl_init' undeclared (first use in this function); did you mean 'register_sysctl_paths'?
36 | register_sysctl_init("fs", dnotify_sysctls, "dnotify_sysctls");
| ^~~~~~~~~~~~~~~~~~~~
| register_sysctl_paths
fs/notify/dnotify/dnotify.c:36:9: note: each undeclared identifier is reported only once for each function it appears in
At top level:
fs/notify/dnotify/dnotify.c:24:25: warning: 'dnotify_sysctls' defined but not used [-Wunused-variable]
24 | static struct ctl_table dnotify_sysctls[] = {
| ^~~~~~~~~~~~~~~
vim +/register_sysctl_init +36 fs/notify/dnotify/dnotify.c
21
22 int dir_notify_enable __read_mostly = 1;
23 #ifdef CONFIG_SYSCTL
24 static struct ctl_table dnotify_sysctls[] = {
25 {
26 .procname = "dir-notify-enable",
27 .data = &dir_notify_enable,
28 .maxlen = sizeof(int),
29 .mode = 0644,
30 .proc_handler = proc_dointvec,
31 },
32 {}
33 };
34 static void __init dnotify_sysctl_init(void)
35 {
> 36 register_sysctl_init("fs", dnotify_sysctls, "dnotify_sysctls");
37 }
38 #else
39 #define dnotify_sysctl_init() do { } while (0)
40 #endif
41
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months
Re: [PATCH 1/3] drm/simpledrm: Bind to OF framebuffers in /chosen
by kernel test robot
Hi Hector,
I love your patch! Yet something to improve:
[auto build test ERROR on drm/drm-next]
[also build test ERROR on v5.16-rc1]
[cannot apply to next-20211118]
[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/Hector-Martin/drm-simpledrm-Appl...
base: git://anongit.freedesktop.org/drm/drm drm-next
config: riscv-randconfig-r035-20211118 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project c46becf500df2a7fb4b4fce16178a036c344315a)
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 riscv cross compiling tool for clang build
# apt-get install binutils-riscv64-linux-gnu
# https://github.com/0day-ci/linux/commit/0be435c1fb3f0722a7099fee532925717...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Hector-Martin/drm-simpledrm-Apple-M1-DT-platform-support-fixes/20211117-230107
git checkout 0be435c1fb3f0722a7099fee532925717a67a42a
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=riscv SHELL=/bin/bash drivers/gpu/drm/tiny/
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/gpu/drm/tiny/simpledrm.c:915:1: error: redefinition of '__inittest'
fs_initcall(simpledrm_init);
^
include/linux/module.h:119:27: note: expanded from macro 'fs_initcall'
#define fs_initcall(fn) module_init(fn)
^
include/linux/module.h:131:42: note: expanded from macro 'module_init'
static inline initcall_t __maybe_unused __inittest(void) \
^
drivers/gpu/drm/tiny/simpledrm.c:899:1: note: previous definition is here
module_platform_driver(simpledrm_platform_driver);
^
include/linux/platform_device.h:252:2: note: expanded from macro 'module_platform_driver'
module_driver(__platform_driver, platform_driver_register, \
^
include/linux/device/driver.h:262:3: note: expanded from macro 'module_driver'
} \
^
include/linux/module.h:131:42: note: expanded from macro '\
module_init'
static inline initcall_t __maybe_unused __inittest(void) \
^
>> drivers/gpu/drm/tiny/simpledrm.c:915:1: error: redefinition of 'init_module'
fs_initcall(simpledrm_init);
^
include/linux/module.h:119:27: note: expanded from macro 'fs_initcall'
#define fs_initcall(fn) module_init(fn)
^
include/linux/module.h:133:6: note: expanded from macro 'module_init'
int init_module(void) __copy(initfn) \
^
drivers/gpu/drm/tiny/simpledrm.c:899:1: note: previous definition is here
module_platform_driver(simpledrm_platform_driver);
^
include/linux/platform_device.h:252:2: note: expanded from macro 'module_platform_driver'
module_driver(__platform_driver, platform_driver_register, \
^
include/linux/device/driver.h:262:3: note: expanded from macro 'module_driver'
} \
^
include/linux/module.h:133:6: note: expanded from macro '\
module_init'
int init_module(void) __copy(initfn) \
^
2 errors generated.
vim +/__inittest +915 drivers/gpu/drm/tiny/simpledrm.c
914
> 915 fs_initcall(simpledrm_init);
916
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months
[intel-lts:5.10/yocto 1/3] sound/soc/intel/common/soc-acpi-intel-tgl-match.c:185:43: warning: unused variable 'tgl_i2s_rt1308'
by kernel test robot
tree: https://github.com/intel/linux-intel-lts.git 5.10/yocto
head: deff0e4b25b3ddd1792dede67243c2f5cce226f2
commit: 877fd5abd34ac2b6abb205f0e8fd194924dec359 [1/3] ASoC: Intel: tgl: add tgl-rt1308 machine driver
config: x86_64-randconfig-r002-20211118 (attached as .config)
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/linux-intel-lts/commit/877fd5abd34ac2b6abb205f0e...
git remote add intel-lts https://github.com/intel/linux-intel-lts.git
git fetch --no-tags intel-lts 5.10/yocto
git checkout 877fd5abd34ac2b6abb205f0e8fd194924dec359
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> sound/soc/intel/common/soc-acpi-intel-tgl-match.c:185:43: warning: unused variable 'tgl_i2s_rt1308' [-Wunused-const-variable]
static const struct snd_soc_acpi_link_adr tgl_i2s_rt1308[] = {
^
1 warning generated.
vim +/tgl_i2s_rt1308 +185 sound/soc/intel/common/soc-acpi-intel-tgl-match.c
44751fc5f0de07 Pierre-Louis Bossart 2020-08-21 184
d985d208bf8f07 Pierre-Louis Bossart 2020-01-10 @185 static const struct snd_soc_acpi_link_adr tgl_i2s_rt1308[] = {
d985d208bf8f07 Pierre-Louis Bossart 2020-01-10 186 {
d985d208bf8f07 Pierre-Louis Bossart 2020-01-10 187 .mask = BIT(0),
d985d208bf8f07 Pierre-Louis Bossart 2020-01-10 188 .num_adr = ARRAY_SIZE(rt711_0_adr),
004bd4163104e4 Pierre-Louis Bossart 2020-03-25 189 .adr_d = rt711_0_adr,
d985d208bf8f07 Pierre-Louis Bossart 2020-01-10 190 },
d985d208bf8f07 Pierre-Louis Bossart 2020-01-10 191 {}
d985d208bf8f07 Pierre-Louis Bossart 2020-01-10 192 };
d985d208bf8f07 Pierre-Louis Bossart 2020-01-10 193
:::::: The code at line 185 was first introduced by commit
:::::: d985d208bf8f079979f284864a6d08900597ee04 ASoC: Intel: common: add match tables for TGL w/ SoundWire
:::::: TO: Pierre-Louis Bossart <pierre-louis.bossart(a)linux.intel.com>
:::::: CC: Mark Brown <broonie(a)kernel.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months
Re: [RFC PATCH 2/4] namespacefs: Add methods to create/remove PID namespace directories
by kernel test robot
Hi "Yordan,
[FYI, it's a private test report for your RFC patch.]
[auto build test WARNING on linux/master]
[also build test WARNING on hnaz-mm/master linus/master v5.16-rc1 next-20211118]
[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/Yordan-Karadzhov-VMware/namespac...
base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 8ab774587903771821b59471cc723bba6d893942
config: m68k-allyesconfig (attached as .config)
compiler: m68k-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/0day-ci/linux/commit/9b9ee11c1c806bd636fd81cd55b93f203...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Yordan-Karadzhov-VMware/namespacefs-Proof-of-Concept/20211119-021813
git checkout 9b9ee11c1c806bd636fd81cd55b93f2034f0d1a0
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=m68k
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
fs/namespacefs/inode.c:161:1: warning: no previous prototype for 'namespacefs_create_file' [-Wmissing-prototypes]
161 | namespacefs_create_file(const char *name, struct dentry *parent,
| ^~~~~~~~~~~~~~~~~~~~~~~
fs/namespacefs/inode.c:170:1: warning: no previous prototype for 'namespacefs_create_dir' [-Wmissing-prototypes]
170 | namespacefs_create_dir(const char *name, struct dentry *parent,
| ^~~~~~~~~~~~~~~~~~~~~~
fs/namespacefs/inode.c:181:6: warning: no previous prototype for 'namespacefs_remove_dir' [-Wmissing-prototypes]
181 | void namespacefs_remove_dir(struct dentry *dentry)
| ^~~~~~~~~~~~~~~~~~~~~~
>> fs/namespacefs/inode.c:286:5: warning: no previous prototype for 'namespacefs_create_pid_ns_dir' [-Wmissing-prototypes]
286 | int namespacefs_create_pid_ns_dir(struct pid_namespace *ns)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> fs/namespacefs/inode.c:305:6: warning: no previous prototype for 'namespacefs_remove_pid_ns_dir' [-Wmissing-prototypes]
305 | void namespacefs_remove_pid_ns_dir(struct pid_namespace *ns)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
vim +/namespacefs_create_pid_ns_dir +286 fs/namespacefs/inode.c
159
160 struct dentry *
> 161 namespacefs_create_file(const char *name, struct dentry *parent,
162 const struct user_namespace *user_ns,
163 const struct file_operations *fops,
164 void *data)
165 {
166 return create(name, parent, user_ns, fops, data);
167 }
168
169 struct dentry *
> 170 namespacefs_create_dir(const char *name, struct dentry *parent,
171 const struct user_namespace *user_ns)
172 {
173 return create(name, parent, user_ns, NULL, NULL);
174 }
175
176 static void remove_one(struct dentry *d)
177 {
178 release_namespacefs();
179 }
180
181 void namespacefs_remove_dir(struct dentry *dentry)
182 {
183 if (IS_ERR_OR_NULL(dentry))
184 return;
185
186 if (pin_fs())
187 return;
188
189 simple_recursive_removal(dentry, remove_one);
190 release_namespacefs();
191 }
192
193 struct idr_seq_context {
194 struct idr *idr;
195 int index;
196 };
197
198 static void *idr_seq_get_next(struct idr_seq_context *idr_ctx, loff_t *pos)
199 {
200 void *next = idr_get_next(idr_ctx->idr, &idr_ctx->index);
201
202 *pos = ++idr_ctx->index;
203 return next;
204 }
205
206 static void *idr_seq_start(struct seq_file *m, loff_t *pos)
207 {
208 struct idr_seq_context *idr_ctx = m->private;
209
210 idr_lock(idr_ctx->idr);
211 idr_ctx->index = *pos;
212 return idr_seq_get_next(idr_ctx, pos);
213 }
214
215 static void *idr_seq_next(struct seq_file *m, void *v, loff_t *pos)
216 {
217 return idr_seq_get_next(m->private, pos);
218 }
219
220 static void idr_seq_stop(struct seq_file *m, void *p)
221 {
222 struct idr_seq_context *idr_ctx = m->private;
223
224 idr_unlock(idr_ctx->idr);
225 }
226
227 static int idr_seq_open(struct file *file, struct idr *idr,
228 const struct seq_operations *ops)
229 {
230 struct idr_seq_context *idr_ctx;
231
232 idr_ctx = __seq_open_private(file, ops, sizeof(*idr_ctx));
233 if (!idr_ctx)
234 return -ENOMEM;
235
236 idr_ctx->idr = idr;
237
238 return 0;
239 }
240
241 static inline int pid_seq_show(struct seq_file *m, void *v)
242 {
243 struct pid *pid = v;
244
245 seq_printf(m, "%d\n", pid_nr(pid));
246 return 0;
247 }
248
249 static const struct seq_operations pid_seq_ops = {
250 .start = idr_seq_start,
251 .next = idr_seq_next,
252 .stop = idr_seq_stop,
253 .show = pid_seq_show,
254 };
255
256 static int pid_seq_open(struct inode *inode, struct file *file)
257 {
258 struct idr *idr = inode->i_private;
259
260 return idr_seq_open(file, idr, &pid_seq_ops);
261 }
262
263 static const struct file_operations tasks_fops = {
264 .open = pid_seq_open,
265 .read = seq_read,
266 .llseek = seq_lseek,
267 .release = seq_release_private,
268 };
269
270 static int create_inode_dir(struct ns_common *ns, struct dentry *parent_dentry,
271 const struct user_namespace *user_ns)
272 {
273 char *dir = kasprintf(GFP_KERNEL, "%u", ns->inum);
274
275 if (!dir)
276 return -ENOMEM;
277
278 ns->dentry = namespacefs_create_dir(dir, parent_dentry, user_ns);
279 kfree(dir);
280 if (IS_ERR(ns->dentry))
281 return PTR_ERR(ns->dentry);
282
283 return 0;
284 }
285
> 286 int namespacefs_create_pid_ns_dir(struct pid_namespace *ns)
287 {
288 struct dentry *dentry;
289 int err;
290
291 err = create_inode_dir(&ns->ns, ns->parent->ns.dentry, ns->user_ns);
292 if (err)
293 return err;
294
295 dentry = namespacefs_create_file("tasks", ns->ns.dentry, ns->user_ns,
296 &tasks_fops, &ns->idr);
297 if (IS_ERR(dentry)) {
298 dput(ns->ns.dentry);
299 return PTR_ERR(dentry);
300 }
301
302 return 0;
303 }
304
> 305 void namespacefs_remove_pid_ns_dir(struct pid_namespace *ns)
306 {
307 namespacefs_remove_dir(ns->ns.dentry);
308 }
309
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months
[android-common:upstream-f2fs-stable-linux-5.4.y 665/676] fs/ubifs/file.c:1644:54: error: too many arguments to function call, expected 4, have 5
by kernel test robot
tree: https://android.googlesource.com/kernel/common upstream-f2fs-stable-linux-5.4.y
head: 0de6dec9da87fd1c8b99ad0643dab94f8a332004
commit: 0e764ea6471e002f101dd7726b6e97f0e55c2288 [665/676] ubifs: report correct st_size for encrypted symlinks
config: x86_64-randconfig-a004-20211118 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project c46becf500df2a7fb4b4fce16178a036c344315a)
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
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common upstream-f2fs-stable-linux-5.4.y
git checkout 0e764ea6471e002f101dd7726b6e97f0e55c2288
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash fs/ubifs/
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 >>):
>> fs/ubifs/file.c:1644:54: error: too many arguments to function call, expected 4, have 5
ubifs_getattr(mnt_userns, path, stat, request_mask, query_flags);
~~~~~~~~~~~~~ ^~~~~~~~~~~
fs/ubifs/ubifs.h:1997:5: note: 'ubifs_getattr' declared here
int ubifs_getattr(const struct path *path, struct kstat *stat,
^
>> fs/ubifs/file.c:1676:17: error: incompatible function pointer types initializing 'int (*)(const struct path *, struct kstat *, u32, unsigned int)' (aka 'int (*)(const struct path *, struct kstat *, unsigned int, unsigned int)') with an expression of type 'int (struct user_namespace *, const struct path *, struct kstat *, u32, unsigned int)' (aka 'int (struct user_namespace *, const struct path *, struct kstat *, unsigned int, unsigned int)') [-Werror,-Wincompatible-function-pointer-types]
.getattr = ubifs_symlink_getattr,
^~~~~~~~~~~~~~~~~~~~~
2 errors generated.
vim +1644 fs/ubifs/file.c
1639
1640 static int ubifs_symlink_getattr(struct user_namespace *mnt_userns,
1641 const struct path *path, struct kstat *stat,
1642 u32 request_mask, unsigned int query_flags)
1643 {
> 1644 ubifs_getattr(mnt_userns, path, stat, request_mask, query_flags);
1645
1646 if (IS_ENCRYPTED(d_inode(path->dentry)))
1647 return fscrypt_symlink_getattr(path, stat);
1648 return 0;
1649 }
1650
1651 const struct address_space_operations ubifs_file_address_operations = {
1652 .readpage = ubifs_readpage,
1653 .writepage = ubifs_writepage,
1654 .write_begin = ubifs_write_begin,
1655 .write_end = ubifs_write_end,
1656 .invalidatepage = ubifs_invalidatepage,
1657 .set_page_dirty = ubifs_set_page_dirty,
1658 #ifdef CONFIG_MIGRATION
1659 .migratepage = ubifs_migrate_page,
1660 #endif
1661 .releasepage = ubifs_releasepage,
1662 };
1663
1664 const struct inode_operations ubifs_file_inode_operations = {
1665 .setattr = ubifs_setattr,
1666 .getattr = ubifs_getattr,
1667 #ifdef CONFIG_UBIFS_FS_XATTR
1668 .listxattr = ubifs_listxattr,
1669 #endif
1670 .update_time = ubifs_update_time,
1671 };
1672
1673 const struct inode_operations ubifs_symlink_inode_operations = {
1674 .get_link = ubifs_get_link,
1675 .setattr = ubifs_setattr,
> 1676 .getattr = ubifs_symlink_getattr,
1677 #ifdef CONFIG_UBIFS_FS_XATTR
1678 .listxattr = ubifs_listxattr,
1679 #endif
1680 .update_time = ubifs_update_time,
1681 };
1682
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c:1647 init_dma_rx_desc_rings() warn: always true condition '(queue >= 0) => (0-u32max >= 0)'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 6fdf886424cf8c4fff96a20189c00606327e5df6
commit: de0b90e52a116a951ca8b13c924c359d5fc39fa0 net: stmmac: rearrange RX and TX desc init into per-queue basis
date: 7 months ago
config: arm-randconfig-m031-20211116 (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 11.2.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
New smatch warnings:
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c:1647 init_dma_rx_desc_rings() warn: always true condition '(queue >= 0) => (0-u32max >= 0)'
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c:1647 init_dma_rx_desc_rings() warn: always true condition '(queue >= 0) => (0-u32max >= 0)'
Old smatch warnings:
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c:1567 stmmac_reinit_rx_buffers() warn: always true condition '(queue >= 0) => (0-u32max >= 0)'
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c:1567 stmmac_reinit_rx_buffers() warn: always true condition '(queue >= 0) => (0-u32max >= 0)'
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c:4453 stmmac_xdp_run_prog() error: (-2147483647) too low for ERR_PTR
vim +1647 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1626
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1627 static int init_dma_rx_desc_rings(struct net_device *dev, gfp_t flags)
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1628 {
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1629 struct stmmac_priv *priv = netdev_priv(dev);
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1630 u32 rx_count = priv->plat->rx_queues_to_use;
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1631 u32 queue;
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1632 int ret;
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1633
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1634 /* RX INITIALIZATION */
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1635 netif_dbg(priv, probe, priv->dev,
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1636 "SKB addresses:\nskb\t\tskb data\tdma data\n");
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1637
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1638 for (queue = 0; queue < rx_count; queue++) {
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1639 ret = __init_dma_rx_desc_rings(priv, queue, flags);
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1640 if (ret)
de0b90e52a116a9 Ong Boon Leong 2021-04-13 1641 goto err_init_rx_buffers;
54139cf3bb33fad Joao Pinto 2017-04-06 1642 }
54139cf3bb33fad Joao Pinto 2017-04-06 1643
71fedb0198cbbda Joao Pinto 2017-04-06 1644 return 0;
54139cf3bb33fad Joao Pinto 2017-04-06 1645
71fedb0198cbbda Joao Pinto 2017-04-06 1646 err_init_rx_buffers:
54139cf3bb33fad Joao Pinto 2017-04-06 @1647 while (queue >= 0) {
4298255f26fa91c Ong Boon Leong 2021-04-13 1648 dma_free_rx_skbufs(priv, queue);
54139cf3bb33fad Joao Pinto 2017-04-06 1649
54139cf3bb33fad Joao Pinto 2017-04-06 1650 if (queue == 0)
54139cf3bb33fad Joao Pinto 2017-04-06 1651 break;
54139cf3bb33fad Joao Pinto 2017-04-06 1652
54139cf3bb33fad Joao Pinto 2017-04-06 1653 queue--;
54139cf3bb33fad Joao Pinto 2017-04-06 1654 }
54139cf3bb33fad Joao Pinto 2017-04-06 1655
71fedb0198cbbda Joao Pinto 2017-04-06 1656 return ret;
71fedb0198cbbda Joao Pinto 2017-04-06 1657 }
71fedb0198cbbda Joao Pinto 2017-04-06 1658
:::::: The code at line 1647 was first introduced by commit
:::::: 54139cf3bb33fad075737000f22749cafe3e83a0 net: stmmac: adding multiple buffers for rx
:::::: TO: Joao Pinto <Joao.Pinto(a)synopsys.com>
:::::: CC: David S. Miller <davem(a)davemloft.net>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months
Re: [PATCH v10 3/5] iio: adc: Add Xilinx AMS driver
by kernel test robot
Hi Anand,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on jic23-iio/togreg]
[also build test ERROR on linux/master linus/master v5.16-rc1 next-20211118]
[cannot apply to xilinx-xlnx/master]
[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/Anand-Ashok-Dumbre/Add-Xilinx-AM...
base: https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git togreg
config: arc-randconfig-r035-20211118 (attached as .config)
compiler: arceb-elf-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/0day-ci/linux/commit/196a4a5b4232a4a12d0843a0002b66472...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Anand-Ashok-Dumbre/Add-Xilinx-AMS-Driver/20211118-001150
git checkout 196a4a5b4232a4a12d0843a0002b664720b5d200
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=arc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All error/warnings (new ones prefixed by >>):
drivers/iio/adc/xilinx-ams.c: In function 'ams_update_intrmask':
>> drivers/iio/adc/xilinx-ams.c:323:20: error: implicit declaration of function 'FIELD_GET' [-Werror=implicit-function-declaration]
323 | regval = ~(FIELD_GET(AMS_ISR1_INTR_MASK, ams->intr_mask));
| ^~~~~~~~~
In file included from drivers/iio/adc/xilinx-ams.c:11:
>> include/linux/bits.h:35:29: warning: left shift count >= width of type [-Wshift-count-overflow]
35 | (((~UL(0)) - (UL(1) << (l)) + 1) & \
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:131:41: note: in expansion of macro 'GENMASK'
131 | #define AMS_ISR1_INTR_MASK GENMASK(63, 32)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:323:30: note: in expansion of macro 'AMS_ISR1_INTR_MASK'
323 | regval = ~(FIELD_GET(AMS_ISR1_INTR_MASK, ams->intr_mask));
| ^~~~~~~~~~~~~~~~~~
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:131:41: note: in expansion of macro 'GENMASK'
131 | #define AMS_ISR1_INTR_MASK GENMASK(63, 32)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:323:30: note: in expansion of macro 'AMS_ISR1_INTR_MASK'
323 | regval = ~(FIELD_GET(AMS_ISR1_INTR_MASK, ams->intr_mask));
| ^~~~~~~~~~~~~~~~~~
>> include/linux/bits.h:35:29: warning: left shift count >= width of type [-Wshift-count-overflow]
35 | (((~UL(0)) - (UL(1) << (l)) + 1) & \
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:131:41: note: in expansion of macro 'GENMASK'
131 | #define AMS_ISR1_INTR_MASK GENMASK(63, 32)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:329:28: note: in expansion of macro 'AMS_ISR1_INTR_MASK'
329 | regval = FIELD_GET(AMS_ISR1_INTR_MASK, ams->intr_mask);
| ^~~~~~~~~~~~~~~~~~
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:131:41: note: in expansion of macro 'GENMASK'
131 | #define AMS_ISR1_INTR_MASK GENMASK(63, 32)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:329:28: note: in expansion of macro 'AMS_ISR1_INTR_MASK'
329 | regval = FIELD_GET(AMS_ISR1_INTR_MASK, ams->intr_mask);
| ^~~~~~~~~~~~~~~~~~
drivers/iio/adc/xilinx-ams.c: In function 'ams_update_ps_alarm':
>> drivers/iio/adc/xilinx-ams.c:360:17: error: implicit declaration of function 'FIELD_PREP' [-Werror=implicit-function-declaration]
360 | cfg = ~(FIELD_PREP(AMS_CONF1_ALARM_2_TO_0_MASK, val));
| ^~~~~~~~~~
In file included from drivers/iio/adc/xilinx-ams.c:11:
drivers/iio/adc/xilinx-ams.c: In function 'ams_enable_channel_sequence':
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:102:41: note: in expansion of macro 'GENMASK'
102 | #define AMS_PL_SEQ_MASK GENMASK(59, 22)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:448:39: note: in expansion of macro 'AMS_PL_SEQ_MASK'
448 | scan_mask = FIELD_GET(AMS_PL_SEQ_MASK, scan_mask);
| ^~~~~~~~~~~~~~~
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:99:41: note: in expansion of macro 'GENMASK'
99 | #define AMS_REG_SEQ1_MASK GENMASK(37, 22)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:453:36: note: in expansion of macro 'AMS_REG_SEQ1_MASK'
453 | regval = FIELD_GET(AMS_REG_SEQ1_MASK, scan_mask);
| ^~~~~~~~~~~~~~~~~
drivers/iio/adc/xilinx-ams.c: In function 'ams_init_device':
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:124:41: note: in expansion of macro 'GENMASK'
124 | #define AMS_ALARM_MASK GENMASK(63, 0)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:501:34: note: in expansion of macro 'AMS_ALARM_MASK'
501 | ams_update_intrmask(ams, AMS_ALARM_MASK, AMS_ALARM_MASK);
| ^~~~~~~~~~~~~~
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:124:41: note: in expansion of macro 'GENMASK'
124 | #define AMS_ALARM_MASK GENMASK(63, 0)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:501:50: note: in expansion of macro 'AMS_ALARM_MASK'
501 | ams_update_intrmask(ams, AMS_ALARM_MASK, AMS_ALARM_MASK);
| ^~~~~~~~~~~~~~
drivers/iio/adc/xilinx-ams.c: In function 'ams_unmask_worker':
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:124:41: note: in expansion of macro 'GENMASK'
124 | #define AMS_ALARM_MASK GENMASK(63, 0)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:1017:35: note: in expansion of macro 'AMS_ALARM_MASK'
1017 | ams_update_intrmask(ams, ~AMS_ALARM_MASK, ~AMS_ALARM_MASK);
| ^~~~~~~~~~~~~~
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:124:41: note: in expansion of macro 'GENMASK'
124 | #define AMS_ALARM_MASK GENMASK(63, 0)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:1017:52: note: in expansion of macro 'AMS_ALARM_MASK'
1017 | ams_update_intrmask(ams, ~AMS_ALARM_MASK, ~AMS_ALARM_MASK);
| ^~~~~~~~~~~~~~
drivers/iio/adc/xilinx-ams.c: In function 'ams_irq':
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:124:41: note: in expansion of macro 'GENMASK'
124 | #define AMS_ALARM_MASK GENMASK(63, 0)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:1049:35: note: in expansion of macro 'AMS_ALARM_MASK'
1049 | ams_update_intrmask(ams, ~AMS_ALARM_MASK, ~AMS_ALARM_MASK);
| ^~~~~~~~~~~~~~
>> include/linux/bits.h:36:18: warning: right shift count is negative [-Wshift-count-negative]
36 | (~UL(0) >> (BITS_PER_LONG - 1 - (h))))
| ^~
include/linux/bits.h:38:38: note: in expansion of macro '__GENMASK'
38 | (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l))
| ^~~~~~~~~
drivers/iio/adc/xilinx-ams.c:124:41: note: in expansion of macro 'GENMASK'
124 | #define AMS_ALARM_MASK GENMASK(63, 0)
| ^~~~~~~
drivers/iio/adc/xilinx-ams.c:1049:52: note: in expansion of macro 'AMS_ALARM_MASK'
1049 | ams_update_intrmask(ams, ~AMS_ALARM_MASK, ~AMS_ALARM_MASK);
| ^~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +/FIELD_GET +323 drivers/iio/adc/xilinx-ams.c
313
314 static void ams_update_intrmask(struct ams *ams, u64 mask, u64 val)
315 {
316 u32 regval;
317
318 ams->intr_mask = (ams->intr_mask & ~mask) | (val & mask);
319
320 regval = ~(ams->intr_mask | ams->masked_alarm);
321 writel(regval, ams->base + AMS_IER_0);
322
> 323 regval = ~(FIELD_GET(AMS_ISR1_INTR_MASK, ams->intr_mask));
324 writel(regval, ams->base + AMS_IER_1);
325
326 regval = ams->intr_mask | ams->masked_alarm;
327 writel(regval, ams->base + AMS_IDR_0);
328
329 regval = FIELD_GET(AMS_ISR1_INTR_MASK, ams->intr_mask);
330 writel(regval, ams->base + AMS_IDR_1);
331 }
332
333 static void ams_disable_all_alarms(struct ams *ams)
334 {
335 /* disable PS module alarm */
336 if (ams->ps_base) {
337 ams_ps_update_reg(ams, AMS_REG_CONFIG1, AMS_REGCFG1_ALARM_MASK,
338 AMS_REGCFG1_ALARM_MASK);
339 ams_ps_update_reg(ams, AMS_REG_CONFIG3, AMS_REGCFG3_ALARM_MASK,
340 AMS_REGCFG3_ALARM_MASK);
341 }
342
343 /* disable PL module alarm */
344 if (ams->pl_base) {
345 ams_pl_update_reg(ams, AMS_REG_CONFIG1,
346 AMS_REGCFG1_ALARM_MASK,
347 AMS_REGCFG1_ALARM_MASK);
348 ams_pl_update_reg(ams, AMS_REG_CONFIG3,
349 AMS_REGCFG3_ALARM_MASK,
350 AMS_REGCFG3_ALARM_MASK);
351 }
352 }
353
354 static void ams_update_ps_alarm(struct ams *ams, unsigned long alarm_mask)
355 {
356 u32 cfg;
357 u32 val;
358
359 val = FIELD_GET(AMS_ISR0_ALARM_2_TO_0_MASK, alarm_mask);
> 360 cfg = ~(FIELD_PREP(AMS_CONF1_ALARM_2_TO_0_MASK, val));
361
362 val = FIELD_GET(AMS_ISR0_ALARM_6_TO_3_MASK, alarm_mask);
363 cfg &= ~(FIELD_PREP(AMS_CONF1_ALARM_6_TO_3_MASK, val));
364
365 ams_ps_update_reg(ams, AMS_REG_CONFIG1, AMS_REGCFG1_ALARM_MASK, cfg);
366
367 val = FIELD_GET(AMS_ISR0_ALARM_12_TO_7_MASK, alarm_mask);
368 cfg = ~(FIELD_PREP(AMS_CONF1_ALARM_12_TO_7_MASK, val));
369 ams_ps_update_reg(ams, AMS_REG_CONFIG3, AMS_REGCFG3_ALARM_MASK, cfg);
370 }
371
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months
[agd5f:drm-next 51/92] drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c:1335:6: warning: no previous prototype for function 'amdgpu_amdkfd_gpuvm_unpin_bo'
by kernel test robot
tree: https://gitlab.freedesktop.org/agd5f/linux.git drm-next
head: eaae0714f4a82df81a60c6aae74c568e8974a716
commit: f140fc51a32ef8637b522a880b8f9f14683ce8df [51/92] drm/amdgpu: Pin MMIO/DOORBELL BO's in GTT domain
config: x86_64-randconfig-r001-20211118 (attached as .config)
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
git remote add agd5f https://gitlab.freedesktop.org/agd5f/linux.git
git fetch --no-tags agd5f drm-next
git checkout f140fc51a32ef8637b522a880b8f9f14683ce8df
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c:1335:6: warning: no previous prototype for function 'amdgpu_amdkfd_gpuvm_unpin_bo' [-Wmissing-prototypes]
void amdgpu_amdkfd_gpuvm_unpin_bo(struct amdgpu_bo *bo)
^
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c:1335:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
void amdgpu_amdkfd_gpuvm_unpin_bo(struct amdgpu_bo *bo)
^
static
1 warning generated.
vim +/amdgpu_amdkfd_gpuvm_unpin_bo +1335 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c
1326
1327 /**
1328 * amdgpu_amdkfd_gpuvm_unpin_bo() - Unpins BO using following criteria
1329 * @bo: Handle of buffer object being unpinned
1330 *
1331 * - Is a illegal request for USERPTR BOs and is ignored
1332 * - All other BO types (GTT, VRAM, MMIO and DOORBELL) will have their
1333 * PIN count decremented. Calls to UNPIN must balance calls to PIN
1334 */
> 1335 void amdgpu_amdkfd_gpuvm_unpin_bo(struct amdgpu_bo *bo)
1336 {
1337 int ret = 0;
1338
1339 ret = amdgpu_bo_reserve(bo, false);
1340 if (unlikely(ret))
1341 return;
1342
1343 amdgpu_bo_unpin(bo);
1344 amdgpu_bo_unreserve(bo);
1345 }
1346
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months
Re: [PATCH v3 12/13] drm/msm/dsi: Add support for DSC configuration
by kernel test robot
Hi Vinod,
I love your patch! Perhaps something to improve:
[auto build test WARNING on drm/drm-next]
[also build test WARNING on v5.16-rc1 next-20211118]
[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/Vinod-Koul/drm-msm-Add-Display-S...
base: git://anongit.freedesktop.org/drm/drm drm-next
config: arm64-randconfig-r036-20211118 (attached as .config)
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 arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://github.com/0day-ci/linux/commit/0d90631d88b4295b0612892e62110dd3b...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Vinod-Koul/drm-msm-Add-Display-Stream-Compression-Support/20211116-142602
git checkout 0d90631d88b4295b0612892e62110dd3b11c9d78
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> drivers/gpu/drm/msm/dsi/dsi_host.c:1039:13: warning: variable 'reg_ctrl' set but not used [-Wunused-but-set-variable]
u32 reg, reg_ctrl, reg_ctrl2;
^
1 warning generated.
vim +/reg_ctrl +1039 drivers/gpu/drm/msm/dsi/dsi_host.c
924
925 static void dsi_timing_setup(struct msm_dsi_host *msm_host, bool is_bonded_dsi)
926 {
927 struct drm_display_mode *mode = msm_host->mode;
928 u32 hs_start = 0, vs_start = 0; /* take sync start as 0 */
929 u32 h_total = mode->htotal;
930 u32 v_total = mode->vtotal;
931 u32 hs_end = mode->hsync_end - mode->hsync_start;
932 u32 vs_end = mode->vsync_end - mode->vsync_start;
933 u32 ha_start = h_total - mode->hsync_start;
934 u32 ha_end = ha_start + mode->hdisplay;
935 u32 va_start = v_total - mode->vsync_start;
936 u32 va_end = va_start + mode->vdisplay;
937 u32 hdisplay = mode->hdisplay;
938 u32 wc;
939
940 DBG("");
941
942 /*
943 * For bonded DSI mode, the current DRM mode has
944 * the complete width of the panel. Since, the complete
945 * panel is driven by two DSI controllers, the horizontal
946 * timings have to be split between the two dsi controllers.
947 * Adjust the DSI host timing values accordingly.
948 */
949 if (is_bonded_dsi) {
950 h_total /= 2;
951 hs_end /= 2;
952 ha_start /= 2;
953 ha_end /= 2;
954 hdisplay /= 2;
955 }
956
957 if (msm_host->dsc) {
958 struct msm_display_dsc_config *dsc = msm_host->dsc;
959
960 /* update dsc params with timing params */
961 dsi_dsc_update_pic_dim(dsc, mode->hdisplay, mode->vdisplay);
962 DBG("Mode Width- %d x Height %d\n", dsc->drm->pic_width, dsc->drm->pic_height);
963
964 /* we do the calculations for dsc parameters here so that
965 * panel can use these parameters
966 */
967 dsi_populate_dsc_params(dsc);
968
969 /* Divide the display by 3 but keep back/font porch and
970 * pulse width same
971 */
972 h_total -= hdisplay;
973 hdisplay /= 3;
974 h_total += hdisplay;
975 ha_end = ha_start + hdisplay;
976 }
977
978 if (msm_host->mode_flags & MIPI_DSI_MODE_VIDEO) {
979 if (msm_host->dsc) {
980 struct msm_display_dsc_config *dsc = msm_host->dsc;
981 u32 reg, intf_width, slice_per_intf;
982 u32 total_bytes_per_intf;
983
984 /* first calculate dsc parameters and then program
985 * compress mode registers
986 */
987 intf_width = hdisplay;
988 slice_per_intf = DIV_ROUND_UP(intf_width, dsc->drm->slice_width);
989
990 dsc->drm->slice_count = 1;
991 dsc->bytes_in_slice = DIV_ROUND_UP(dsc->drm->slice_width * 8, 8);
992 total_bytes_per_intf = dsc->bytes_in_slice * slice_per_intf;
993
994 dsc->eol_byte_num = total_bytes_per_intf % 3;
995 dsc->pclk_per_line = DIV_ROUND_UP(total_bytes_per_intf, 3);
996 dsc->bytes_per_pkt = dsc->bytes_in_slice * dsc->drm->slice_count;
997 dsc->pkt_per_line = slice_per_intf / dsc->drm->slice_count;
998
999 reg = dsc->bytes_per_pkt << 16;
1000 reg |= (0x0b << 8); /* dtype of compressed image */
1001
1002 /* pkt_per_line:
1003 * 0 == 1 pkt
1004 * 1 == 2 pkt
1005 * 2 == 4 pkt
1006 * 3 pkt is not supported
1007 * above translates to ffs() - 1
1008 */
1009 reg |= (ffs(dsc->pkt_per_line) - 1) << 6;
1010
1011 dsc->eol_byte_num = total_bytes_per_intf % 3;
1012 reg |= dsc->eol_byte_num << 4;
1013 reg |= 1;
1014
1015 dsi_write(msm_host,
1016 REG_DSI_VIDEO_COMPRESSION_MODE_CTRL, reg);
1017 }
1018
1019 dsi_write(msm_host, REG_DSI_ACTIVE_H,
1020 DSI_ACTIVE_H_START(ha_start) |
1021 DSI_ACTIVE_H_END(ha_end));
1022 dsi_write(msm_host, REG_DSI_ACTIVE_V,
1023 DSI_ACTIVE_V_START(va_start) |
1024 DSI_ACTIVE_V_END(va_end));
1025 dsi_write(msm_host, REG_DSI_TOTAL,
1026 DSI_TOTAL_H_TOTAL(h_total - 1) |
1027 DSI_TOTAL_V_TOTAL(v_total - 1));
1028
1029 dsi_write(msm_host, REG_DSI_ACTIVE_HSYNC,
1030 DSI_ACTIVE_HSYNC_START(hs_start) |
1031 DSI_ACTIVE_HSYNC_END(hs_end));
1032 dsi_write(msm_host, REG_DSI_ACTIVE_VSYNC_HPOS, 0);
1033 dsi_write(msm_host, REG_DSI_ACTIVE_VSYNC_VPOS,
1034 DSI_ACTIVE_VSYNC_VPOS_START(vs_start) |
1035 DSI_ACTIVE_VSYNC_VPOS_END(vs_end));
1036 } else { /* command mode */
1037 if (msm_host->dsc) {
1038 struct msm_display_dsc_config *dsc = msm_host->dsc;
> 1039 u32 reg, reg_ctrl, reg_ctrl2;
1040 u32 slice_per_intf, bytes_in_slice, total_bytes_per_intf;
1041
1042 reg_ctrl = dsi_read(msm_host, REG_DSI_COMMAND_COMPRESSION_MODE_CTRL);
1043 reg_ctrl2 = dsi_read(msm_host, REG_DSI_COMMAND_COMPRESSION_MODE_CTRL2);
1044
1045 slice_per_intf = DIV_ROUND_UP(hdisplay, dsc->drm->slice_width);
1046 bytes_in_slice = DIV_ROUND_UP(dsc->drm->slice_width *
1047 dsc->drm->bits_per_pixel, 8);
1048 dsc->drm->slice_chunk_size = bytes_in_slice;
1049 total_bytes_per_intf = dsc->bytes_in_slice * slice_per_intf;
1050 dsc->pkt_per_line = slice_per_intf / dsc->drm->slice_count;
1051
1052 reg = 0x39 << 8;
1053 reg |= ffs(dsc->pkt_per_line) << 6;
1054
1055 dsc->eol_byte_num = total_bytes_per_intf % 3;
1056 reg |= dsc->eol_byte_num << 4;
1057 reg |= 1;
1058
1059 reg_ctrl |= reg;
1060 reg_ctrl2 |= bytes_in_slice;
1061
1062 dsi_write(msm_host, REG_DSI_COMMAND_COMPRESSION_MODE_CTRL, reg);
1063 dsi_write(msm_host, REG_DSI_COMMAND_COMPRESSION_MODE_CTRL2, reg_ctrl2);
1064 }
1065
1066 /* image data and 1 byte write_memory_start cmd */
1067 if (!msm_host->dsc)
1068 wc = hdisplay * dsi_get_bpp(msm_host->format) / 8 + 1;
1069 else
1070 wc = mode->hdisplay / 2 + 1;
1071
1072 dsi_write(msm_host, REG_DSI_CMD_MDP_STREAM0_CTRL,
1073 DSI_CMD_MDP_STREAM0_CTRL_WORD_COUNT(wc) |
1074 DSI_CMD_MDP_STREAM0_CTRL_VIRTUAL_CHANNEL(
1075 msm_host->channel) |
1076 DSI_CMD_MDP_STREAM0_CTRL_DATA_TYPE(
1077 MIPI_DSI_DCS_LONG_WRITE));
1078
1079 dsi_write(msm_host, REG_DSI_CMD_MDP_STREAM0_TOTAL,
1080 DSI_CMD_MDP_STREAM0_TOTAL_H_TOTAL(hdisplay) |
1081 DSI_CMD_MDP_STREAM0_TOTAL_V_TOTAL(mode->vdisplay));
1082 }
1083 }
1084
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
10 months