From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [android-common:android13-5.10 11238/13329] mm/page_pinner.c:229:28: warning: comparison of distinct pointer types ('typeof ((ts_usec)) *' (aka 'long long *') and 'uint64_t *' (aka 'unsigned long long *'))
Date: Sun, 05 Sep 2021 09:09:55 +0800 [thread overview]
Message-ID: <202109050949.faLn7c0Z-lkp@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 5806 bytes --]
tree: https://android.googlesource.com/kernel/common android13-5.10
head: a3fbac7deb9ced9fb9f5621becd276e7118d9f64
commit: 0445b67beee9639842df07960dcc3cc5bc30f0d0 [11238/13329] ANDROID: mm: page_pinner: change timestamp format
config: arm-randconfig-r024-20210903 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project c9948e9254fbb6ea00f66c7b4542311d21e060be)
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 arm cross compiling tool for clang build
# apt-get install binutils-arm-linux-gnueabi
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android13-5.10
git checkout 0445b67beee9639842df07960dcc3cc5bc30f0d0
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> mm/page_pinner.c:229:28: warning: comparison of distinct pointer types ('typeof ((ts_usec)) *' (aka 'long long *') and 'uint64_t *' (aka 'unsigned long long *')) [-Wcompare-distinct-pointer-types]
unsigned long rem_usec = do_div(ts_usec, 1000000);
^~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/div64.h:226:28: note: expanded from macro 'do_div'
(void)(((typeof((n)) *)0) == ((uint64_t *)0)); \
~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~
mm/page_pinner.c:299:13: warning: comparison of distinct pointer types ('typeof ((ts_usec)) *' (aka 'long long *') and 'uint64_t *' (aka 'unsigned long long *')) [-Wcompare-distinct-pointer-types]
rem_usec = do_div(ts_usec, 1000000);
^~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/div64.h:226:28: note: expanded from macro 'do_div'
(void)(((typeof((n)) *)0) == ((uint64_t *)0)); \
~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~
mm/page_pinner.c:322:22: warning: variable 'page_pinner' set but not used [-Wunused-but-set-variable]
struct page_pinner *page_pinner;
^
3 warnings generated.
Kconfig warnings: (for reference only)
WARNING: unmet direct dependencies detected for USB_PHY
Depends on USB_SUPPORT
Selected by
- GKI_HIDDEN_USB_CONFIGS
WARNING: unmet direct dependencies detected for SND_VMASTER
Depends on SOUND && !UML && SND
Selected by
- GKI_HIDDEN_SND_CONFIGS
WARNING: unmet direct dependencies detected for SND_PCM_IEC958
Depends on SOUND && !UML && SND
Selected by
- GKI_HIDDEN_SND_SOC_CONFIGS
WARNING: unmet direct dependencies detected for DRM_TTM
Depends on HAS_IOMEM && DRM && MMU
Selected by
- GKI_HIDDEN_DRM_CONFIGS && HAS_IOMEM && DRM
WARNING: unmet direct dependencies detected for SND_JACK
Depends on SOUND && !UML && SND
Selected by
- GKI_HIDDEN_SND_CONFIGS
WARNING: unmet direct dependencies detected for SND_JACK_INPUT_DEV
Depends on SOUND && !UML && SND && SND_JACK
Selected by
- GKI_HIDDEN_SND_CONFIGS
WARNING: unmet direct dependencies detected for HMM_MIRROR
Depends on MMU
Selected by
- GKI_HIDDEN_GPU_CONFIGS
WARNING: unmet direct dependencies detected for SND_PCM_ELD
Depends on SOUND && !UML && SND
Selected by
- GKI_HIDDEN_SND_CONFIGS
WARNING: unmet direct dependencies detected for BALLOON_COMPACTION
Depends on COMPACTION && MEMORY_BALLOON
Selected by
- GKI_HIDDEN_MM_CONFIGS
vim +229 mm/page_pinner.c
210
211 static ssize_t
212 print_page_pinner(bool longterm, char __user *buf, size_t count, struct captured_pinner *record)
213 {
214 int ret;
215 unsigned long *entries;
216 unsigned int nr_entries;
217 char *kbuf;
218
219 count = min_t(size_t, count, PAGE_SIZE);
220 kbuf = kmalloc(count, GFP_KERNEL);
221 if (!kbuf)
222 return -ENOMEM;
223
224 if (longterm) {
225 ret = snprintf(kbuf, count, "Page pinned for %lld us\n",
226 record->elapsed);
227 } else {
228 s64 ts_usec = record->ts_usec;
> 229 unsigned long rem_usec = do_div(ts_usec, 1000000);
230
231 ret = snprintf(kbuf, count,
232 "Page pinned ts [%5lu.%06lu]\n",
233 (unsigned long)ts_usec, rem_usec);
234 }
235
236 if (ret >= count)
237 goto err;
238
239 /* Print information relevant to grouping pages by mobility */
240 ret += snprintf(kbuf + ret, count - ret,
241 "PFN %lu Block %lu type %s Flags %#lx(%pGp)\n",
242 record->pfn,
243 record->pfn >> pageblock_order,
244 migratetype_names[record->page_mt],
245 record->page_flags, &record->page_flags);
246
247 if (ret >= count)
248 goto err;
249
250 nr_entries = stack_depot_fetch(record->handle, &entries);
251 ret += stack_trace_snprint(kbuf + ret, count - ret, entries,
252 nr_entries, 0);
253 if (ret >= count)
254 goto err;
255
256 ret += snprintf(kbuf + ret, count - ret, "\n");
257 if (ret >= count)
258 goto err;
259
260 if (copy_to_user(buf, kbuf, ret))
261 ret = -EFAULT;
262
263 kfree(kbuf);
264 return ret;
265
266 err:
267 kfree(kbuf);
268 return -ENOMEM;
269 }
270
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 40595 bytes --]
reply other threads:[~2021-09-05 1:09 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=202109050949.faLn7c0Z-lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.