From: kbuild test robot <lkp@intel.com>
To: Matthew Wilcox <mawilcox@microsoft.com>
Cc: kbuild-all@01.org, Johannes Weiner <hannes@cmpxchg.org>,
Andrew Morton <akpm@linux-foundation.org>,
Linux Memory Management List <linux-mm@kvack.org>
Subject: [mmotm:master 149/199] lib/idr.c:583:2: error: implicit declaration of function 'xa_lock_irqsave'; did you mean 'read_lock_irqsave'?
Date: Sat, 19 May 2018 04:21:17 +0800 [thread overview]
Message-ID: <201805190415.2D1H4m65%fengguang.wu@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 5215 bytes --]
tree: git://git.cmpxchg.org/linux-mmotm.git master
head: 7400fc6942aefa2e009272d0e118284f110c5088
commit: d5f90621ff2af7f139b01b7bcf8649a91665965e [149/199] lib/idr.c: remove simple_ida_lock
config: x86_64-randconfig-i0-201819 (attached as .config)
compiler: gcc-7 (Debian 7.3.0-16) 7.3.0
reproduce:
git checkout d5f90621ff2af7f139b01b7bcf8649a91665965e
# save the attached .config to linux build tree
make ARCH=x86_64
Note: the mmotm/master HEAD 7400fc6942aefa2e009272d0e118284f110c5088 builds fine.
It only hurts bisectibility.
All errors (new ones prefixed by >>):
lib/idr.c: In function 'ida_simple_get':
>> lib/idr.c:583:2: error: implicit declaration of function 'xa_lock_irqsave'; did you mean 'read_lock_irqsave'? [-Werror=implicit-function-declaration]
xa_lock_irqsave(&ida->ida_rt, flags);
^~~~~~~~~~~~~~~
read_lock_irqsave
>> lib/idr.c:593:2: error: implicit declaration of function 'xa_unlock_irqrestore'; did you mean 'read_unlock_irqrestore'? [-Werror=implicit-function-declaration]
xa_unlock_irqrestore(&ida->ida_rt, flags);
^~~~~~~~~~~~~~~~~~~~
read_unlock_irqrestore
Cyclomatic Complexity 5 include/linux/compiler.h:__read_once_size
Cyclomatic Complexity 5 include/linux/compiler.h:__write_once_size
Cyclomatic Complexity 1 arch/x86/include/asm/bitops.h:__set_bit
Cyclomatic Complexity 1 arch/x86/include/asm/bitops.h:__clear_bit
Cyclomatic Complexity 1 arch/x86/include/asm/bitops.h:constant_test_bit
Cyclomatic Complexity 1 arch/x86/include/asm/bitops.h:variable_test_bit
Cyclomatic Complexity 1 arch/x86/include/asm/bitops.h:__ffs
Cyclomatic Complexity 1 include/linux/err.h:ERR_PTR
Cyclomatic Complexity 1 include/linux/err.h:PTR_ERR
Cyclomatic Complexity 1 include/linux/radix-tree.h:radix_tree_is_internal_node
Cyclomatic Complexity 1 include/linux/radix-tree.h:iter_shift
Cyclomatic Complexity 1 include/linux/radix-tree.h:radix_tree_iter_init
Cyclomatic Complexity 1 include/linux/radix-tree.h:__radix_tree_iter_add
Cyclomatic Complexity 1 include/linux/radix-tree.h:radix_tree_chunk_size
Cyclomatic Complexity 1 include/linux/radix-tree.h:__radix_tree_next_slot
Cyclomatic Complexity 9 include/linux/radix-tree.h:radix_tree_next_slot
Cyclomatic Complexity 1 include/linux/err.h:IS_ERR
Cyclomatic Complexity 1 include/linux/radix-tree.h:radix_tree_exception
Cyclomatic Complexity 1 include/linux/radix-tree.h:radix_tree_iter_find
Cyclomatic Complexity 1 include/linux/radix-tree.h:radix_tree_iter_lookup
Cyclomatic Complexity 3 include/linux/bitmap.h:bitmap_full
Cyclomatic Complexity 3 include/linux/bitmap.h:bitmap_empty
Cyclomatic Complexity 7 lib/idr.c:idr_alloc_u32
Cyclomatic Complexity 5 lib/idr.c:idr_alloc
Cyclomatic Complexity 6 lib/idr.c:idr_alloc_cyclic
Cyclomatic Complexity 1 lib/idr.c:idr_remove
Cyclomatic Complexity 1 lib/idr.c:idr_find
Cyclomatic Complexity 6 lib/idr.c:idr_for_each
Cyclomatic Complexity 5 lib/idr.c:idr_get_next
Cyclomatic Complexity 3 lib/idr.c:idr_get_next_ul
Cyclomatic Complexity 5 lib/idr.c:idr_replace
Cyclomatic Complexity 18 lib/idr.c:ida_get_new_above
Cyclomatic Complexity 10 lib/idr.c:ida_remove
Cyclomatic Complexity 4 lib/idr.c:ida_destroy
Cyclomatic Complexity 6 lib/idr.c:ida_simple_get
Cyclomatic Complexity 1 lib/idr.c:ida_simple_remove
cc1: some warnings being treated as errors
vim +583 lib/idr.c
546
547 /**
548 * ida_simple_get - get a new id.
549 * @ida: the (initialized) ida.
550 * @start: the minimum id (inclusive, < 0x8000000)
551 * @end: the maximum id (exclusive, < 0x8000000 or 0)
552 * @gfp_mask: memory allocation flags
553 *
554 * Allocates an id in the range start <= id < end, or returns -ENOSPC.
555 * On memory allocation failure, returns -ENOMEM.
556 *
557 * Compared to ida_get_new_above() this function does its own locking, and
558 * should be used unless there are special requirements.
559 *
560 * Use ida_simple_remove() to get rid of an id.
561 */
562 int ida_simple_get(struct ida *ida, unsigned int start, unsigned int end,
563 gfp_t gfp_mask)
564 {
565 int ret, id;
566 unsigned int max;
567 unsigned long flags;
568
569 BUG_ON((int)start < 0);
570 BUG_ON((int)end < 0);
571
572 if (end == 0)
573 max = 0x80000000;
574 else {
575 BUG_ON(end < start);
576 max = end - 1;
577 }
578
579 again:
580 if (!ida_pre_get(ida, gfp_mask))
581 return -ENOMEM;
582
> 583 xa_lock_irqsave(&ida->ida_rt, flags);
584 ret = ida_get_new_above(ida, start, &id);
585 if (!ret) {
586 if (id > max) {
587 ida_remove(ida, id);
588 ret = -ENOSPC;
589 } else {
590 ret = id;
591 }
592 }
> 593 xa_unlock_irqrestore(&ida->ida_rt, flags);
594
595 if (unlikely(ret == -EAGAIN))
596 goto again;
597
598 return ret;
599 }
600 EXPORT_SYMBOL(ida_simple_get);
601
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 27289 bytes --]
next reply other threads:[~2018-05-18 20:21 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-18 20:21 kbuild test robot [this message]
2018-05-18 22:10 ` Andrew Morton
2018-05-19 14:31 ` Fengguang Wu
2018-05-21 0:48 ` [kbuild-all] " Li, Philip
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201805190415.2D1H4m65%fengguang.wu@intel.com \
--to=lkp@intel.com \
--cc=akpm@linux-foundation.org \
--cc=hannes@cmpxchg.org \
--cc=kbuild-all@01.org \
--cc=linux-mm@kvack.org \
--cc=mawilcox@microsoft.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox