Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp5326126rdb; Wed, 13 Dec 2023 05:51:24 -0800 (PST) X-Google-Smtp-Source: AGHT+IF2rvaQqry1m0u5dV6xAEzryJuQqHCFzDcRk9SxPn2CL1IBTIN9ciBj2GQNI0B3b7x2ML6n X-Received: by 2002:a05:6a00:14c4:b0:6ce:696f:d0f5 with SMTP id w4-20020a056a0014c400b006ce696fd0f5mr4760977pfu.31.1702475483735; Wed, 13 Dec 2023 05:51:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702475483; cv=none; d=google.com; s=arc-20160816; b=EGfH9Jcz/+sjyoRLCUw9WPtfHk3Kln0UWcyK5AFVd9kucjAPh05KDTfntDCcaKCWvv rW630d4ka5C+TcxCQoR4v2ZMn41sp4UUB/m1jsOkPGIMt0Z3H5j6SNWxHP9x7DF3JrnC 7g+EjkHwlSW8xTYTlhCT4gtl5iveIosFeSWRl08eDRiGvacAz3rUoAdhjDqzdvf4mTZS 0qECObxiv3vh3R9/1dPVynHdU+KnYeIUtZ/KNuZRmNQ6s3+gG4mjGFaK/hi5+hgnryLY cyZB6hkEmUCU0jTx8DD8HIOZ+X6BwdqDWNxtBNM4soZbGkh/h6cn5g4vrjsg6OSbnXEu 0PAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=mwRJi2sCnG34wTz+6X85LZ5bO1xW/kuUkUV8gU/er0M=; fh=9hT4l0EMR1D2zdgUoRXiqFwsybSJyrmM/FC/blQlPsI=; b=xV2GWVmrOpoiFuZW/UdIr3dpxoo2Z1k8EYsgi0sBllxebcYWVCVNQwClzViy0tPNqW /esXDaTB1MxhZJoStImPaa0wDqFWt971U39EnnJ+ICeV1yc41/JnFX/ttIWapP4OIbdM WvOuI5cHvNQ+PmDkC+KVhNVLqWY22hHupuGVPKUNKWlItjeGdNQ2GbCxwNzXTzXfsr92 4hTVfoh/kFiSsEJM3Z5OFUQDj6A8IRSBO0WHQs7uYOQm8DqhNVLjnxdEWNg6ria7E0cZ CEc3UYGkXh8ovhO5Z60IpvuUOxj0P/q3RbZjrTndgHr9NAAVLZOe+ornwGsSdcIOKgYx iJ8g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b="GDKZcq/A"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id c2-20020a056a000ac200b006cb6fc94847si9661911pfl.172.2023.12.13.05.51.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Dec 2023 05:51:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b="GDKZcq/A"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 0BC9480C247A; Wed, 13 Dec 2023 05:51:04 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1379313AbjLMNud (ORCPT + 99 others); Wed, 13 Dec 2023 08:50:33 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34956 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1379265AbjLMNuX (ORCPT ); Wed, 13 Dec 2023 08:50:23 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DB310123 for ; Wed, 13 Dec 2023 05:50:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1702475426; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=mwRJi2sCnG34wTz+6X85LZ5bO1xW/kuUkUV8gU/er0M=; b=GDKZcq/Ab4e3r6Bon3L+1dcaDDxJOKrj9c3FgI9WgIFapDGFJFIBIXX/zy3pKDBHd6dyF3 qwhzNlMSDPSeKFTxpT4acu0lvJ0leMem7o55t+G5JtHzgjYLxn/lzIoueabwFq40RtW8vx UFClue8rvMAcs7DxIggiiHe9ZsT8LSg= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-325-cfUhRadEPFaaBvS2RUXciA-1; Wed, 13 Dec 2023 08:50:23 -0500 X-MC-Unique: cfUhRadEPFaaBvS2RUXciA-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id E4C068C46C2; Wed, 13 Dec 2023 13:50:22 +0000 (UTC) Received: from warthog.procyon.org.com (unknown [10.42.28.2]) by smtp.corp.redhat.com (Postfix) with ESMTP id 278D72166B32; Wed, 13 Dec 2023 13:50:22 +0000 (UTC) From: David Howells To: Marc Dionne Cc: David Howells , linux-afs@lists.infradead.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 10/40] afs: Don't skip server addresses for which we didn't get an RTT reading Date: Wed, 13 Dec 2023 13:49:32 +0000 Message-ID: <20231213135003.367397-11-dhowells@redhat.com> In-Reply-To: <20231213135003.367397-1-dhowells@redhat.com> References: <20231213135003.367397-1-dhowells@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.6 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Wed, 13 Dec 2023 05:51:04 -0800 (PST) In the rotation algorithms for iterating over volume location servers and file servers, don't skip servers from which we got a valid response to a probe (either a reply DATA packet or an ABORT) even if we didn't manage to get an RTT reading. Signed-off-by: David Howells cc: Marc Dionne cc: linux-afs@lists.infradead.org --- fs/afs/rotate.c | 2 +- fs/afs/vl_rotate.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/afs/rotate.c b/fs/afs/rotate.c index 59aed7a6dd11..d420f073300b 100644 --- a/fs/afs/rotate.c +++ b/fs/afs/rotate.c @@ -427,7 +427,7 @@ bool afs_select_fileserver(struct afs_operation *op) if (!test_bit(i, &op->untried) || !test_bit(AFS_SERVER_FL_RESPONDING, &s->flags)) continue; - if (s->probe.rtt < rtt) { + if (s->probe.rtt <= rtt) { op->index = i; rtt = s->probe.rtt; } diff --git a/fs/afs/vl_rotate.c b/fs/afs/vl_rotate.c index f8f255c966ae..6aaa2e4733ec 100644 --- a/fs/afs/vl_rotate.c +++ b/fs/afs/vl_rotate.c @@ -201,7 +201,7 @@ bool afs_select_vlserver(struct afs_vl_cursor *vc) if (!test_bit(i, &vc->untried) || !test_bit(AFS_VLSERVER_FL_RESPONDING, &s->flags)) continue; - if (s->probe.rtt < rtt) { + if (s->probe.rtt <= rtt) { vc->index = i; rtt = s->probe.rtt; }