summaryrefslogtreecommitdiff
path: root/fs/ceph
diff options
context:
space:
mode:
authorXiubo Li <xiubli@redhat.com>2023-07-20 11:33:55 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-08-03 10:22:46 +0200
commit7c9b8cca49176232f155ddbd78bb8066defec551 (patch)
tree4bbfc075b1b0d71a582276b7003da3562b687613 /fs/ceph
parente443b3a508b0bb228e4f5291442dbffbb18ce786 (diff)
downloadlinux-7c9b8cca49176232f155ddbd78bb8066defec551.tar.gz
linux-7c9b8cca49176232f155ddbd78bb8066defec551.tar.bz2
linux-7c9b8cca49176232f155ddbd78bb8066defec551.zip
ceph: never send metrics if disable_send_metrics is set
commit 50164507f6b7b7ed85d8c3ac0266849fbd908db7 upstream. Even the 'disable_send_metrics' is true so when the session is being opened it will always trigger to send the metric for the first time. Cc: stable@vger.kernel.org Signed-off-by: Xiubo Li <xiubli@redhat.com> Reviewed-by: Venky Shankar <vshankar@redhat.com> Reviewed-by: Jeff Layton <jlayton@kernel.org> Signed-off-by: Ilya Dryomov <idryomov@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/ceph')
-rw-r--r--fs/ceph/metric.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ceph/metric.c b/fs/ceph/metric.c
index 04d5df29bbbf..d21ff4354332 100644
--- a/fs/ceph/metric.c
+++ b/fs/ceph/metric.c
@@ -202,7 +202,7 @@ static void metric_delayed_work(struct work_struct *work)
struct ceph_mds_client *mdsc =
container_of(m, struct ceph_mds_client, metric);
- if (mdsc->stopping)
+ if (mdsc->stopping || disable_send_metrics)
return;
if (!m->session || !check_session_state(m->session)) {