Received: by 2002:a05:6a10:6d25:0:0:0:0 with SMTP id gq37csp1926820pxb; Mon, 13 Sep 2021 08:19:24 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwiXBdI+nhisDCJ3izoQrVoFDtUA+auCAuELXpOW+il9FU5xnM6JaKj4srmBNLvYYjhwaO6 X-Received: by 2002:a05:6e02:e13:: with SMTP id a19mr8676529ilk.11.1631546364750; Mon, 13 Sep 2021 08:19:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631546364; cv=none; d=google.com; s=arc-20160816; b=wXktk11ietWcOibhz+ay/JIXd266DGT3Zy+gANP36HccwdoW7qTOCN/71CTOMtKAUG KEOVBFa90iciVhdrOws9h9Q0WUpIBU7TeRMdNqbPFgxzSXuM7wyFwgx7w5mNrNYimoAC SegojfVWf9cXxYAb9CTJjY9BOFkky7/ZMM0svhD3Q0dBX25Xyr8QBEj5QZt0UVrh70rr SZ6QaCV6jo4Dib343/lOQ4ZBqdHhNr/v/wY2kbcfyNTx+S/+3KTj+/hasPcPoCkXsGt1 XYInMs0olalEw4stpLIcVMBCPxOOP5STO0PpuDq8NVDRIupUIVgbN+s0DPAvP0bgI2qs wm6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from; bh=Paz5e9pxEoNv7W8lcrWO623CLc7ymBcnFvyvtNCROIk=; b=uGhr3g1/IQ8bFgDRPXFqls+fIrk9E2vDmUEuQyqybZicG7cJT92XEAsmqMIZ49Vaxt Pp5SLKFmkj4MPjOPjhjCANszsaijlqei6GMn+nhTo7NapWzBJSIHqnrWKCt9+YKqC5xZ b94/OzVVcXF4+cNG4nnoEs0JGSBbyjsrkvtOgJ6weQViKgNg3OG2gsKRwWQRv4UyBnH2 Q80Uh8fCdnlUMiJKjzwp9uUiq6PlqNJvNo9/pUFOP50vseBYIfyJ3jiCMhFpmWX/lYTt FpUZtv0p0MPgEKRtgUwSmnzbmniwNQ5pS/tPfp/+SENR0issHYeiRXtIUy8Df6z90wsC dlfQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h5si8082440iol.44.2021.09.13.08.19.13; Mon, 13 Sep 2021 08:19:24 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231183AbhIMPT0 (ORCPT + 99 others); Mon, 13 Sep 2021 11:19:26 -0400 Received: from frasgout.his.huawei.com ([185.176.79.56]:3777 "EHLO frasgout.his.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346143AbhIMPSv (ORCPT ); Mon, 13 Sep 2021 11:18:51 -0400 Received: from fraeml739-chm.china.huawei.com (unknown [172.18.147.206]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4H7VR15sgQz67wNx; Mon, 13 Sep 2021 23:15:25 +0800 (CST) Received: from lhreml724-chm.china.huawei.com (10.201.108.75) by fraeml739-chm.china.huawei.com (10.206.15.220) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.8; Mon, 13 Sep 2021 17:17:31 +0200 Received: from localhost.localdomain (10.69.192.58) by lhreml724-chm.china.huawei.com (10.201.108.75) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.8; Mon, 13 Sep 2021 16:17:29 +0100 From: John Garry To: CC: , , , , John Garry Subject: [PATCH RESEND v3 05/13] blk-mq-sched: Rename blk_mq_sched_alloc_{tags -> map_and_rqs}() Date: Mon, 13 Sep 2021 23:12:22 +0800 Message-ID: <1631545950-56586-6-git-send-email-john.garry@huawei.com> X-Mailer: git-send-email 2.8.1 In-Reply-To: <1631545950-56586-1-git-send-email-john.garry@huawei.com> References: <1631545950-56586-1-git-send-email-john.garry@huawei.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.69.192.58] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To lhreml724-chm.china.huawei.com (10.201.108.75) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Function blk_mq_sched_alloc_tags() does same as __blk_mq_alloc_map_and_request(), so give a similar name to be consistent. Similarly rename label err_free_tags -> err_free_map_and_rqs. Signed-off-by: John Garry Reviewed-by: Ming Lei --- block/blk-mq-sched.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/block/blk-mq-sched.c b/block/blk-mq-sched.c index 2231fb0d4c35..5f340203e6e5 100644 --- a/block/blk-mq-sched.c +++ b/block/blk-mq-sched.c @@ -515,9 +515,9 @@ void blk_mq_sched_insert_requests(struct blk_mq_hw_ctx *hctx, percpu_ref_put(&q->q_usage_counter); } -static int blk_mq_sched_alloc_tags(struct request_queue *q, - struct blk_mq_hw_ctx *hctx, - unsigned int hctx_idx) +static int blk_mq_sched_alloc_map_and_rqs(struct request_queue *q, + struct blk_mq_hw_ctx *hctx, + unsigned int hctx_idx) { struct blk_mq_tag_set *set = q->tag_set; int ret; @@ -609,15 +609,15 @@ int blk_mq_init_sched(struct request_queue *q, struct elevator_type *e) BLKDEV_DEFAULT_RQ); queue_for_each_hw_ctx(q, hctx, i) { - ret = blk_mq_sched_alloc_tags(q, hctx, i); + ret = blk_mq_sched_alloc_map_and_rqs(q, hctx, i); if (ret) - goto err_free_tags; + goto err_free_map_and_rqs; } if (blk_mq_is_sbitmap_shared(q->tag_set->flags)) { ret = blk_mq_init_sched_shared_sbitmap(q); if (ret) - goto err_free_tags; + goto err_free_map_and_rqs; } ret = e->ops.init_sched(q, e); @@ -645,8 +645,8 @@ int blk_mq_init_sched(struct request_queue *q, struct elevator_type *e) err_free_sbitmap: if (blk_mq_is_sbitmap_shared(q->tag_set->flags)) blk_mq_exit_sched_shared_sbitmap(q); -err_free_tags: blk_mq_sched_free_requests(q); +err_free_map_and_rqs: blk_mq_sched_tags_teardown(q); q->elevator = NULL; return ret; -- 2.26.2