From patchwork Wed Feb 16 04:45:09 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ming Lei X-Patchwork-Id: 12747946 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 4C5AFC433F5 for ; Wed, 16 Feb 2022 04:46:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344400AbiBPEqb (ORCPT ); Tue, 15 Feb 2022 23:46:31 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:46618 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S245430AbiBPEqa (ORCPT ); Tue, 15 Feb 2022 23:46:30 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 14378F463D for ; Tue, 15 Feb 2022 20:46:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1644986777; h=from:from:reply-to:subject:subject: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=0xT85jgi10eWAW7O5YmpBMIQk2b0erOuEtyen64ctUE=; b=FoyyonBW4KPJMZobgDoQERAzUhGkdePdmvY7QjIwf3h4e4Ft7gQb2BuwklrwfNJc3PV8R0 rvyNeq3VKGlQN80BSREgrDoOeDtN15SemiYRfm8fKg4/sgyZUWSbXHumffHBv6EMtBju15 MnCg+eI3hNOeYI0cdpKRwsfhRJj4CL0= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-50-Gg4hbeGKMg675TVRSWA-1w-1; Tue, 15 Feb 2022 23:46:16 -0500 X-MC-Unique: Gg4hbeGKMg675TVRSWA-1w-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 4F19B1808320; Wed, 16 Feb 2022 04:46:15 +0000 (UTC) Received: from localhost (ovpn-8-27.pek2.redhat.com [10.72.8.27]) by smtp.corp.redhat.com (Postfix) with ESMTP id 3E7E15E482; Wed, 16 Feb 2022 04:46:06 +0000 (UTC) From: Ming Lei To: Jens Axboe Cc: linux-block@vger.kernel.org, Ning Li , Tejun Heo , Chunguang Xu , Ming Lei , Christoph Hellwig Subject: [PATCH V4 3/8] block: don't declare submit_bio_checks in local header Date: Wed, 16 Feb 2022 12:45:09 +0800 Message-Id: <20220216044514.2903784-4-ming.lei@redhat.com> In-Reply-To: <20220216044514.2903784-1-ming.lei@redhat.com> References: <20220216044514.2903784-1-ming.lei@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org submit_bio_checks() won't be called outside of block/blk-core.c any more since commit 9d497e2941c3 ("block: don't protect submit_bio_checks by q_usage_counter"), so mark it as one local helper. Reviewed-by: Christoph Hellwig Signed-off-by: Ming Lei Reviewed-by: Chaitanya Kulkarni --- block/blk-core.c | 2 +- block/blk.h | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/block/blk-core.c b/block/blk-core.c index f03fff1fa391..5248b94d276b 100644 --- a/block/blk-core.c +++ b/block/blk-core.c @@ -676,7 +676,7 @@ static inline blk_status_t blk_check_zone_append(struct request_queue *q, return BLK_STS_OK; } -noinline_for_stack bool submit_bio_checks(struct bio *bio) +static noinline_for_stack bool submit_bio_checks(struct bio *bio) { struct block_device *bdev = bio->bi_bdev; struct request_queue *q = bdev_get_queue(bdev); diff --git a/block/blk.h b/block/blk.h index abb663a2a147..b2516cb4f98e 100644 --- a/block/blk.h +++ b/block/blk.h @@ -46,7 +46,6 @@ void blk_freeze_queue(struct request_queue *q); void __blk_mq_unfreeze_queue(struct request_queue *q, bool force_atomic); void blk_queue_start_drain(struct request_queue *q); int __bio_queue_enter(struct request_queue *q, struct bio *bio); -bool submit_bio_checks(struct bio *bio); static inline bool blk_try_enter_queue(struct request_queue *q, bool pm) {