[jirislaby:devel 95/100] drivers/video/fbdev/vga16fb.c:1324:29: sparse: sparse: incorrect type in assignment (different address spaces)
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jirislaby/linux.git devel
head: 61fbd3f9b3f46a50216cc58557ed831d7a686734
commit: bdfc30fb2d3db4193174ba05ce6d078d8b5ce75c [95/100] make VGA_MAP_MEM return pointer
config: powerpc-randconfig-s031-20210301 (attached as .config)
compiler: powerpc-linux-gcc (GCC) 9.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.3-241-geaceeafa-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/jirislaby/linux.git/commi...
git remote add jirislaby https://git.kernel.org/pub/scm/linux/kernel/git/jirislaby/linux.git
git fetch --no-tags jirislaby devel
git checkout bdfc30fb2d3db4193174ba05ce6d078d8b5ce75c
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=powerpc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
"sparse warnings: (new ones prefixed by >>)"
>> drivers/video/fbdev/vga16fb.c:1324:29: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected char *screen_buffer @@ got void [noderef] __iomem * @@
drivers/video/fbdev/vga16fb.c:1324:29: sparse: expected char *screen_buffer
drivers/video/fbdev/vga16fb.c:1324:29: sparse: got void [noderef] __iomem *
vim +1324 drivers/video/fbdev/vga16fb.c
1302
1303 static int vga16fb_probe(struct platform_device *dev)
1304 {
1305 struct fb_info *info;
1306 struct vga16fb_par *par;
1307 int i;
1308 int ret = 0;
1309
1310 printk(KERN_DEBUG "vga16fb: initializing\n");
1311 info = framebuffer_alloc(sizeof(struct vga16fb_par), &dev->dev);
1312
1313 if (!info) {
1314 ret = -ENOMEM;
1315 goto err_fb_alloc;
1316 }
1317 info->apertures = alloc_apertures(1);
1318 if (!info->apertures) {
1319 ret = -ENOMEM;
1320 goto err_ioremap;
1321 }
1322
1323 /* XXX share VGA_FB_PHYS and I/O region with vgacon and others */
> 1324 info->screen_buffer = VGA_MAP_MEM(VGA_FB_PHYS, 0);
1325
1326 if (!info->screen_base) {
1327 printk(KERN_ERR "vga16fb: unable to map device\n");
1328 ret = -ENOMEM;
1329 goto err_ioremap;
1330 }
1331
1332 printk(KERN_INFO "vga16fb: mapped to 0x%p\n", info->screen_base);
1333 par = info->par;
1334
1335 par->isVGA = screen_info.orig_video_isVGA;
1336 par->palette_blanked = 0;
1337 par->vesa_blanked = 0;
1338
1339 i = par->isVGA? 6 : 2;
1340
1341 vga16fb_defined.red.length = i;
1342 vga16fb_defined.green.length = i;
1343 vga16fb_defined.blue.length = i;
1344
1345 /* name should not depend on EGA/VGA */
1346 info->fbops = &vga16fb_ops;
1347 info->var = vga16fb_defined;
1348 info->fix = vga16fb_fix;
1349 /* supports rectangles with widths of multiples of 8 */
1350 info->pixmap.blit_x = 1 << 7 | 1 << 15 | 1 << 23 | 1 << 31;
1351 info->flags = FBINFO_FLAG_DEFAULT | FBINFO_MISC_FIRMWARE |
1352 FBINFO_HWACCEL_YPAN;
1353
1354 i = (info->var.bits_per_pixel == 8) ? 256 : 16;
1355 ret = fb_alloc_cmap(&info->cmap, i, 0);
1356 if (ret) {
1357 printk(KERN_ERR "vga16fb: unable to allocate colormap\n");
1358 ret = -ENOMEM;
1359 goto err_alloc_cmap;
1360 }
1361
1362 if (vga16fb_check_var(&info->var, info)) {
1363 printk(KERN_ERR "vga16fb: unable to validate variable\n");
1364 ret = -EINVAL;
1365 goto err_check_var;
1366 }
1367
1368 vga16fb_update_fix(info);
1369
1370 info->apertures->ranges[0].base = VGA_FB_PHYS;
1371 info->apertures->ranges[0].size = VGA_FB_PHYS_LEN;
1372
1373 if (register_framebuffer(info) < 0) {
1374 printk(KERN_ERR "vga16fb: unable to register framebuffer\n");
1375 ret = -EINVAL;
1376 goto err_check_var;
1377 }
1378
1379 fb_info(info, "%s frame buffer device\n", info->fix.id);
1380 platform_set_drvdata(dev, info);
1381
1382 return 0;
1383
1384 err_check_var:
1385 fb_dealloc_cmap(&info->cmap);
1386 err_alloc_cmap:
1387 iounmap(info->screen_base);
1388 err_ioremap:
1389 framebuffer_release(info);
1390 err_fb_alloc:
1391 return ret;
1392 }
1393
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 3 months
drivers/net/ethernet/aquantia/atlantic/aq_ring.c:80:21: warning: taking address of packed member '' of class or structure 'aq_ring_buff_s' may result in an unaligned pointer value
by kernel test robot
Hi Léo,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
commit: 9b22fece786ed641909988da4810bfa8e5d2e592 atlantic: remove architecture depends
date: 9 weeks ago
config: mips-randconfig-r011-20210301 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project b077d82b00d81934c7c27ac89dd8b0e7f448bded)
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 mips cross compiling tool for clang build
# apt-get install binutils-mips-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 9b22fece786ed641909988da4810bfa8e5d2e592
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=mips
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 >>):
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.h:13:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:17:
In file included from include/linux/bvec.h:14:
In file included from include/linux/mm.h:10:
In file included from include/linux/gfp.h:6:
In file included from include/linux/mmzone.h:8:
In file included from include/linux/spinlock.h:59:
In file included from include/linux/lockdep.h:27:
include/linux/debug_locks.h:17:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
return xchg(&debug_locks, 0);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.h:13:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:17:
In file included from include/linux/bvec.h:14:
In file included from include/linux/mm.h:33:
In file included from include/linux/pgtable.h:6:
arch/mips/include/asm/pgtable.h:202:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
cmpxchg64(&buddy->pte, 0, _PAGE_GLOBAL);
^
arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
cmpxchg((ptr), (o), (n)); \
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.h:13:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:17:
In file included from include/linux/bvec.h:14:
In file included from include/linux/mm.h:33:
In file included from include/linux/pgtable.h:6:
arch/mips/include/asm/pgtable.h:202:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
cmpxchg((ptr), (o), (n)); \
^
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.h:13:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:28:
In file included from include/net/checksum.h:22:
arch/mips/include/asm/checksum.h:161:9: error: unsupported inline asm: input with type 'unsigned long' matching output with type '__wsum' (aka 'unsigned int')
: "0" ((__force unsigned long)daddr),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.h:13:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:21:
include/linux/netdevice.h:560:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
} while (cmpxchg(&n->state, val, new) != val);
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_ring.h:13:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:21:
include/linux/netdevice.h:560:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
>> drivers/net/ethernet/aquantia/atlantic/aq_ring.c:80:21: warning: taking address of packed member '' of class or structure 'aq_ring_buff_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
aq_free_rxpage(&rxbuf->rxdata,
^~~~~~~~~~~~~
drivers/net/ethernet/aquantia/atlantic/aq_ring.c:95:24: warning: taking address of packed member '' of class or structure 'aq_ring_buff_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
ret = aq_get_rxpage(&rxbuf->rxdata, order,
^~~~~~~~~~~~~
drivers/net/ethernet/aquantia/atlantic/aq_ring.c:427:23: warning: taking address of packed member '' of class or structure 'aq_ring_buff_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
aq_buf_vaddr(&buff->rxdata),
^~~~~~~~~~~~
drivers/net/ethernet/aquantia/atlantic/aq_ring.c:433:23: warning: taking address of packed member '' of class or structure 'aq_ring_buff_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
aq_buf_vaddr(&buff->rxdata),
^~~~~~~~~~~~
drivers/net/ethernet/aquantia/atlantic/aq_ring.c:436:49: warning: taking address of packed member '' of class or structure 'aq_ring_buff_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
memcpy(__skb_put(skb, hdr_len), aq_buf_vaddr(&buff->rxdata),
^~~~~~~~~~~~
drivers/net/ethernet/aquantia/atlantic/aq_ring.c:543:28: warning: taking address of packed member '' of class or structure 'aq_ring_buff_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
buff->pa = aq_buf_daddr(&buff->rxdata);
^~~~~~~~~~~~
drivers/net/ethernet/aquantia/atlantic/aq_ring.c:560:19: warning: taking address of packed member '' of class or structure 'aq_ring_buff_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
aq_free_rxpage(&buff->rxdata, aq_nic_get_dev(self->aq_nic));
^~~~~~~~~~~~
21 warnings and 1 error generated.
--
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/../aq_hw.h:15:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:17:
In file included from include/linux/bvec.h:14:
In file included from include/linux/mm.h:10:
In file included from include/linux/gfp.h:6:
In file included from include/linux/mmzone.h:8:
In file included from include/linux/spinlock.h:59:
In file included from include/linux/lockdep.h:27:
include/linux/debug_locks.h:17:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
return xchg(&debug_locks, 0);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/../aq_hw.h:15:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:17:
In file included from include/linux/bvec.h:14:
In file included from include/linux/mm.h:33:
In file included from include/linux/pgtable.h:6:
arch/mips/include/asm/pgtable.h:202:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
cmpxchg64(&buddy->pte, 0, _PAGE_GLOBAL);
^
arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
cmpxchg((ptr), (o), (n)); \
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/../aq_hw.h:15:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:17:
In file included from include/linux/bvec.h:14:
In file included from include/linux/mm.h:33:
In file included from include/linux/pgtable.h:6:
arch/mips/include/asm/pgtable.h:202:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
cmpxchg((ptr), (o), (n)); \
^
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/../aq_hw.h:15:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:28:
In file included from include/net/checksum.h:22:
arch/mips/include/asm/checksum.h:161:9: error: unsupported inline asm: input with type 'unsigned long' matching output with type '__wsum' (aka 'unsigned int')
: "0" ((__force unsigned long)daddr),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/../aq_hw.h:15:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:21:
include/linux/netdevice.h:560:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
} while (cmpxchg(&n->state, val, new) != val);
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:10:
In file included from drivers/net/ethernet/aquantia/atlantic/hw_atl/../aq_hw.h:15:
In file included from drivers/net/ethernet/aquantia/atlantic/aq_common.h:13:
In file included from include/linux/etherdevice.h:21:
include/linux/netdevice.h:560:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
>> drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:1323:7: warning: taking address of packed member 'ns_mac' of class or structure 'hw_fw_request_ptp_adj_freq' may result in an unaligned pointer value [-Waddress-of-packed-member]
&fwreq.ptp_adj_freq.ns_mac,
^~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:1324:7: warning: taking address of packed member 'fns_mac' of class or structure 'hw_fw_request_ptp_adj_freq' may result in an unaligned pointer value [-Waddress-of-packed-member]
&fwreq.ptp_adj_freq.fns_mac);
^~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:1326:7: warning: taking address of packed member 'ns_phy' of class or structure 'hw_fw_request_ptp_adj_freq' may result in an unaligned pointer value [-Waddress-of-packed-member]
&fwreq.ptp_adj_freq.ns_phy,
^~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_b0.c:1327:7: warning: taking address of packed member 'fns_phy' of class or structure 'hw_fw_request_ptp_adj_freq' may result in an unaligned pointer value [-Waddress-of-packed-member]
&fwreq.ptp_adj_freq.fns_phy);
^~~~~~~~~~~~~~~~~~~~~~~~~~
18 warnings and 1 error generated.
vim +80 drivers/net/ethernet/aquantia/atlantic/aq_ring.c
46f4c29d9de6e4 Igor Russkikh 2019-03-23 60
46f4c29d9de6e4 Igor Russkikh 2019-03-23 61 static int aq_get_rxpages(struct aq_ring_s *self, struct aq_ring_buff_s *rxbuf,
46f4c29d9de6e4 Igor Russkikh 2019-03-23 62 int order)
46f4c29d9de6e4 Igor Russkikh 2019-03-23 63 {
46f4c29d9de6e4 Igor Russkikh 2019-03-23 64 int ret;
46f4c29d9de6e4 Igor Russkikh 2019-03-23 65
46f4c29d9de6e4 Igor Russkikh 2019-03-23 66 if (rxbuf->rxdata.page) {
46f4c29d9de6e4 Igor Russkikh 2019-03-23 67 /* One means ring is the only user and can reuse */
46f4c29d9de6e4 Igor Russkikh 2019-03-23 68 if (page_ref_count(rxbuf->rxdata.page) > 1) {
46f4c29d9de6e4 Igor Russkikh 2019-03-23 69 /* Try reuse buffer */
46f4c29d9de6e4 Igor Russkikh 2019-03-23 70 rxbuf->rxdata.pg_off += AQ_CFG_RX_FRAME_MAX;
46f4c29d9de6e4 Igor Russkikh 2019-03-23 71 if (rxbuf->rxdata.pg_off + AQ_CFG_RX_FRAME_MAX <=
46f4c29d9de6e4 Igor Russkikh 2019-03-23 72 (PAGE_SIZE << order)) {
d7d8bb9286134b Mark Starovoytov 2020-07-20 73 u64_stats_update_begin(&self->stats.rx.syncp);
46f4c29d9de6e4 Igor Russkikh 2019-03-23 74 self->stats.rx.pg_flips++;
d7d8bb9286134b Mark Starovoytov 2020-07-20 75 u64_stats_update_end(&self->stats.rx.syncp);
46f4c29d9de6e4 Igor Russkikh 2019-03-23 76 } else {
46f4c29d9de6e4 Igor Russkikh 2019-03-23 77 /* Buffer exhausted. We have other users and
46f4c29d9de6e4 Igor Russkikh 2019-03-23 78 * should release this page and realloc
46f4c29d9de6e4 Igor Russkikh 2019-03-23 79 */
46f4c29d9de6e4 Igor Russkikh 2019-03-23 @80 aq_free_rxpage(&rxbuf->rxdata,
46f4c29d9de6e4 Igor Russkikh 2019-03-23 81 aq_nic_get_dev(self->aq_nic));
d7d8bb9286134b Mark Starovoytov 2020-07-20 82 u64_stats_update_begin(&self->stats.rx.syncp);
46f4c29d9de6e4 Igor Russkikh 2019-03-23 83 self->stats.rx.pg_losts++;
d7d8bb9286134b Mark Starovoytov 2020-07-20 84 u64_stats_update_end(&self->stats.rx.syncp);
46f4c29d9de6e4 Igor Russkikh 2019-03-23 85 }
46f4c29d9de6e4 Igor Russkikh 2019-03-23 86 } else {
46f4c29d9de6e4 Igor Russkikh 2019-03-23 87 rxbuf->rxdata.pg_off = 0;
d7d8bb9286134b Mark Starovoytov 2020-07-20 88 u64_stats_update_begin(&self->stats.rx.syncp);
46f4c29d9de6e4 Igor Russkikh 2019-03-23 89 self->stats.rx.pg_reuses++;
d7d8bb9286134b Mark Starovoytov 2020-07-20 90 u64_stats_update_end(&self->stats.rx.syncp);
46f4c29d9de6e4 Igor Russkikh 2019-03-23 91 }
46f4c29d9de6e4 Igor Russkikh 2019-03-23 92 }
46f4c29d9de6e4 Igor Russkikh 2019-03-23 93
46f4c29d9de6e4 Igor Russkikh 2019-03-23 94 if (!rxbuf->rxdata.page) {
46f4c29d9de6e4 Igor Russkikh 2019-03-23 95 ret = aq_get_rxpage(&rxbuf->rxdata, order,
46f4c29d9de6e4 Igor Russkikh 2019-03-23 96 aq_nic_get_dev(self->aq_nic));
aa7e17a3e35a6e Dmitry Bogdanov 2020-07-20 97 if (ret) {
aa7e17a3e35a6e Dmitry Bogdanov 2020-07-20 98 u64_stats_update_begin(&self->stats.rx.syncp);
aa7e17a3e35a6e Dmitry Bogdanov 2020-07-20 99 self->stats.rx.alloc_fails++;
aa7e17a3e35a6e Dmitry Bogdanov 2020-07-20 100 u64_stats_update_end(&self->stats.rx.syncp);
aa7e17a3e35a6e Dmitry Bogdanov 2020-07-20 101 }
46f4c29d9de6e4 Igor Russkikh 2019-03-23 102 return ret;
46f4c29d9de6e4 Igor Russkikh 2019-03-23 103 }
46f4c29d9de6e4 Igor Russkikh 2019-03-23 104
46f4c29d9de6e4 Igor Russkikh 2019-03-23 105 return 0;
46f4c29d9de6e4 Igor Russkikh 2019-03-23 106 }
46f4c29d9de6e4 Igor Russkikh 2019-03-23 107
:::::: The code at line 80 was first introduced by commit
:::::: 46f4c29d9de6e4a9d4ed7de9a37dd42501d89f86 net: aquantia: optimize rx performance by page reuse strategy
:::::: TO: Igor Russkikh <Igor.Russkikh(a)aquantia.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
1 year, 3 months
[kas:kvm-unmapped-memfd-secret 259/305] lib/stackdepot.c:154:2: warning: ignoring return value of 'kstrtobool', declared with attribute warn_unused_result
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/kas/linux.git kvm-unmapped-memfd-secret
head: 94275e094f4072635764a33ae668a1c42e588034
commit: c35686e535d7b1e77d1597ea230e6d0c42db19b8 [259/305] lib: stackdepot: add support to disable stack depot
config: ia64-randconfig-r003-20210301 (attached as .config)
compiler: ia64-linux-gcc (GCC) 9.3.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/kas/linux.git/commit/?id=...
git remote add kas https://git.kernel.org/pub/scm/linux/kernel/git/kas/linux.git
git fetch --no-tags kas kvm-unmapped-memfd-secret
git checkout c35686e535d7b1e77d1597ea230e6d0c42db19b8
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=ia64
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 >>):
In file included from arch/ia64/include/asm/pgtable.h:154,
from include/linux/pgtable.h:6,
from arch/ia64/include/asm/uaccess.h:40,
from include/linux/uaccess.h:11,
from arch/ia64/include/asm/sections.h:11,
from include/linux/interrupt.h:20,
from lib/stackdepot.c:23:
arch/ia64/include/asm/mmu_context.h: In function 'reload_context':
arch/ia64/include/asm/mmu_context.h:127:41: warning: variable 'old_rr4' set but not used [-Wunused-but-set-variable]
127 | unsigned long rr0, rr1, rr2, rr3, rr4, old_rr4;
| ^~~~~~~
lib/stackdepot.c: In function 'is_stack_depot_disabled':
>> lib/stackdepot.c:154:2: warning: ignoring return value of 'kstrtobool', declared with attribute warn_unused_result [-Wunused-result]
154 | kstrtobool(str, &stack_depot_disable);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
vim +/kstrtobool +154 lib/stackdepot.c
151
152 static int __init is_stack_depot_disabled(char *str)
153 {
> 154 kstrtobool(str, &stack_depot_disable);
155 if (stack_depot_disable) {
156 pr_info("Stack Depot is disabled\n");
157 stack_table = NULL;
158 }
159 return 0;
160 }
161 early_param("stack_depot_disable", is_stack_depot_disabled);
162
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 3 months
[PATCH] PM / devfreq: fix odd_ptr_err.cocci warnings (fwd)
by Julia Lawall
Hello,
There seems to be an inconsistency, but the patch proposed by Coccinelle
does not look correct. There should be a test on opp_table.
julia
---------- Forwarded message ----------
Date: Mon, 1 Mar 2021 16:35:52 +0800
From: kernel test robot <lkp(a)intel.com>
To: kbuild(a)lists.01.org
Cc: lkp(a)intel.com, Julia Lawall <julia.lawall(a)lip6.fr>
Subject: [PATCH] PM / devfreq: fix odd_ptr_err.cocci warnings
CC: kbuild-all(a)lists.01.org
TO: Saravana Kannan <skannan(a)codeaurora.org>
CC: Chanwoo Choi <cw00.choi(a)samsung.com>
CC: Sibi Sankar <sibis(a)codeaurora.org>
CC: MyungJoo Ham <myungjoo.ham(a)samsung.com>
CC: Kyungmin Park <kyungmin.park(a)samsung.com>
CC: linux-pm(a)vger.kernel.org
CC: linux-kernel(a)vger.kernel.org
From: kernel test robot <lkp(a)intel.com>
drivers/devfreq/governor_passive.c:318:7-13: inconsistent IS_ERR and PTR_ERR on line 319.
PTR_ERR should access the value just tested by IS_ERR
Semantic patch information:
There can be false positives in the patch case, where it is the call to
IS_ERR that is wrong.
Generated by: scripts/coccinelle/tests/odd_ptr_err.cocci
Fixes: 82d4ff586ae2 ("PM / devfreq: Add cpu based scaling support to passive governor")
CC: Saravana Kannan <skannan(a)codeaurora.org>
Reported-by: kernel test robot <lkp(a)intel.com>
Signed-off-by: kernel test robot <lkp(a)intel.com>
---
tree: https://git.kernel.org/pub/scm/linux/kernel/git/chanwoo/linux.git devfreq-testing-passive-gov
head: 82d4ff586ae2fb6d89cad871949004bed3438ccb
commit: 82d4ff586ae2fb6d89cad871949004bed3438ccb [3/3] PM / devfreq: Add cpu based scaling support to passive governor
:::::: branch date: 3 hours ago
:::::: commit date: 3 hours ago
Please take the patch only if it's a positive warning. Thanks!
governor_passive.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/devfreq/governor_passive.c
+++ b/drivers/devfreq/governor_passive.c
@@ -316,7 +316,7 @@ static int cpufreq_passive_register(stru
opp_table = dev_pm_opp_get_opp_table(cpu_dev);
if (IS_ERR(devfreq->opp_table)) {
- ret = PTR_ERR(opp_table);
+ ret = PTR_ERR(devfreq->opp_table);
goto out;
}
1 year, 3 months
Re: [PATCH v2 2/3] clk: Provide new devm_clk_helpers for prepared and enabled clocks
by kernel test robot
Hi "Uwe,
I love your patch! Yet something to improve:
[auto build test ERROR on fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8]
url: https://github.com/0day-ci/linux/commits/Uwe-Kleine-K-nig/clk-provide-new...
base: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
config: i386-randconfig-s002-20210301 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-241-geaceeafa-dirty
# https://github.com/0day-ci/linux/commit/fb9e331a334ed83c22735b4398e56b121...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Uwe-Kleine-K-nig/clk-provide-new-devm-helpers-for-prepared-and-enabled-clocks/20210301-191522
git checkout fb9e331a334ed83c22735b4398e56b121ca9dbf5
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=i386
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/clk/clk-devres.c:22:13: warning: no previous prototype for '__devm_clk_get' [-Wmissing-prototypes]
22 | struct clk *__devm_clk_get(struct device *dev, const char *id,
| ^~~~~~~~~~~~~~
/tmp/ccuTaeUR.s: Assembler messages:
>> /tmp/ccuTaeUR.s:37: Error: symbol `__kstrtab_devm_clk_get_prepared' is already defined
>> /tmp/ccuTaeUR.s:39: Error: symbol `__kstrtabns_devm_clk_get_prepared' is already defined
/tmp/ccuTaeUR.s:45: Error: symbol `__ksymtab_devm_clk_get_prepared' is already defined
>> /tmp/ccuTaeUR.s:82: Error: symbol `__kstrtab_devm_clk_get_optional_prepared' is already defined
>> /tmp/ccuTaeUR.s:84: Error: symbol `__kstrtabns_devm_clk_get_optional_prepared' is already defined
/tmp/ccuTaeUR.s:90: Error: symbol `__ksymtab_devm_clk_get_optional_prepared' is already defined
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 3 months
[jirislaby:devel 76/100] drivers/usb/class/cdc-acm.c:1057:10: error: expected ';' before 'acm'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jirislaby/linux.git devel
head: 61fbd3f9b3f46a50216cc58557ed831d7a686734
commit: 8eba9d0ff9f60cd0f7e1ee447e6894250972c7c2 [76/100] make use of tty_get_byte_size
config: nios2-randconfig-r001-20210301 (attached as .config)
compiler: nios2-linux-gcc (GCC) 9.3.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/jirislaby/linux.git/commi...
git remote add jirislaby https://git.kernel.org/pub/scm/linux/kernel/git/jirislaby/linux.git
git fetch --no-tags jirislaby devel
git checkout 8eba9d0ff9f60cd0f7e1ee447e6894250972c7c2
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=nios2
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/usb/class/cdc-acm.c: In function 'acm_tty_set_termios':
>> drivers/usb/class/cdc-acm.c:1057:10: error: expected ';' before 'acm'
1057 | false)
| ^
| ;
......
1060 | acm->clocal = ((termios->c_cflag & CLOCAL) != 0);
| ~~~
vim +1057 drivers/usb/class/cdc-acm.c
1042
1043 static void acm_tty_set_termios(struct tty_struct *tty,
1044 struct ktermios *termios_old)
1045 {
1046 struct acm *acm = tty->driver_data;
1047 struct ktermios *termios = &tty->termios;
1048 struct usb_cdc_line_coding newline;
1049 int newctrl = acm->ctrlout;
1050
1051 newline.dwDTERate = cpu_to_le32(tty_get_baud_rate(tty));
1052 newline.bCharFormat = termios->c_cflag & CSTOPB ? 2 : 0;
1053 newline.bParityType = termios->c_cflag & PARENB ?
1054 (termios->c_cflag & PARODD ? 1 : 2) +
1055 (termios->c_cflag & CMSPAR ? 2 : 0) : 0;
1056 newline.bDataBits = tty_get_byte_size(termios->c_cflag, false, false,
> 1057 false)
1058
1059 /* FIXME: Needs to clear unsupported bits in the termios */
1060 acm->clocal = ((termios->c_cflag & CLOCAL) != 0);
1061
1062 if (C_BAUD(tty) == B0) {
1063 newline.dwDTERate = acm->line.dwDTERate;
1064 newctrl &= ~ACM_CTRL_DTR;
1065 } else if (termios_old && (termios_old->c_cflag & CBAUD) == B0) {
1066 newctrl |= ACM_CTRL_DTR;
1067 }
1068
1069 if (newctrl != acm->ctrlout)
1070 acm_set_control(acm, acm->ctrlout = newctrl);
1071
1072 if (memcmp(&acm->line, &newline, sizeof newline)) {
1073 memcpy(&acm->line, &newline, sizeof newline);
1074 dev_dbg(&acm->control->dev, "%s - set line: %d %d %d %d\n",
1075 __func__,
1076 le32_to_cpu(newline.dwDTERate),
1077 newline.bCharFormat, newline.bParityType,
1078 newline.bDataBits);
1079 acm_set_line(acm, &acm->line);
1080 }
1081 }
1082
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 3 months
drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:233:24: warning: taking address of packed member 'param1' of class or structure 'qtnf_extra_bd_params' may result in an unaligned pointer value
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
commit: 1062fc45d1e93faefb93961f3be0a687f3f0e2e1 MIPS: Loongson64: Select SMP in Kconfig to avoid build error
date: 5 months ago
config: mips-randconfig-r011-20210301 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project b077d82b00d81934c7c27ac89dd8b0e7f448bded)
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 mips cross compiling tool for clang build
# apt-get install binutils-mips-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 1062fc45d1e93faefb93961f3be0a687f3f0e2e1
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=mips
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 >>):
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:6:
In file included from include/linux/pci.h:1439:
In file included from include/linux/dmapool.h:14:
In file included from include/linux/scatterlist.h:8:
In file included from include/linux/mm.h:33:
In file included from include/linux/pgtable.h:6:
arch/mips/include/asm/pgtable.h:208:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
cmpxchg((ptr), (o), (n)); \
^
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:16:
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/pcie_priv.h:10:
In file included from include/linux/skbuff.h:28:
In file included from include/net/checksum.h:22:
arch/mips/include/asm/checksum.h:195:9: error: unsupported inline asm: input with type 'unsigned long' matching output with type '__wsum' (aka 'unsigned int')
: "0" ((__force unsigned long)daddr),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:16:
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/pcie_priv.h:15:
In file included from drivers/net/wireless/quantenna/qtnfmac/bus.h:7:
include/linux/netdevice.h:567:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
} while (cmpxchg(&n->state, val, new) != val);
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:16:
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/pcie_priv.h:15:
In file included from drivers/net/wireless/quantenna/qtnfmac/bus.h:7:
include/linux/netdevice.h:567:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:16:
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/pcie_priv.h:15:
In file included from drivers/net/wireless/quantenna/qtnfmac/bus.h:11:
In file included from drivers/net/wireless/quantenna/qtnfmac/core.h:15:
In file included from include/net/sock.h:61:
include/linux/poll.h:142:27: warning: division by zero is undefined [-Wdivision-by-zero]
M(RDNORM) | M(RDBAND) | M(WRNORM) | M(WRBAND) |
^~~~~~~~~
include/linux/poll.h:140:32: note: expanded from macro 'M'
#define M(X) (__force __poll_t)__MAP(val, POLL##X, (__force __u16)EPOLL##X)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/poll.h:126:51: note: expanded from macro '__MAP'
(from < to ? (v & from) * (to/from) : (v & from) / (from/to))
^ ~~~~~~~~~
include/linux/poll.h:142:39: warning: division by zero is undefined [-Wdivision-by-zero]
M(RDNORM) | M(RDBAND) | M(WRNORM) | M(WRBAND) |
^~~~~~~~~
include/linux/poll.h:140:32: note: expanded from macro 'M'
#define M(X) (__force __poll_t)__MAP(val, POLL##X, (__force __u16)EPOLL##X)
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/poll.h:126:51: note: expanded from macro '__MAP'
(from < to ? (v & from) * (to/from) : (v & from) / (from/to))
^ ~~~~~~~~~
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:16:
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/pcie_priv.h:15:
In file included from drivers/net/wireless/quantenna/qtnfmac/bus.h:11:
In file included from drivers/net/wireless/quantenna/qtnfmac/core.h:15:
include/net/sock.h:1971:12: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
old_dst = xchg((__force struct dst_entry **)&sk->sk_dst_cache, dst);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:16:
In file included from drivers/net/wireless/quantenna/qtnfmac/pcie/pcie_priv.h:15:
In file included from drivers/net/wireless/quantenna/qtnfmac/bus.h:11:
In file included from drivers/net/wireless/quantenna/qtnfmac/core.h:15:
include/net/sock.h:2219:8: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
err = xchg(&sk->sk_err, 0);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
>> drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:233:24: warning: taking address of packed member 'param1' of class or structure 'qtnf_extra_bd_params' may result in an unaligned pointer value [-Waddress-of-packed-member]
ts->ep_next_rx_pkt = &extra_params->param1;
^~~~~~~~~~~~~~~~~~~~
>> drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:236:22: warning: taking address of packed member 'param2' of class or structure 'qtnf_extra_bd_params' may result in an unaligned pointer value [-Waddress-of-packed-member]
ts->txqueue_wake = &extra_params->param2;
^~~~~~~~~~~~~~~~~~~~
>> drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c:237:20: warning: taking address of packed member 'param3' of class or structure 'qtnf_extra_bd_params' may result in an unaligned pointer value [-Waddress-of-packed-member]
ts->ep_pmstate = &extra_params->param3;
^~~~~~~~~~~~~~~~~~~~
21 warnings and 1 error generated.
--
In file included from include/linux/rculist.h:11:
In file included from include/linux/rcupdate.h:29:
In file included from include/linux/lockdep.h:14:
In file included from include/linux/smp.h:15:
In file included from include/linux/smp_types.h:5:
include/linux/llist.h:222:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
return xchg(&head->first, NULL);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/pcie/rx.c:64:
In file included from include/linux/sched.h:14:
In file included from include/linux/pid.h:5:
In file included from include/linux/rculist.h:11:
In file included from include/linux/rcupdate.h:29:
In file included from include/linux/lockdep.h:27:
include/linux/debug_locks.h:17:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
return xchg(&debug_locks, 0);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/pcie/rx.c:69:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-io.h:61:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-devtrace.h:15:
In file included from include/linux/skbuff.h:17:
In file included from include/linux/bvec.h:13:
In file included from include/linux/mm.h:33:
In file included from include/linux/pgtable.h:6:
arch/mips/include/asm/pgtable.h:208:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
cmpxchg64(&buddy->pte, 0, _PAGE_GLOBAL);
^
arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
cmpxchg((ptr), (o), (n)); \
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/pcie/rx.c:69:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-io.h:61:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-devtrace.h:15:
In file included from include/linux/skbuff.h:17:
In file included from include/linux/bvec.h:13:
In file included from include/linux/mm.h:33:
In file included from include/linux/pgtable.h:6:
arch/mips/include/asm/pgtable.h:208:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
cmpxchg((ptr), (o), (n)); \
^
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/pcie/rx.c:69:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-io.h:61:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-devtrace.h:15:
In file included from include/linux/skbuff.h:28:
In file included from include/net/checksum.h:22:
arch/mips/include/asm/checksum.h:195:9: error: unsupported inline asm: input with type 'unsigned long' matching output with type '__wsum' (aka 'unsigned int')
: "0" ((__force unsigned long)daddr),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/net/wireless/intel/iwlwifi/pcie/rx.c:69:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-io.h:61:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-devtrace.h:16:
In file included from include/linux/ieee80211.h:20:
In file included from include/linux/etherdevice.h:21:
include/linux/netdevice.h:567:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
} while (cmpxchg(&n->state, val, new) != val);
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/pcie/rx.c:69:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-io.h:61:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-devtrace.h:16:
In file included from include/linux/ieee80211.h:20:
In file included from include/linux/etherdevice.h:21:
include/linux/netdevice.h:567:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/pcie/rx.c:70:
>> drivers/net/wireless/intel/iwlwifi/pcie/internal.h:273:20: warning: taking address of packed member 'closed_rb_num' of class or structure 'iwl_rb_status' may result in an unaligned pointer value [-Waddress-of-packed-member]
return READ_ONCE(rb_stts->closed_rb_num);
^~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:50:14: note: expanded from macro 'READ_ONCE'
__READ_ONCE(x); \
^
include/asm-generic/rwonce.h:44:72: note: expanded from macro '__READ_ONCE'
#define __READ_ONCE(x) (*(const volatile __unqual_scalar_typeof(x) *)&(x))
^
15 warnings and 1 error generated.
--
In file included from include/linux/pid.h:5:
In file included from include/linux/rculist.h:11:
In file included from include/linux/rcupdate.h:29:
In file included from include/linux/lockdep.h:14:
In file included from include/linux/smp.h:15:
In file included from include/linux/smp_types.h:5:
include/linux/llist.h:222:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
return xchg(&head->first, NULL);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/fw/dbg.c:64:
In file included from include/linux/devcoredump.h:8:
In file included from include/linux/device.h:15:
In file included from include/linux/dev_printk.h:16:
In file included from include/linux/ratelimit.h:6:
In file included from include/linux/sched.h:14:
In file included from include/linux/pid.h:5:
In file included from include/linux/rculist.h:11:
In file included from include/linux/rcupdate.h:29:
In file included from include/linux/lockdep.h:27:
include/linux/debug_locks.h:17:9: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
return xchg(&debug_locks, 0);
^
arch/mips/include/asm/cmpxchg.h:102:7: note: expanded from macro 'xchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/fw/dbg.c:64:
In file included from include/linux/devcoredump.h:12:
In file included from include/linux/scatterlist.h:8:
In file included from include/linux/mm.h:33:
In file included from include/linux/pgtable.h:6:
arch/mips/include/asm/pgtable.h:208:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
cmpxchg64(&buddy->pte, 0, _PAGE_GLOBAL);
^
arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
cmpxchg((ptr), (o), (n)); \
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/fw/dbg.c:64:
In file included from include/linux/devcoredump.h:12:
In file included from include/linux/scatterlist.h:8:
In file included from include/linux/mm.h:33:
In file included from include/linux/pgtable.h:6:
arch/mips/include/asm/pgtable.h:208:3: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:220:2: note: expanded from macro 'cmpxchg64'
cmpxchg((ptr), (o), (n)); \
^
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/fw/dbg.c:66:
In file included from drivers/net/wireless/intel/iwlwifi/fw/runtime.h:63:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-config.h:64:
In file included from include/linux/netdevice.h:37:
In file included from include/linux/ethtool.h:18:
In file included from include/uapi/linux/ethtool.h:19:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:28:
In file included from include/net/checksum.h:22:
arch/mips/include/asm/checksum.h:195:9: error: unsupported inline asm: input with type 'unsigned long' matching output with type '__wsum' (aka 'unsigned int')
: "0" ((__force unsigned long)daddr),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from drivers/net/wireless/intel/iwlwifi/fw/dbg.c:66:
In file included from drivers/net/wireless/intel/iwlwifi/fw/runtime.h:63:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-config.h:64:
include/linux/netdevice.h:567:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
} while (cmpxchg(&n->state, val, new) != val);
^
arch/mips/include/asm/cmpxchg.h:194:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
In file included from drivers/net/wireless/intel/iwlwifi/fw/dbg.c:66:
In file included from drivers/net/wireless/intel/iwlwifi/fw/runtime.h:63:
In file included from drivers/net/wireless/intel/iwlwifi/iwl-config.h:64:
include/linux/netdevice.h:567:11: warning: converting the result of '<<' to a boolean always evaluates to true [-Wtautological-constant-compare]
arch/mips/include/asm/cmpxchg.h:204:7: note: expanded from macro 'cmpxchg'
if (!__SYNC_loongson3_war) \
^
arch/mips/include/asm/sync.h:147:34: note: expanded from macro '__SYNC_loongson3_war'
# define __SYNC_loongson3_war (1 << 31)
^
>> drivers/net/wireless/intel/iwlwifi/fw/dbg.c:1940:17: warning: taking address of packed member 'list' of class or structure 'iwl_fw_ini_dump_entry' may result in an unaligned pointer value [-Waddress-of-packed-member]
list_add_tail(&entry->list, list);
^~~~~~~~~~~
drivers/net/wireless/intel/iwlwifi/fw/dbg.c:2046:12: warning: taking address of packed member 'list' of class or structure 'iwl_fw_ini_dump_entry' may result in an unaligned pointer value [-Waddress-of-packed-member]
list_add(&entry->list, list);
^~~~~~~~~~~
drivers/net/wireless/intel/iwlwifi/fw/dbg.c:2219:12: warning: taking address of packed member 'list' of class or structure 'iwl_fw_ini_dump_entry' may result in an unaligned pointer value [-Waddress-of-packed-member]
list_add(&entry->list, list);
^~~~~~~~~~~
drivers/net/wireless/intel/iwlwifi/fw/dbg.c:2286:13: warning: taking address of packed member 'list' of class or structure 'iwl_fw_ini_dump_entry' may result in an unaligned pointer value [-Waddress-of-packed-member]
list_del(&entry->list);
^~~~~~~~~~~
drivers/net/wireless/intel/iwlwifi/fw/dbg.c:2314:23: warning: taking address of packed member 'list' of class or structure 'iwl_fw_ini_dump_entry' may result in an unaligned pointer value [-Waddress-of-packed-member]
list_for_each_entry(entry, &dump_list, list) {
~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/list.h:620:8: note: expanded from macro 'list_for_each_entry'
&pos->member != (head); \
^~~~~~~~~~~
19 warnings and 1 error generated.
..
vim +233 drivers/net/wireless/quantenna/qtnfmac/pcie/topaz_pcie.c
e401fa25cfa23d Sergey Matyukevich 2018-10-16 182
e401fa25cfa23d Sergey Matyukevich 2018-10-16 183 static int topaz_alloc_bd_table(struct qtnf_pcie_topaz_state *ts,
e401fa25cfa23d Sergey Matyukevich 2018-10-16 184 struct qtnf_topaz_bda __iomem *bda)
e401fa25cfa23d Sergey Matyukevich 2018-10-16 185 {
e401fa25cfa23d Sergey Matyukevich 2018-10-16 186 struct qtnf_extra_bd_params __iomem *extra_params;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 187 struct qtnf_pcie_bus_priv *priv = &ts->base;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 188 dma_addr_t paddr;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 189 void *vaddr;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 190 int len;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 191 int i;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 192
e401fa25cfa23d Sergey Matyukevich 2018-10-16 193 /* bd table */
e401fa25cfa23d Sergey Matyukevich 2018-10-16 194
e401fa25cfa23d Sergey Matyukevich 2018-10-16 195 len = priv->tx_bd_num * sizeof(struct qtnf_topaz_tx_bd) +
e401fa25cfa23d Sergey Matyukevich 2018-10-16 196 priv->rx_bd_num * sizeof(struct qtnf_topaz_rx_bd) +
e401fa25cfa23d Sergey Matyukevich 2018-10-16 197 sizeof(struct qtnf_extra_bd_params);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 198
e401fa25cfa23d Sergey Matyukevich 2018-10-16 199 vaddr = dmam_alloc_coherent(&priv->pdev->dev, len, &paddr, GFP_KERNEL);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 200 if (!vaddr)
e401fa25cfa23d Sergey Matyukevich 2018-10-16 201 return -ENOMEM;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 202
e401fa25cfa23d Sergey Matyukevich 2018-10-16 203 /* tx bd */
e401fa25cfa23d Sergey Matyukevich 2018-10-16 204
e401fa25cfa23d Sergey Matyukevich 2018-10-16 205 ts->tx_bd_vbase = vaddr;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 206 qtnf_non_posted_write(paddr, &bda->bda_rc_tx_bd_base);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 207
e401fa25cfa23d Sergey Matyukevich 2018-10-16 208 for (i = 0; i < priv->tx_bd_num; i++)
e401fa25cfa23d Sergey Matyukevich 2018-10-16 209 ts->tx_bd_vbase[i].info |= cpu_to_le32(QTN_BD_EMPTY);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 210
e401fa25cfa23d Sergey Matyukevich 2018-10-16 211 pr_debug("TX descriptor table: vaddr=0x%p paddr=%pad\n", vaddr, &paddr);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 212
e401fa25cfa23d Sergey Matyukevich 2018-10-16 213 priv->tx_bd_r_index = 0;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 214 priv->tx_bd_w_index = 0;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 215
e401fa25cfa23d Sergey Matyukevich 2018-10-16 216 /* rx bd */
e401fa25cfa23d Sergey Matyukevich 2018-10-16 217
e401fa25cfa23d Sergey Matyukevich 2018-10-16 218 vaddr = ((struct qtnf_topaz_tx_bd *)vaddr) + priv->tx_bd_num;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 219 paddr += priv->tx_bd_num * sizeof(struct qtnf_topaz_tx_bd);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 220
e401fa25cfa23d Sergey Matyukevich 2018-10-16 221 ts->rx_bd_vbase = vaddr;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 222 qtnf_non_posted_write(paddr, &bda->bda_rc_rx_bd_base);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 223
e401fa25cfa23d Sergey Matyukevich 2018-10-16 224 pr_debug("RX descriptor table: vaddr=0x%p paddr=%pad\n", vaddr, &paddr);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 225
e401fa25cfa23d Sergey Matyukevich 2018-10-16 226 /* extra shared params */
e401fa25cfa23d Sergey Matyukevich 2018-10-16 227
e401fa25cfa23d Sergey Matyukevich 2018-10-16 228 vaddr = ((struct qtnf_topaz_rx_bd *)vaddr) + priv->rx_bd_num;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 229 paddr += priv->rx_bd_num * sizeof(struct qtnf_topaz_rx_bd);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 230
e401fa25cfa23d Sergey Matyukevich 2018-10-16 231 extra_params = (struct qtnf_extra_bd_params __iomem *)vaddr;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 232
e401fa25cfa23d Sergey Matyukevich 2018-10-16 @233 ts->ep_next_rx_pkt = &extra_params->param1;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 234 qtnf_non_posted_write(paddr + QTNF_BD_PARAM_OFFSET(1),
e401fa25cfa23d Sergey Matyukevich 2018-10-16 235 &bda->bda_ep_next_pkt);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 @236 ts->txqueue_wake = &extra_params->param2;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 @237 ts->ep_pmstate = &extra_params->param3;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 238 ts->dma_msi_dummy = paddr + QTNF_BD_PARAM_OFFSET(4);
e401fa25cfa23d Sergey Matyukevich 2018-10-16 239
e401fa25cfa23d Sergey Matyukevich 2018-10-16 240 return 0;
e401fa25cfa23d Sergey Matyukevich 2018-10-16 241 }
e401fa25cfa23d Sergey Matyukevich 2018-10-16 242
:::::: The code at line 233 was first introduced by commit
:::::: e401fa25cfa23df8b17960a656ff11f49facae84 qtnfmac: add support for Topaz chipsets
:::::: TO: Sergey Matyukevich <sergey.matyukevich.os(a)quantenna.com>
:::::: CC: Kalle Valo <kvalo(a)codeaurora.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 3 months
Re: [PATCH v2 2/3] clk: Provide new devm_clk_helpers for prepared and enabled clocks
by kernel test robot
Hi "Uwe,
I love your patch! Yet something to improve:
[auto build test ERROR on fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8]
url: https://github.com/0day-ci/linux/commits/Uwe-Kleine-K-nig/clk-provide-new...
base: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
config: sh-randconfig-r035-20210301 (attached as .config)
compiler: sh4-linux-gcc (GCC) 9.3.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/fb9e331a334ed83c22735b4398e56b121...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Uwe-Kleine-K-nig/clk-provide-new-devm-helpers-for-prepared-and-enabled-clocks/20210301-191522
git checkout fb9e331a334ed83c22735b4398e56b121ca9dbf5
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=sh
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/clk/clk-devres.c:22:13: warning: no previous prototype for '__devm_clk_get' [-Wmissing-prototypes]
22 | struct clk *__devm_clk_get(struct device *dev, const char *id,
| ^~~~~~~~~~~~~~
In file included from include/linux/linkage.h:7,
from include/linux/kernel.h:7,
from include/linux/clk.h:13,
from drivers/clk/clk-devres.c:2:
>> include/linux/export.h:67:36: error: redefinition of '__ksymtab_devm_clk_get_prepared'
67 | static const struct kernel_symbol __ksymtab_##sym \
| ^~~~~~~~~~
include/linux/export.h:108:2: note: in expansion of macro '__KSYMTAB_ENTRY'
108 | __KSYMTAB_ENTRY(sym, sec)
| ^~~~~~~~~~~~~~~
include/linux/export.h:147:39: note: in expansion of macro '___EXPORT_SYMBOL'
147 | #define __EXPORT_SYMBOL(sym, sec, ns) ___EXPORT_SYMBOL(sym, sec, ns)
| ^~~~~~~~~~~~~~~~
include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL'
155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "")
| ^~~~~~~~~~~~~~~
include/linux/export.h:158:29: note: in expansion of macro '_EXPORT_SYMBOL'
158 | #define EXPORT_SYMBOL(sym) _EXPORT_SYMBOL(sym, "")
| ^~~~~~~~~~~~~~
drivers/clk/clk-devres.c:83:1: note: in expansion of macro 'EXPORT_SYMBOL'
83 | EXPORT_SYMBOL(devm_clk_get_prepared);
| ^~~~~~~~~~~~~
include/linux/export.h:67:36: note: previous definition of '__ksymtab_devm_clk_get_prepared' was here
67 | static const struct kernel_symbol __ksymtab_##sym \
| ^~~~~~~~~~
include/linux/export.h:108:2: note: in expansion of macro '__KSYMTAB_ENTRY'
108 | __KSYMTAB_ENTRY(sym, sec)
| ^~~~~~~~~~~~~~~
include/linux/export.h:147:39: note: in expansion of macro '___EXPORT_SYMBOL'
147 | #define __EXPORT_SYMBOL(sym, sec, ns) ___EXPORT_SYMBOL(sym, sec, ns)
| ^~~~~~~~~~~~~~~~
include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL'
155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "")
| ^~~~~~~~~~~~~~~
include/linux/export.h:158:29: note: in expansion of macro '_EXPORT_SYMBOL'
158 | #define EXPORT_SYMBOL(sym) _EXPORT_SYMBOL(sym, "")
| ^~~~~~~~~~~~~~
drivers/clk/clk-devres.c:75:1: note: in expansion of macro 'EXPORT_SYMBOL'
75 | EXPORT_SYMBOL(devm_clk_get_prepared);
| ^~~~~~~~~~~~~
>> include/linux/export.h:67:36: error: redefinition of '__ksymtab_devm_clk_get_optional_prepared'
67 | static const struct kernel_symbol __ksymtab_##sym \
| ^~~~~~~~~~
include/linux/export.h:108:2: note: in expansion of macro '__KSYMTAB_ENTRY'
108 | __KSYMTAB_ENTRY(sym, sec)
| ^~~~~~~~~~~~~~~
include/linux/export.h:147:39: note: in expansion of macro '___EXPORT_SYMBOL'
147 | #define __EXPORT_SYMBOL(sym, sec, ns) ___EXPORT_SYMBOL(sym, sec, ns)
| ^~~~~~~~~~~~~~~~
include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL'
155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "")
| ^~~~~~~~~~~~~~~
include/linux/export.h:158:29: note: in expansion of macro '_EXPORT_SYMBOL'
158 | #define EXPORT_SYMBOL(sym) _EXPORT_SYMBOL(sym, "")
| ^~~~~~~~~~~~~~
drivers/clk/clk-devres.c:105:1: note: in expansion of macro 'EXPORT_SYMBOL'
105 | EXPORT_SYMBOL(devm_clk_get_optional_prepared);
| ^~~~~~~~~~~~~
include/linux/export.h:67:36: note: previous definition of '__ksymtab_devm_clk_get_optional_prepared' was here
67 | static const struct kernel_symbol __ksymtab_##sym \
| ^~~~~~~~~~
include/linux/export.h:108:2: note: in expansion of macro '__KSYMTAB_ENTRY'
108 | __KSYMTAB_ENTRY(sym, sec)
| ^~~~~~~~~~~~~~~
include/linux/export.h:147:39: note: in expansion of macro '___EXPORT_SYMBOL'
147 | #define __EXPORT_SYMBOL(sym, sec, ns) ___EXPORT_SYMBOL(sym, sec, ns)
| ^~~~~~~~~~~~~~~~
include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL'
155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "")
| ^~~~~~~~~~~~~~~
include/linux/export.h:158:29: note: in expansion of macro '_EXPORT_SYMBOL'
158 | #define EXPORT_SYMBOL(sym) _EXPORT_SYMBOL(sym, "")
| ^~~~~~~~~~~~~~
drivers/clk/clk-devres.c:97:1: note: in expansion of macro 'EXPORT_SYMBOL'
97 | EXPORT_SYMBOL(devm_clk_get_optional_prepared);
| ^~~~~~~~~~~~~
vim +/__ksymtab_devm_clk_get_prepared +67 include/linux/export.h
f50169324df4ad Paul Gortmaker 2011-05-23 41
7290d58095712a Ard Biesheuvel 2018-08-21 42 #ifdef CONFIG_HAVE_ARCH_PREL32_RELOCATIONS
7290d58095712a Ard Biesheuvel 2018-08-21 43 #include <linux/compiler.h>
7290d58095712a Ard Biesheuvel 2018-08-21 44 /*
7290d58095712a Ard Biesheuvel 2018-08-21 45 * Emit the ksymtab entry as a pair of relative references: this reduces
7290d58095712a Ard Biesheuvel 2018-08-21 46 * the size by half on 64-bit architectures, and eliminates the need for
7290d58095712a Ard Biesheuvel 2018-08-21 47 * absolute relocations that require runtime processing on relocatable
7290d58095712a Ard Biesheuvel 2018-08-21 48 * kernels.
7290d58095712a Ard Biesheuvel 2018-08-21 49 */
7290d58095712a Ard Biesheuvel 2018-08-21 50 #define __KSYMTAB_ENTRY(sym, sec) \
7290d58095712a Ard Biesheuvel 2018-08-21 51 __ADDRESSABLE(sym) \
7290d58095712a Ard Biesheuvel 2018-08-21 52 asm(" .section \"___ksymtab" sec "+" #sym "\", \"a\" \n" \
ed13fc33f76303 Matthias Maennich 2019-09-06 53 " .balign 4 \n" \
7290d58095712a Ard Biesheuvel 2018-08-21 54 "__ksymtab_" #sym ": \n" \
7290d58095712a Ard Biesheuvel 2018-08-21 55 " .long " #sym "- . \n" \
7290d58095712a Ard Biesheuvel 2018-08-21 56 " .long __kstrtab_" #sym "- . \n" \
c3a6cf19e695c8 Masahiro Yamada 2019-10-18 57 " .long __kstrtabns_" #sym "- . \n" \
7290d58095712a Ard Biesheuvel 2018-08-21 58 " .previous \n")
7290d58095712a Ard Biesheuvel 2018-08-21 59
7290d58095712a Ard Biesheuvel 2018-08-21 60 struct kernel_symbol {
7290d58095712a Ard Biesheuvel 2018-08-21 61 int value_offset;
7290d58095712a Ard Biesheuvel 2018-08-21 62 int name_offset;
8651ec01daedad Matthias Maennich 2019-09-06 63 int namespace_offset;
7290d58095712a Ard Biesheuvel 2018-08-21 64 };
7290d58095712a Ard Biesheuvel 2018-08-21 65 #else
7290d58095712a Ard Biesheuvel 2018-08-21 66 #define __KSYMTAB_ENTRY(sym, sec) \
7290d58095712a Ard Biesheuvel 2018-08-21 @67 static const struct kernel_symbol __ksymtab_##sym \
7290d58095712a Ard Biesheuvel 2018-08-21 68 __attribute__((section("___ksymtab" sec "+" #sym), used)) \
ed13fc33f76303 Matthias Maennich 2019-09-06 69 __aligned(sizeof(void *)) \
c3a6cf19e695c8 Masahiro Yamada 2019-10-18 70 = { (unsigned long)&sym, __kstrtab_##sym, __kstrtabns_##sym }
7290d58095712a Ard Biesheuvel 2018-08-21 71
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 3 months
Re: [PATCH v2 1/3] clk: generalize devm_clk_get() a bit
by kernel test robot
Hi "Uwe,
I love your patch! Perhaps something to improve:
[auto build test WARNING on fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8]
url: https://github.com/0day-ci/linux/commits/Uwe-Kleine-K-nig/clk-provide-new...
base: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
config: arm64-randconfig-r036-20210301 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 5de09ef02e24d234d9fc0cd1c6dfe18a1bb784b0)
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/bf2779180284ed39480360900c07ce553...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Uwe-Kleine-K-nig/clk-provide-new-devm-helpers-for-prepared-and-enabled-clocks/20210301-191522
git checkout bf2779180284ed39480360900c07ce553f75e06a
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross 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/clk/clk-devres.c:22:13: warning: no previous prototype for function '__devm_clk_get' [-Wmissing-prototypes]
struct clk *__devm_clk_get(struct device *dev, const char *id,
^
drivers/clk/clk-devres.c:22:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
struct clk *__devm_clk_get(struct device *dev, const char *id,
^
static
1 warning generated.
vim +/__devm_clk_get +22 drivers/clk/clk-devres.c
21
> 22 struct clk *__devm_clk_get(struct device *dev, const char *id,
23 struct clk *(*get)(struct device *dev, const char *id),
24 int (*init)(struct clk *clk),
25 void (*exit)(struct clk *clk))
26 {
27 struct devm_clk_state *state;
28 struct clk *clk;
29 int ret;
30
31 state = devres_alloc(devm_clk_release, sizeof(*state), GFP_KERNEL);
32 if (!state)
33 return ERR_PTR(-ENOMEM);
34
35 clk = get(dev, id);
36 if (IS_ERR(clk)) {
37 ret = PTR_ERR(clk);
38 goto err_clk_get;
39 }
40
41 if (init) {
42 ret = init(clk);
43 if (ret)
44 goto err_clk_init;
45 }
46
47 state->clk = clk;
48 state->exit = exit;
49
50 devres_add(dev, state);
51
52 return clk;
53
54 err_clk_init:
55
56 clk_put(clk);
57 err_clk_get:
58
59 devres_free(state);
60 return ERR_PTR(ret);
61 }
62
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 3 months
Re: [PATCH v2 1/3] clk: generalize devm_clk_get() a bit
by kernel test robot
Hi "Uwe,
I love your patch! Perhaps something to improve:
[auto build test WARNING on fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8]
url: https://github.com/0day-ci/linux/commits/Uwe-Kleine-K-nig/clk-provide-new...
base: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
config: nds32-defconfig (attached as .config)
compiler: nds32le-linux-gcc (GCC) 9.3.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/bf2779180284ed39480360900c07ce553...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Uwe-Kleine-K-nig/clk-provide-new-devm-helpers-for-prepared-and-enabled-clocks/20210301-191522
git checkout bf2779180284ed39480360900c07ce553f75e06a
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=nds32
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/clk/clk-devres.c:22:13: warning: no previous prototype for '__devm_clk_get' [-Wmissing-prototypes]
22 | struct clk *__devm_clk_get(struct device *dev, const char *id,
| ^~~~~~~~~~~~~~
vim +/__devm_clk_get +22 drivers/clk/clk-devres.c
21
> 22 struct clk *__devm_clk_get(struct device *dev, const char *id,
23 struct clk *(*get)(struct device *dev, const char *id),
24 int (*init)(struct clk *clk),
25 void (*exit)(struct clk *clk))
26 {
27 struct devm_clk_state *state;
28 struct clk *clk;
29 int ret;
30
31 state = devres_alloc(devm_clk_release, sizeof(*state), GFP_KERNEL);
32 if (!state)
33 return ERR_PTR(-ENOMEM);
34
35 clk = get(dev, id);
36 if (IS_ERR(clk)) {
37 ret = PTR_ERR(clk);
38 goto err_clk_get;
39 }
40
41 if (init) {
42 ret = init(clk);
43 if (ret)
44 goto err_clk_init;
45 }
46
47 state->clk = clk;
48 state->exit = exit;
49
50 devres_add(dev, state);
51
52 return clk;
53
54 err_clk_init:
55
56 clk_put(clk);
57 err_clk_get:
58
59 devres_free(state);
60 return ERR_PTR(ret);
61 }
62
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 3 months