From: Alex Elder <elder@ieee.org>
To: Yuesong Li <liyuesong@vivo.com>,
Ilya Dryomov <idryomov@gmail.com>, Xiubo Li <xiubli@redhat.com>,
ceph-devel@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: opensource.kernel@vivo.com
Subject: Re: [PATCH v1] ceph: convert to use secs_to_jiffies
Date: Fri, 13 Jun 2025 08:37:45 -0500 [thread overview]
Message-ID: <9dfa0d6b-e28d-4e83-acd0-1ad7803d2387@ieee.org> (raw)
In-Reply-To: <20250613102322.3074153-1-liyuesong@vivo.com>
On 6/13/25 5:23 AM, Yuesong Li wrote:
> Since secs_to_jiffies()(commit:b35108a51cf7) has been introduced, we can
> use it to avoid scaling the time to msec.
>
> Signed-off-by: Yuesong Li <liyuesong@vivo.com>
Looks good.
Reviewed-by: Alex Elder <elder@riscstar.com>
> ---
> net/ceph/ceph_common.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/net/ceph/ceph_common.c b/net/ceph/ceph_common.c
> index 4c6441536d55..9ef326b0d50e 100644
> --- a/net/ceph/ceph_common.c
> +++ b/net/ceph/ceph_common.c
> @@ -530,26 +530,26 @@ int ceph_parse_param(struct fs_parameter *param, struct ceph_options *opt,
> if (result.uint_32 < 1 || result.uint_32 > INT_MAX / 1000)
> goto out_of_range;
> opt->osd_keepalive_timeout =
> - msecs_to_jiffies(result.uint_32 * 1000);
> + secs_to_jiffies(result.uint_32);
> break;
> case Opt_osd_idle_ttl:
> /* 0 isn't well defined right now, reject it */
> if (result.uint_32 < 1 || result.uint_32 > INT_MAX / 1000)
> goto out_of_range;
> - opt->osd_idle_ttl = msecs_to_jiffies(result.uint_32 * 1000);
> + opt->osd_idle_ttl = secs_to_jiffies(result.uint_32);
> break;
> case Opt_mount_timeout:
> /* 0 is "wait forever" (i.e. infinite timeout) */
> if (result.uint_32 > INT_MAX / 1000)
> goto out_of_range;
> - opt->mount_timeout = msecs_to_jiffies(result.uint_32 * 1000);
> + opt->mount_timeout = secs_to_jiffies(result.uint_32);
> break;
> case Opt_osd_request_timeout:
> /* 0 is "wait forever" (i.e. infinite timeout) */
> if (result.uint_32 > INT_MAX / 1000)
> goto out_of_range;
> opt->osd_request_timeout =
> - msecs_to_jiffies(result.uint_32 * 1000);
> + secs_to_jiffies(result.uint_32);
> break;
>
> case Opt_share:
prev parent reply other threads:[~2025-06-13 13:37 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-13 10:23 Yuesong Li
2025-06-13 13:37 ` Alex Elder [this message]
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=9dfa0d6b-e28d-4e83-acd0-1ad7803d2387@ieee.org \
--to=elder@ieee.org \
--cc=ceph-devel@vger.kernel.org \
--cc=idryomov@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=liyuesong@vivo.com \
--cc=opensource.kernel@vivo.com \
--cc=xiubli@redhat.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®