From patchwork Thu May 19 10:52:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Kara X-Patchwork-Id: 12854784 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 75AC7C433FE for ; Thu, 19 May 2022 10:52:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236896AbiESKwt (ORCPT ); Thu, 19 May 2022 06:52:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34148 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236931AbiESKwn (ORCPT ); Thu, 19 May 2022 06:52:43 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CF922AF1C3 for ; Thu, 19 May 2022 03:52:39 -0700 (PDT) Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out2.suse.de (Postfix) with ESMTP id 5FC7B1F97E; Thu, 19 May 2022 10:52:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1652957558; h=from:from:reply-to: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=l4k+ZSfjAneIX0NUGcevC9JYmxk8Z92Md3R2Cx0luj4=; b=Oj4fcOJIDoiOxRQvo5FALdkMjz69MXn4GkFArPniPVr28v8TMpk/mseeqIH+5sFG3Ctnmm nQE/0vdTc05bIb9g1oIPXfVykt3UVhziH7P7+s9me+blp6YCAwxZ1NylMkVcmSNVbCT8G7 1tSh54bNzhrkZLbj4P4SICRlJ3BBxOg= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1652957558; h=from:from:reply-to: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=l4k+ZSfjAneIX0NUGcevC9JYmxk8Z92Md3R2Cx0luj4=; b=C+bccho4EiFflejyhU0GAb0knxFdgaR0CLvHfw7GUDLPfVCPX6IqIZ53ZjxxNMo1MU+JpU kIyyKtPjx7bYLvDg== Received: from quack3.suse.cz (unknown [10.100.224.230]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id 50E9A2C146; Thu, 19 May 2022 10:52:38 +0000 (UTC) Received: by quack3.suse.cz (Postfix, from userid 1000) id 75A20A0620; Thu, 19 May 2022 12:52:35 +0200 (CEST) From: Jan Kara To: Paolo Valente Cc: , Jens Axboe , Jan Kara Subject: [PATCH 1/4] bfq: Relax waker detection for shared queues Date: Thu, 19 May 2022 12:52:29 +0200 Message-Id: <20220519105235.31397-1-jack@suse.cz> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20220519104621.15456-1-jack@suse.cz> References: <20220519104621.15456-1-jack@suse.cz> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=3150; h=from:subject; bh=XDqySJNqIGwoVns1eEnbv4pEyftTIPtZP+hQYSYPkbc=; b=owEBbQGS/pANAwAIAZydqgc/ZEDZAcsmYgBihiFs5RJaTwuVAMxPEKz6t8p6ejjgwQwmy13FbMyJ HZ3vM9KJATMEAAEIAB0WIQSrWdEr1p4yirVVKBycnaoHP2RA2QUCYoYhbAAKCRCcnaoHP2RA2XWIB/ 9XwI/x+SfyBUJnMchZGlyP3K4NieVllI556DTugR+hdDCJ5bqYl+HeDSmf+OWl3DAsr0s0hPUYpzw/ 5aPiUKUOcWkDLezh+lIn+C+KC3tLn4tQTfwHUiTmM76hpgeWGMNphxrHV1k36XOOzXS4XRhgCibo7n WjsRhZDEGl3UxIT5a9P0uaNsB73aBVQJBRgj3QdbQsX9hw4xuF+t8gZoCLyYScF3kH+McZEDaz7jas AZe2ctVqeHqtGsbts7lh0q31yL4fKfxXnNQpSR6bP30T5YiYUIEmiJw7waWOsiIw0gk9D9wM4NA3wO IunPVt2NbhjtsRuM+0aVq6nmiEiXIY X-Developer-Key: i=jack@suse.cz; a=openpgp; fpr=93C6099A142276A28BBE35D815BC833443038D8C Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Currently we look for waker only if current queue has no requests. This makes sense for bfq queues with a single process however for shared queues when there is a larger number of processes the condition that queue has no requests is difficult to meet because often at least one process has some request in flight although all the others are waiting for the waker to do the work and this harms throughput. Relax the "no queued request for bfq queue" condition to "the current task has no queued requests yet". For this, we also need to start tracking number of requests in flight for each task. This patch (together with the following one) restores the performance for dbench with 128 clients that regressed with commit c65e6fd460b4 ("bfq: Do not let waker requests skip proper accounting") because this commit makes requests of wakers properly enter BFQ queues and thus these queues become ineligible for the old waker detection logic. Dbench results: Vanilla 5.18-rc3 5.18-rc3 + revert 5.18-rc3 patched Mean 1237.36 ( 0.00%) 950.16 * 23.21%* 988.35 * 20.12%* Numbers are time to complete workload so lower is better. Fixes: c65e6fd460b4 ("bfq: Do not let waker requests skip proper accounting") Signed-off-by: Jan Kara --- block/bfq-iosched.c | 5 +++-- block/bfq-iosched.h | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/block/bfq-iosched.c b/block/bfq-iosched.c index 2e0dd68a3cbe..397f6be3c8fe 100644 --- a/block/bfq-iosched.c +++ b/block/bfq-iosched.c @@ -2127,7 +2127,6 @@ static void bfq_check_waker(struct bfq_data *bfqd, struct bfq_queue *bfqq, if (!bfqd->last_completed_rq_bfqq || bfqd->last_completed_rq_bfqq == bfqq || bfq_bfqq_has_short_ttime(bfqq) || - bfqq->dispatched > 0 || now_ns - bfqd->last_completion >= 4 * NSEC_PER_MSEC || bfqd->last_completed_rq_bfqq == bfqq->waker_bfqq) return; @@ -2204,7 +2203,7 @@ static void bfq_add_request(struct request *rq) bfqq->queued[rq_is_sync(rq)]++; bfqd->queued++; - if (RB_EMPTY_ROOT(&bfqq->sort_list) && bfq_bfqq_sync(bfqq)) { + if (bfq_bfqq_sync(bfqq) && RQ_BIC(rq)->requests <= 1) { bfq_check_waker(bfqd, bfqq, now_ns); /* @@ -6557,6 +6556,7 @@ static void bfq_finish_requeue_request(struct request *rq) bfq_completed_request(bfqq, bfqd); } bfq_finish_requeue_request_body(bfqq); + RQ_BIC(rq)->requests--; spin_unlock_irqrestore(&bfqd->lock, flags); /* @@ -6790,6 +6790,7 @@ static struct bfq_queue *bfq_init_rq(struct request *rq) bfqq_request_allocated(bfqq); bfqq->ref++; + bic->requests++; bfq_log_bfqq(bfqd, bfqq, "get_request %p: bfqq %p, %d", rq, bfqq, bfqq->ref); diff --git a/block/bfq-iosched.h b/block/bfq-iosched.h index 3b83e3d1c2e5..25fada961bc9 100644 --- a/block/bfq-iosched.h +++ b/block/bfq-iosched.h @@ -468,6 +468,7 @@ struct bfq_io_cq { struct bfq_queue *stable_merge_bfqq; bool stably_merged; /* non splittable if true */ + unsigned int requests; /* Number of requests this process has in flight */ }; /** From patchwork Thu May 19 10:52:30 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Kara X-Patchwork-Id: 12854782 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id ED365C43219 for ; Thu, 19 May 2022 10:52:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236918AbiESKws (ORCPT ); Thu, 19 May 2022 06:52:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34146 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236896AbiESKwn (ORCPT ); Thu, 19 May 2022 06:52:43 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CF725AF1C0 for ; Thu, 19 May 2022 03:52:39 -0700 (PDT) Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out2.suse.de (Postfix) with ESMTP id 5AE411F86C; Thu, 19 May 2022 10:52:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1652957558; h=from:from:reply-to: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=hpmc3+ltFkrwjxVrsDq9b68XJYDCoIbRnV55KYes/J0=; b=S8GWAp4C59TynWccHd/sCVEJDMyaS3KDeuHoYYOvDDnnBh/+wQcaGD68Q0erU5j21Dz5F9 9Usbn9/RnN6pSZXI4IH3uEPgQ6cDEAsX8Sv2UziooL4MVlVRuInKKChdlNMZxZqJSEUdGN RIV5uPDnvxKs5XkrKCr6/MuKZsZEqSg= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1652957558; h=from:from:reply-to: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=hpmc3+ltFkrwjxVrsDq9b68XJYDCoIbRnV55KYes/J0=; b=bbFcJLcfD2UPw19y8MTymlU5HJX7/+TzWJr85Ir13AkFLn1TimQYGSAvUe3LqHww8AmkxG rFD2F2MnZ62BVtBA== Received: from quack3.suse.cz (unknown [10.100.224.230]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id 4E9C92C145; Thu, 19 May 2022 10:52:38 +0000 (UTC) Received: by quack3.suse.cz (Postfix, from userid 1000) id 7D980A0632; Thu, 19 May 2022 12:52:35 +0200 (CEST) From: Jan Kara To: Paolo Valente Cc: , Jens Axboe , Jan Kara Subject: [PATCH 2/4] bfq: Allow current waker to defend against a tentative one Date: Thu, 19 May 2022 12:52:30 +0200 Message-Id: <20220519105235.31397-2-jack@suse.cz> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20220519104621.15456-1-jack@suse.cz> References: <20220519104621.15456-1-jack@suse.cz> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1097; h=from:subject; bh=3MpNAaGjm1nnlvDF9v3+ueqmLrswHCe4Feive2e0iis=; b=owEBbQGS/pANAwAIAZydqgc/ZEDZAcsmYgBihiFtMgd4yOJUG3VqNPgYQbRfgadh1iAwUjYVYyzc 06zjfrSJATMEAAEIAB0WIQSrWdEr1p4yirVVKBycnaoHP2RA2QUCYoYhbQAKCRCcnaoHP2RA2dd3CA DaVEHx1qvOvcjwznvpv6qBHooTTdiDcjIsAazjOBuab+mGlmNF6JdXIFGAoNxMaRe3od/KGzfJEeA7 /UxxSLQho7RjLh9SMJMLrOViID7vK7Ds3rwtNhhYSbhq9wm0AOV92jx/ED9UrQUhWEMIndNafK2p9F Dis0q0kx+ffORtd8HJaopSuS+1pKU+LF7gV+sh0yxTkThUJmkOe2HgzvXYpP5anjicqHd0bwlI8ZUU qnOQEzDVfMmATaeWLQvXOjqHIPFVarQDS4egxxya4/b+w8VesH0brrHXP7jSO+45LLubHuFl5Mmiu5 duxtcNxgnHFWsx9dBqGtHKAkgiJR25 X-Developer-Key: i=jack@suse.cz; a=openpgp; fpr=93C6099A142276A28BBE35D815BC833443038D8C Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org The code in bfq_check_waker() ignores wake up events from the current waker. This makes it more likely we select a new tentative waker although the current one is generating more wake up events. Treat current waker the same way as any other process and allow it to reset the waker detection logic. Fixes: 71217df39dc6 ("block, bfq: make waker-queue detection more robust") Signed-off-by: Jan Kara --- block/bfq-iosched.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/block/bfq-iosched.c b/block/bfq-iosched.c index 397f6be3c8fe..1cc242c90fb6 100644 --- a/block/bfq-iosched.c +++ b/block/bfq-iosched.c @@ -2127,8 +2127,7 @@ static void bfq_check_waker(struct bfq_data *bfqd, struct bfq_queue *bfqq, if (!bfqd->last_completed_rq_bfqq || bfqd->last_completed_rq_bfqq == bfqq || bfq_bfqq_has_short_ttime(bfqq) || - now_ns - bfqd->last_completion >= 4 * NSEC_PER_MSEC || - bfqd->last_completed_rq_bfqq == bfqq->waker_bfqq) + now_ns - bfqd->last_completion >= 4 * NSEC_PER_MSEC) return; /* From patchwork Thu May 19 10:52:31 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Kara X-Patchwork-Id: 12854781 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EF34AC433FE for ; Thu, 19 May 2022 10:52:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234382AbiESKwr (ORCPT ); Thu, 19 May 2022 06:52:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34140 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236888AbiESKwn (ORCPT ); Thu, 19 May 2022 06:52:43 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CE6ABAEE2D for ; Thu, 19 May 2022 03:52:39 -0700 (PDT) Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out1.suse.de (Postfix) with ESMTP id 56BAA219AD; Thu, 19 May 2022 10:52:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1652957558; h=from:from:reply-to: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=AcYU44NRF+VRVNxo1CHlAkQziojCs0+/JS9pbMcerqE=; b=2VZINmBMRTbNPda0ZzIVn6/bO/8NMYyHkzrz7LeFFqcf/+YXJTT4FaNY0wHJhE7g54nmrb 4F01eq9anzmA0suFFcCuqmMf9vIwM8D7wFP0iqHf0i0ynZcwiVYcCQ98xQgOnt6sWIzfMl w451hmMCiP+kJF0HVeMbBXaZFByadDA= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1652957558; h=from:from:reply-to: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=AcYU44NRF+VRVNxo1CHlAkQziojCs0+/JS9pbMcerqE=; b=qRe1jrvZcJhk+M8ArHIj9x/YzLaM+jGbzgwsv2HZa9P/tx6WfjsYa4o3qUnVyR08T+2lgL Z7hUKRWZ/ScvQPBg== Received: from quack3.suse.cz (unknown [10.100.224.230]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id 4C4F12C143; Thu, 19 May 2022 10:52:38 +0000 (UTC) Received: by quack3.suse.cz (Postfix, from userid 1000) id 836ACA0633; Thu, 19 May 2022 12:52:35 +0200 (CEST) From: Jan Kara To: Paolo Valente Cc: , Jens Axboe , Jan Kara Subject: [PATCH 3/4] bfq: Remove superfluous conversion from RQ_BIC() Date: Thu, 19 May 2022 12:52:31 +0200 Message-Id: <20220519105235.31397-3-jack@suse.cz> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20220519104621.15456-1-jack@suse.cz> References: <20220519104621.15456-1-jack@suse.cz> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=893; h=from:subject; bh=RSV/+NRnH3Zfn+UVJqgtLy0C3J+V8YNDKHFHlL9H7h8=; b=owEBbQGS/pANAwAIAZydqgc/ZEDZAcsmYgBihiFuZG608ClQI9xPIDfrCKiu7hQBOjzrQnGpJnsc S+zgaDyJATMEAAEIAB0WIQSrWdEr1p4yirVVKBycnaoHP2RA2QUCYoYhbgAKCRCcnaoHP2RA2QfUB/ 9LqxvLo/WrXuQG/lYPKKfo0h5ZcSEFQU6moGF831upmO0GEO7Fctk3Wfo+e86x4hHEnCrJ+7xoCITN pccg59Vs4YvjWNsvPJp4AfuGnERdZ8t27RjriOySTaMrzRf2pnM9sA9AeZvBpEMVKrx0s2iYQBLMa6 MW9K3WAhOqlrX9wtTUZDDkZrG53YgvP8exOrfeDAparkoMnwmqDe0qgIB+MiqsS4A9wiDUGVz5Hs64 tSJgOdUFAhl9LsAn+97cyZs1AkCsuPB23xEAWqS0KNBOiccdxKssBoj+EJ1cLCFDyjpNYjO76ksWYZ 1/hIANDzYQqsgUAZpgfa5FUVY6dQ3L X-Developer-Key: i=jack@suse.cz; a=openpgp; fpr=93C6099A142276A28BBE35D815BC833443038D8C Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org We store struct bfq_io_cq pointer in rq->elv.priv[0] in bfq_init_rq(). Thus a call to icq_to_bic() in RQ_BIC() is wrong. Luckily it does no harm currently because struct io_iq is the first one in struct bfq_io_cq. Signed-off-by: Jan Kara --- block/bfq-iosched.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/bfq-iosched.c b/block/bfq-iosched.c index 1cc242c90fb6..904fe56495ce 100644 --- a/block/bfq-iosched.c +++ b/block/bfq-iosched.c @@ -374,7 +374,7 @@ static const unsigned long bfq_activation_stable_merging = 600; */ static const unsigned long bfq_late_stable_merging = 600; -#define RQ_BIC(rq) icq_to_bic((rq)->elv.priv[0]) +#define RQ_BIC(rq) ((struct bfq_io_cq *)((rq)->elv.priv[0])) #define RQ_BFQQ(rq) ((rq)->elv.priv[1]) struct bfq_queue *bic_to_bfqq(struct bfq_io_cq *bic, bool is_sync) From patchwork Thu May 19 10:52:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Kara X-Patchwork-Id: 12854783 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 54760C433EF for ; Thu, 19 May 2022 10:52:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236888AbiESKws (ORCPT ); Thu, 19 May 2022 06:52:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34144 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236918AbiESKwn (ORCPT ); Thu, 19 May 2022 06:52:43 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CF4A1AEE34 for ; Thu, 19 May 2022 03:52:39 -0700 (PDT) Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out2.suse.de (Postfix) with ESMTP id 5637C1F86B; Thu, 19 May 2022 10:52:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1652957558; h=from:from:reply-to: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=fg677vFI7lCltTpQm+6fkXpOi2PLcsYb0DZ0AhFMni0=; b=pfWiLddc4Y64Ic53l2Nu6M7s90z66iY/ZTea7+kb0PRrDdPwlVMUg7M3xBSna6Ux6f20Pq YTf38CuIQvYgI4p0KlI7uvZZhe+GCBcjzlOSnuaSbiJNJeYMtD7AXZJRXC/DrqISyZqhKR TbbrppaY2aB8mVQynsde1Qz4ocHWKtI= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1652957558; h=from:from:reply-to: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=fg677vFI7lCltTpQm+6fkXpOi2PLcsYb0DZ0AhFMni0=; b=qx4HyaNRVVQgD0pVBtsUkKQXF0iJJN0K4D9KzfxRRrT+AbbWcbGxKtCDE8Yn9l6eFdbukL ZIpOHqQoSv08D9CA== Received: from quack3.suse.cz (unknown [10.100.224.230]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id 491D02C142; Thu, 19 May 2022 10:52:38 +0000 (UTC) Received: by quack3.suse.cz (Postfix, from userid 1000) id 8A4ACA0634; Thu, 19 May 2022 12:52:35 +0200 (CEST) From: Jan Kara To: Paolo Valente Cc: , Jens Axboe , Jan Kara Subject: [PATCH 4/4] bfq: Remove bfq_requeue_request_body() Date: Thu, 19 May 2022 12:52:32 +0200 Message-Id: <20220519105235.31397-4-jack@suse.cz> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20220519104621.15456-1-jack@suse.cz> References: <20220519104621.15456-1-jack@suse.cz> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1145; h=from:subject; bh=YG1rQ0Gh4ujxaNXAwLRG4EsZFC+ssY7mez/N4UeBGtA=; b=owEBbQGS/pANAwAIAZydqgc/ZEDZAcsmYgBihiFvDIanD8kUTR5sGtO4m+5GYcCR93Oy+oAEFOgy AH3TN+qJATMEAAEIAB0WIQSrWdEr1p4yirVVKBycnaoHP2RA2QUCYoYhbwAKCRCcnaoHP2RA2eEhCA CFDNTzt5la2Kv+QSv++Jg2RFCq/BWDrbZniRe4bvOOZ6RE30SNwI+FcBGOvWqcNIvYzKW0eoZmDfwK CWFIeW9MIG8FDYM84IUIejYg3PIpsvl5w9iBeKsFC30b6RA18vYm8PpYUPVXMRZwn2Fem63aOhh4Pn MTmvsAx+veslEubMMsMV8GGPTQ9Xz91O42CMc67HaEoVoC9CQDw5GRftQkZwwLM2XocbGBZ/0G9wD5 JGuvNZBLp0zv4PdpCNzqM4U6vhbrNp4cLmGxxOICh4t+nnbgrCyPh+sDSURVNbpqPOP6VhytcGSDQY Lwks3JwaRb6gR2d/0fV1wSKPHr2gKD X-Developer-Key: i=jack@suse.cz; a=openpgp; fpr=93C6099A142276A28BBE35D815BC833443038D8C Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org The function has only a single caller and two lines. Just remove it since it is pointless and just harming readability. Signed-off-by: Jan Kara --- block/bfq-iosched.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/block/bfq-iosched.c b/block/bfq-iosched.c index 904fe56495ce..a1127dfe647e 100644 --- a/block/bfq-iosched.c +++ b/block/bfq-iosched.c @@ -6352,12 +6352,6 @@ static void bfq_completed_request(struct bfq_queue *bfqq, struct bfq_data *bfqd) bfq_schedule_dispatch(bfqd); } -static void bfq_finish_requeue_request_body(struct bfq_queue *bfqq) -{ - bfqq_request_freed(bfqq); - bfq_put_queue(bfqq); -} - /* * The processes associated with bfqq may happen to generate their * cumulative I/O at a lower rate than the rate at which the device @@ -6554,7 +6548,8 @@ static void bfq_finish_requeue_request(struct request *rq) bfq_completed_request(bfqq, bfqd); } - bfq_finish_requeue_request_body(bfqq); + bfqq_request_freed(bfqq); + bfq_put_queue(bfqq); RQ_BIC(rq)->requests--; spin_unlock_irqrestore(&bfqd->lock, flags);