From: kernel test robot <lkp@intel.com>
To: Easwar Hariharan <eahariha@linux.microsoft.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: Re: [PATCH 09/16] xfs: convert timeouts to secs_to_jiffies()
Date: Thu, 30 Jan 2025 13:51:04 +0800 [thread overview]
Message-ID: <202501301334.NB6NszQR-lkp@intel.com> (raw)
In-Reply-To: <20250128-converge-secs-to-jiffies-part-two-v1-9-9a6ecf0b2308@linux.microsoft.com>
Hi Easwar,
kernel test robot noticed the following build warnings:
[auto build test WARNING on 9a87ce288fe30f268b3a598422fe76af9bb2c2d2]
url: https://github.com/intel-lab-lkp/linux/commits/Easwar-Hariharan/coccinelle-misc-secs_to_jiffies-Patch-expressions-too/20250129-022410
base: 9a87ce288fe30f268b3a598422fe76af9bb2c2d2
patch link: https://lore.kernel.org/r/20250128-converge-secs-to-jiffies-part-two-v1-9-9a6ecf0b2308%40linux.microsoft.com
patch subject: [PATCH 09/16] xfs: convert timeouts to secs_to_jiffies()
config: x86_64-buildonly-randconfig-006-20250129 (https://download.01.org/0day-ci/archive/20250130/202501301334.NB6NszQR-lkp@intel.com/config)
compiler: clang version 19.1.3 (https://github.com/llvm/llvm-project ab51eccf88f5321e7c60591c5546b254b6afab99)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250130/202501301334.NB6NszQR-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202501301334.NB6NszQR-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> fs/xfs/xfs_sysfs.c:572:31: warning: result of comparison of constant 9223372036854775807 with expression of type 'int' is always true [-Wtautological-constant-out-of-range-compare]
572 | ASSERT(secs_to_jiffies(val) < LONG_MAX);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~
fs/xfs/xfs_linux.h:224:10: note: expanded from macro 'ASSERT'
224 | (likely(expr) ? (void)0 : assfail(NULL, #expr, __FILE__, __LINE__))
| ~~~~~~~^~~~~
include/linux/compiler.h:76:40: note: expanded from macro 'likely'
76 | # define likely(x) __builtin_expect(!!(x), 1)
| ^
1 warning generated.
vim +/int +572 fs/xfs/xfs_sysfs.c
549
550 static ssize_t
551 retry_timeout_seconds_store(
552 struct kobject *kobject,
553 const char *buf,
554 size_t count)
555 {
556 struct xfs_error_cfg *cfg = to_error_cfg(kobject);
557 int ret;
558 int val;
559
560 ret = kstrtoint(buf, 0, &val);
561 if (ret)
562 return ret;
563
564 /* 1 day timeout maximum, -1 means infinite */
565 if (val < -1 || val > 86400)
566 return -EINVAL;
567
568 if (val == -1)
569 cfg->retry_timeout = XFS_ERR_RETRY_FOREVER;
570 else {
571 cfg->retry_timeout = secs_to_jiffies(val);
> 572 ASSERT(secs_to_jiffies(val) < LONG_MAX);
573 }
574 return count;
575 }
576 XFS_SYSFS_ATTR_RW(retry_timeout_seconds);
577
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
parent reply other threads:[~2025-01-30 5:51 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <20250128-converge-secs-to-jiffies-part-two-v1-9-9a6ecf0b2308@linux.microsoft.com>]
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=202501301334.NB6NszQR-lkp@intel.com \
--to=lkp@intel.com \
--cc=eahariha@linux.microsoft.com \
--cc=llvm@lists.linux.dev \
--cc=oe-kbuild-all@lists.linux.dev \
/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