From: kbuild test robot <lkp@intel.com>
To: Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: kbuild-all@01.org, linux-kbuild@vger.kernel.org,
Joe Perches <joe@perches.com>, Tom Rini <trini@konsulko.com>,
Geert Uytterhoeven <geert+renesas@glider.be>,
Masahiro Yamada <yamada.masahiro@socionext.com>,
Michal Marek <michal.lkml@markovi.net>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] kbuild: redefine __FILE__ as relative path from $(srctree) if possible
Date: Sun, 15 Oct 2017 04:15:40 +0800 [thread overview]
Message-ID: <201710150414.2Vnb9j2L%fengguang.wu@intel.com> (raw)
In-Reply-To: <1507802164-31614-3-git-send-email-yamada.masahiro@socionext.com>
[-- Attachment #1: Type: text/plain, Size: 2229 bytes --]
Hi Masahiro,
[auto build test WARNING on mmarek/for-next]
[also build test WARNING on next-20171013]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Masahiro-Yamada/kbuild-use-relative-path-from-srctree-instead-of-__FILE__/20171015-012234
base: git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild for-next
config: sparc64-allmodconfig (attached as .config)
compiler: sparc64-linux-gnu-gcc (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
make.cross ARCH=sparc64
All warnings (new ones prefixed by >>):
lib/dynamic_debug.c: In function 'trim_prefix':
>> lib/dynamic_debug.c:71:13: warning: overflow in implicit constant conversion [-Woverflow]
int skip = strlen(__FILE__) - strlen("lib/dynamic_debug.c");
^~~~~~
vim +71 lib/dynamic_debug.c
e9d376f0 Jason Baron 2009-02-05 67
2b678319 Jim Cromie 2011-12-19 68 /* Return the path relative to source root */
2b678319 Jim Cromie 2011-12-19 69 static inline const char *trim_prefix(const char *path)
2b678319 Jim Cromie 2011-12-19 70 {
2b678319 Jim Cromie 2011-12-19 @71 int skip = strlen(__FILE__) - strlen("lib/dynamic_debug.c");
2b678319 Jim Cromie 2011-12-19 72
2b678319 Jim Cromie 2011-12-19 73 if (strncmp(path, __FILE__, skip))
2b678319 Jim Cromie 2011-12-19 74 skip = 0; /* prefix mismatch, don't skip */
2b678319 Jim Cromie 2011-12-19 75
2b678319 Jim Cromie 2011-12-19 76 return path + skip;
2b678319 Jim Cromie 2011-12-19 77 }
2b678319 Jim Cromie 2011-12-19 78
:::::: The code at line 71 was first introduced by commit
:::::: 2b6783191da7211c88f98eb1a2bd2027bff36e30 dynamic_debug: add trim_prefix() to provide source-root relative paths
:::::: TO: Jim Cromie <jim.cromie@gmail.com>
:::::: CC: Greg Kroah-Hartman <gregkh@suse.de>
---
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: 48210 bytes --]
next prev parent reply other threads:[~2017-10-14 20:16 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-12 9:56 [PATCH 0/2] kbuild: use relative path from $(srctree) instead of __FILE__ Masahiro Yamada
2017-10-12 9:56 ` [PATCH 1/2] kbuild: add stringify helper to quote a string passed to C files Masahiro Yamada
2017-10-12 9:56 ` [PATCH 2/2] kbuild: redefine __FILE__ as relative path from $(srctree) if possible Masahiro Yamada
2017-10-14 20:15 ` kbuild test robot [this message]
2017-10-14 3:17 ` [PATCH 0/2] kbuild: use relative path from $(srctree) instead of __FILE__ Masahiro Yamada
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=201710150414.2Vnb9j2L%fengguang.wu@intel.com \
--to=lkp@intel.com \
--cc=geert+renesas@glider.be \
--cc=joe@perches.com \
--cc=kbuild-all@01.org \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.lkml@markovi.net \
--cc=trini@konsulko.com \
--cc=yamada.masahiro@socionext.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
all inboxes | Powered by JetHome®