tree:
https://github.com/jimc/linux.git dd-merge
head: 751c4af184aac85e647bfad89defad95f86dcd24
commit: 3c23cffcf721b5bf124ad1c3178170d8e0a30cb4 [20/37] dyndbg: validate ddebug_site_get
invariants
config: i386-randconfig-r004-20210617 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
#
https://github.com/jimc/linux/commit/3c23cffcf721b5bf124ad1c3178170d8e0a3...
git remote add jimc
https://github.com/jimc/linux.git
git fetch --no-tags jimc dd-merge
git checkout 3c23cffcf721b5bf124ad1c3178170d8e0a30cb4
# save the attached .config to linux build tree
make W=1 ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Note: the jimc/dd-merge HEAD 751c4af184aac85e647bfad89defad95f86dcd24 builds fine.
It only hurts bisectibility.
All errors (new ones prefixed by >>):
lib/dynamic_debug.c: In function 'ddebug_site_get':
> lib/dynamic_debug.c:155:12: error: '__start___dyndbg'
undeclared (first use in this function); did you mean '__start___dyndbgs'?
155 | if (dp >= __start___dyndbg && dp < __stop___dyndbg) {
| ^~~~~~~~~~~~~~~~
| __start___dyndbgs
lib/dynamic_debug.c:155:12: note: each undeclared identifier is reported only once for
each function it appears in
> lib/dynamic_debug.c:155:37: error: '__stop___dyndbg'
undeclared (first use in this function); did you mean '__stop___dyndbgs'?
155 | if (dp >= __start___dyndbg && dp < __stop___dyndbg) {
| ^~~~~~~~~~~~~~~
| __stop___dyndbgs
vim +155 lib/dynamic_debug.c
148
149 static struct _ddebug_site *ddebug_site_get(struct _ddebug *dp)
150 {
151 struct _ddebug *dh = dp - (dp->_index);
152
153 WARN_ON(!is_dyndbg_header_pair(dh, dh->site));
154
155 if (dp >= __start___dyndbg && dp <
__stop___dyndbg) {
156
157 v5pr_info("get: %s is builtin: %d %d %s:%s:%d\n",
158 dp->site->modname, dp->_index, (int)(dp - dh),
159 dh->site[dp->_index].filename,
160 dh->site[dp->_index].function, dp->lineno);
161
162 WARN_ON(dp != &__start___dyndbg[dp->_index]);
163
164 WARN_ON(!(dp->_index == (dp - dh) &&
165 dp->_index == (dp - __start___dyndbg) &&
166 dp->_index == (&__start___dyndbg_sites[dp->_index]
167 - &__start___dyndbg_sites[0])));
168
169 WARN_ON(&__start___dyndbg_sites[dp->_index] != dp->site);
170 } else {
171 v4pr_info("get: %s is loaded: %d %s:%s:%d\n",
172 dp->site->modname, dp->_index,
173 dh->site[dp->_index].filename,
174 dh->site[dp->_index].function, dp->lineno);
175 }
176 WARN_ON(&dh->site[dp->_index] != dp->site);
177
178 return dp->site;
179 }
180 static inline void ddebug_site_put(struct _ddebug *dp)
181 {
182 }
183
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org