Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp11269922rwl; Mon, 2 Jan 2023 17:57:57 -0800 (PST) X-Google-Smtp-Source: AMrXdXvMqE4JlQK7jcUYQVPB+3IHhOH5Y8QVifUd84tUcn6Sbn+mu/P2sY6cGz6MQNJ5pMRZLOpM X-Received: by 2002:a05:6402:220e:b0:483:a6d8:7ad with SMTP id cq14-20020a056402220e00b00483a6d807admr25174867edb.24.1672711077484; Mon, 02 Jan 2023 17:57:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1672711077; cv=none; d=google.com; s=arc-20160816; b=TkJe7Pc1NkP115MMzitHoS/4Nm9Qxx5j5CBqhJ8l/S1HA9ZBJY1nVoBYlqAowtD5AR X3x/6SScyI+lFNcDTYyRxxfDhkjT7CEEXmQmXoX7UiJyQGY/5aph1rX41Kix8WQViU3T 4Ar8+K80t4MkPduZn8HKuYZX67qE+9ESx9yrmiGmttT/o5Cs+KvEJx+ygNf9zRdrCpdW OwpAitnmSpSpiQ2VuGZpLwkBtbnWRgA90t4NPVmLZxQ9tx+n3D/07yQWJ5TDkUMGWwLJ lix6I9zBZZ8R+l7R+d0TZDUIaSwHVA8ZPscsn/b6X5ey3eHWMFgidM3JkO1xb9x6sUAS XuKA== 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; bh=IrsfoVhGeJcthQ0zAuY6F2oPIuc7fblYYMp7L42TEmg=; b=l2NWZgYnwhdWF5ryYFRPZGnlBXSvGOqmkdeTX9BpQJkWxfjcrL/HhBHcg+EkxborE2 x1OwpCpshe+8zk6Q/B6YrdE6Mjfpp4Ayp+6DyQZn2ezucnoepTIKNhY0r+xuoDqxjGEt K4McCNhjlOtkxTHAF9a+xgjG6ho/uBDKDKu2QBopL4emU++t8/ru/myck0WooKAyR5Jj ZcPsljivGW2St4zzANEfB8jzVbQfFaj5kuRfSNBKoRQDl1mwmb8Zv+3pnHzhfqq90Qep 1sOYF+M3dx9gkCYBUL3L/pHwozK8N/QALqfmaBY/zhLGtmTVjkH3ATCuDPmkpZEeVi7y O9xA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h7-20020a056402280700b0046b7410c015si31267304ede.18.2023.01.02.17.57.42; Mon, 02 Jan 2023 17:57:57 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236650AbjACBzR (ORCPT + 62 others); Mon, 2 Jan 2023 20:55:17 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53908 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236497AbjACByZ (ORCPT ); Mon, 2 Jan 2023 20:54:25 -0500 Received: from dggsgout11.his.huawei.com (unknown [45.249.212.51]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8416C7663; Mon, 2 Jan 2023 17:54:24 -0800 (PST) Received: from mail02.huawei.com (unknown [172.30.67.153]) by dggsgout11.his.huawei.com (SkyGuard) with ESMTP id 4NmG4W2ghMz4f3lXY; Tue, 3 Jan 2023 09:54:19 +0800 (CST) Received: from huaweicloud.com (unknown [10.175.124.27]) by APP4 (Coremail) with SMTP id gCh0CgBHr7LJirNj9wMDBA--.19481S9; Tue, 03 Jan 2023 09:54:21 +0800 (CST) From: Kemeng Shi To: jack@suse.com, paolo.valente@linaro.org, axboe@kernel.dk Cc: hch@lst.de, damien.lemoal@opensource.wdc.com, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 7/8] block, bfq: remove unnecessary goto tag in bfq_dispatch_rq_from_bfqq Date: Tue, 3 Jan 2023 17:53:02 +0800 Message-Id: <20230103095303.2223546-8-shikemeng@huaweicloud.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20230103095303.2223546-1-shikemeng@huaweicloud.com> References: <20230103095303.2223546-1-shikemeng@huaweicloud.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CM-TRANSID: gCh0CgBHr7LJirNj9wMDBA--.19481S9 X-Coremail-Antispam: 1UD129KBjvdXoWruF4UWF4DWFyxKr47GF15urg_yoWkZFcEyF 4kKr9YyrWkCFZ8Wr4YkF4DJF4DAFW2va1DJF1Fg3y2gF17t3ZYy3sFqrsxCa95WFWIkFyY qFs0q343Jr1UXjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUbSxYFVCjjxCrM7AC8VAFwI0_Wr0E3s1l1xkIjI8I6I8E6xAIw20E Y4v20xvaj40_Wr0E3s1l1IIY67AEw4v_Jr0_Jr4l87I20VAvwVAaII0Ic2I_JFv_Gryl82 xGYIkIc2x26280x7IE14v26r126s0DM28IrcIa0xkI8VCY1x0267AKxVW5JVCq3wA2ocxC 64kIII0Yj41l84x0c7CEw4AK67xGY2AK021l84ACjcxK6xIIjxv20xvE14v26w1j6s0DM2 8EF7xvwVC0I7IYx2IY6xkF7I0E14v26r4UJVWxJr1l84ACjcxK6I8E87Iv67AKxVW0oVCq 3wA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_GcCE3s1le2I262IYc4CY6c8Ij28IcVAaY2xG8w Aqx4xG64xvF2IEw4CE5I8CrVC2j2WlYx0E2Ix0cI8IcVAFwI0_Jr0_Jr4lYx0Ex4A2jsIE 14v26r1j6r4UMcvjeVCFs4IE7xkEbVWUJVW8JwACjcxG0xvY0x0EwIxGrwCF04k20xvY0x 0EwIxGrwCFx2IqxVCFs4IE7xkEbVWUJVW8JwC20s026c02F40E14v26r1j6r18MI8I3I0E 7480Y4vE14v26r106r1rMI8E67AF67kF1VAFwI0_JF0_Jw1lIxkGc2Ij64vIr41lIxAIcV C0I7IYx2IY67AKxVWUCVW8JwCI42IY6xIIjxv20xvEc7CjxVAFwI0_Cr0_Gr1UMIIF0xvE 42xK8VAvwI8IcIk0rVWUJVWUCwCI42IY6I8E87Iv67AKxVWUJVW8JwCI42IY6I8E87Iv6x kF7I0E14v26r4j6r4UJbIYCTnIWIevJa73UjIFyTuYvjxUIL05UUUUU X-CM-SenderInfo: 5vklyvpphqwq5kxd4v5lfo033gof0z/ X-CFilter-Loop: Reflected X-Spam-Status: No, score=0.0 required=5.0 tests=BAYES_00,DATE_IN_FUTURE_06_12, SPF_HELO_NONE,SPF_PASS autolearn=ham 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 We jump to tag only for returning current rq. Return directly to remove this tag. Signed-off-by: Kemeng Shi --- block/bfq-iosched.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/block/bfq-iosched.c b/block/bfq-iosched.c index 9ff424c78e9b..a11be312ac77 100644 --- a/block/bfq-iosched.c +++ b/block/bfq-iosched.c @@ -4966,7 +4966,7 @@ static struct request *bfq_dispatch_rq_from_bfqq(struct bfq_data *bfqd, bfq_dispatch_remove(bfqd->queue, rq); if (bfqq != bfqd->in_service_queue) - goto return_rq; + return rq; /* * If weight raising has to terminate for bfqq, then next @@ -4986,12 +4986,9 @@ static struct request *bfq_dispatch_rq_from_bfqq(struct bfq_data *bfqd, * belongs to CLASS_IDLE and other queues are waiting for * service. */ - if (!(bfq_tot_busy_queues(bfqd) > 1 && bfq_class_idle(bfqq))) - goto return_rq; + if (bfq_tot_busy_queues(bfqd) > 1 && bfq_class_idle(bfqq)) + bfq_bfqq_expire(bfqd, bfqq, false, BFQQE_BUDGET_EXHAUSTED); - bfq_bfqq_expire(bfqd, bfqq, false, BFQQE_BUDGET_EXHAUSTED); - -return_rq: return rq; } -- 2.30.0