From patchwork Wed Oct 19 12:15:12 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yu Kuai X-Patchwork-Id: 13011692 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 DA1CEC41535 for ; Wed, 19 Oct 2022 12:49:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232323AbiJSMt0 (ORCPT ); Wed, 19 Oct 2022 08:49:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32844 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233391AbiJSMtA (ORCPT ); Wed, 19 Oct 2022 08:49:00 -0400 Received: from dggsgout11.his.huawei.com (unknown [45.249.212.51]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0E088140FC; Wed, 19 Oct 2022 05:31:43 -0700 (PDT) Received: from mail02.huawei.com (unknown [172.30.67.153]) by dggsgout11.his.huawei.com (SkyGuard) with ESMTP id 4Mspvx4m1WzKHg0; Wed, 19 Oct 2022 19:50:53 +0800 (CST) Received: from huaweicloud.com (unknown [10.175.127.227]) by APP4 (Coremail) with SMTP id gCh0CgCX0DAq5U9jgItmAA--.58124S4; Wed, 19 Oct 2022 19:53:16 +0800 (CST) From: Yu Kuai To: hch@lst.de, ebiggers@google.com, axboe@kernel.dk Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, yukuai3@huawei.com, yukuai1@huaweicloud.com, yi.zhang@huawei.com Subject: [PATCH v5 0/6] blk-wbt: simple improvment to enable wbt correctly Date: Wed, 19 Oct 2022 20:15:12 +0800 Message-Id: <20221019121518.3865235-1-yukuai1@huaweicloud.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 X-C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Info: 51xn3trlr6x35dzhxuhorxvhhfrp/ X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org From: Yu Kuai changes in v5: - code adjustment in patch 4, as suggested by Christoph. - add review tag by Christop. changes in v4: - remove patch 3 from v3 - add patch 2,3 in v4 changes in v3: - instead of check elevator name, add a flag in elevator_queue, as suggested by Christoph. - add patch 3 and patch 5 to this patchset. changes in v2: - define new api if wbt config is not enabled in patch 1. Yu Kuai (6): elevator: remove redundant code in elv_unregister_queue() blk-wbt: remove unnecessary check in wbt_enable_default() blk-wbt: make enable_state more accurate blk-wbt: don't show valid wbt_lat_usec in sysfs while wbt is disabled elevator: add new field flags in struct elevator_queue blk-wbt: don't enable throttling if default elevator is bfq block/bfq-iosched.c | 2 ++ block/blk-sysfs.c | 3 +++ block/blk-wbt.c | 26 ++++++++++++++++++++++---- block/blk-wbt.h | 17 ++++++++++++----- block/elevator.c | 8 ++------ block/elevator.h | 5 ++++- 6 files changed, 45 insertions(+), 16 deletions(-)