From patchwork Thu Mar 17 11:26:50 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yu Kuai X-Patchwork-Id: 12783890 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 72DECC433F5 for ; Thu, 17 Mar 2022 11:11:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232887AbiCQLNH (ORCPT ); Thu, 17 Mar 2022 07:13:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53468 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232893AbiCQLNG (ORCPT ); Thu, 17 Mar 2022 07:13:06 -0400 Received: from szxga08-in.huawei.com (szxga08-in.huawei.com [45.249.212.255]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BEDAE1E110B; Thu, 17 Mar 2022 04:11:46 -0700 (PDT) Received: from kwepemi500020.china.huawei.com (unknown [172.30.72.55]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4KK48j55ZPz1GC0x; Thu, 17 Mar 2022 19:06:45 +0800 (CST) Received: from kwepemm600009.china.huawei.com (7.193.23.164) by kwepemi500020.china.huawei.com (7.221.188.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Thu, 17 Mar 2022 19:11:44 +0800 Received: from huawei.com (10.175.127.227) by kwepemm600009.china.huawei.com (7.193.23.164) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Thu, 17 Mar 2022 19:11:44 +0800 From: Yu Kuai To: , , CC: , , , Subject: [PATCH 0/3] optimizations for io accounting Date: Thu, 17 Mar 2022 19:26:50 +0800 Message-ID: <20220317112653.1019490-1-yukuai3@huawei.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 X-Originating-IP: [10.175.127.227] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To kwepemm600009.china.huawei.com (7.193.23.164) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Yu Kuai (3): block: don't show disk stats if io accounting is disabled block: factor out common code for part_stat_show() and diskstats_show() block: update nsecs[] in part_stat_show() and diskstats_show() block/bdev.c | 2 + block/blk-mq.c | 63 +++++++++++++++- block/blk-mq.h | 2 + block/genhd.c | 154 ++++++++++++++++++-------------------- include/linux/blk-mq.h | 2 + include/linux/blk_types.h | 5 ++ 6 files changed, 146 insertions(+), 82 deletions(-)