From patchwork Wed Oct 26 07:56:31 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ye Bin X-Patchwork-Id: 11097 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp111777wru; Wed, 26 Oct 2022 00:41:41 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7pwJFfNksKNfjboMNqFX+cjn8EW/iuS3jYdK5o5GvuG1W3VsSS6JXgGwXaMFX/PGKwl+CU X-Received: by 2002:a17:907:74a:b0:77e:9455:b4e1 with SMTP id xc10-20020a170907074a00b0077e9455b4e1mr37037338ejb.462.1666770100840; Wed, 26 Oct 2022 00:41:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666770100; cv=none; d=google.com; s=arc-20160816; b=FYp8zTIJBJkQ6xxQKtYduRHalNFqUelnfRlPfAP4zIPuTk97pncBazzJ+cAEplR6bb IJMK1kn8kE7DWt7BLs7k+TlW1UlzKpOy48vxb0fCLfgaCtpj9Rr6wAGp29qJIk5w+YPI zfkzkrJRhEsZSti3GmFZ4/GmD0cMgQhqeTLnH35A7UAKMuU0OQT1gaxB4UMBwIaQeIyu iLKrkXnk417cF5fAE4DdXxoxwHgL3xdxf/pqrBE9PmSBPGpUz82yU6JL7Cx7U8qKH6ka igv53/MfaXMCYpQbwC1dVLio8Yy9OeHdW4sHYgLidsVc6ixQx5usWYWDGdZQiKDyBxLO v9KA== 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 :message-id:date:subject:cc:to:from; bh=o2JhfJxDNpciWuIZrySXBdX1QHbtd8Dc36v5WFi46TY=; b=AtDwAH64JRELYlC6lMFTSWLgCOr1aum0L7JrbPdNRpJ5iGpCYTdaqoFrLGGcpW3JqS pUteXcyMVfxTGAJvneizEjwYSTBnutC5NaIr3hxKoezNTbJBRiAkR0n0j9UBZHy4ehR+ bQU1FThgbVFdljpPtYl606c6MzISqo0/jhm+veVnSjIG9w1UsxVQQ1A5Rkc4WwJVE6wF 6Ry14FQc3H9NxuMjDxpnZ/DSP9b1TtwjlnBy7Qj9xjMMb7nP6a248sEgVJmeQR0Injqx DFxrh27j0EyigMZiCC253xxUOYz2ERkBEcKPcTrIn/a9l5YghOjF3l77o2FBxnjb11AS ksLw== 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r18-20020a50aad2000000b004588172def1si4407665edc.410.2022.10.26.00.41.15; Wed, 26 Oct 2022 00:41:40 -0700 (PDT) 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 S229904AbiJZHet (ORCPT + 99 others); Wed, 26 Oct 2022 03:34:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46816 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232489AbiJZHer (ORCPT ); Wed, 26 Oct 2022 03:34:47 -0400 Received: from dggsgout12.his.huawei.com (unknown [45.249.212.56]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7B718DFF3; Wed, 26 Oct 2022 00:34:42 -0700 (PDT) Received: from mail02.huawei.com (unknown [172.30.67.153]) by dggsgout12.his.huawei.com (SkyGuard) with ESMTP id 4My0rF53QRz6T6mt; Wed, 26 Oct 2022 15:32:13 +0800 (CST) Received: from huaweicloud.com (unknown [10.175.127.227]) by APP4 (Coremail) with SMTP id gCh0CgCntOYO41hjqLzeAA--.4330S4; Wed, 26 Oct 2022 15:34:40 +0800 (CST) From: Ye Bin To: axboe@kernel.dk, rostedt@goodmis.org, mhiramat@kernel.org, linux-block@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Ye Bin Subject: [PATCH] blktrace:use '__blk_trace_remove' helper in 'blk_trace_remove_queue' Date: Wed, 26 Oct 2022 15:56:31 +0800 Message-Id: <20221026075631.682100-1-yebin@huaweicloud.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 X-CM-TRANSID: gCh0CgCntOYO41hjqLzeAA--.4330S4 X-Coremail-Antispam: 1UD129KBjvdXoWrKw1ktFykWry3XF45Xr4ruFg_yoWDJFc_ZF yUW3Wxtr43Cr90qr4fAFsIq3Wqq34jvFyFya45tFW5A3ZrXrn8G3ZxZwsIgrZ09r4kWa4U Jry3t34UGF1YyjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUbr8YFVCjjxCrM7AC8VAFwI0_Gr0_Xr1l1xkIjI8I6I8E6xAIw20E Y4v20xvaj40_JFC_Wr1l1IIY67AEw4v_Jr0_Jr4l8cAvFVAK0II2c7xJM28CjxkF64kEwV A0rcxSw2x7M28EF7xvwVC0I7IYx2IY67AKxVWDJVCq3wA2z4x0Y4vE2Ix0cI8IcVCY1x02 67AKxVW8Jr0_Cr1UM28EF7xvwVC2z280aVAFwI0_GcCE3s1l84ACjcxK6I8E87Iv6xkF7I 0E14v26rxl6s0DM2AIxVAIcxkEcVAq07x20xvEncxIr21l5I8CrVACY4xI64kE6c02F40E x7xfMcIj6xIIjxv20xvE14v26r106r15McIj6I8E87Iv67AKxVWUJVW8JwAm72CE4IkC6x 0Yz7v_Jr0_Gr1lF7xvr2IYc2Ij64vIr41l42xK82IYc2Ij64vIr41l4I8I3I0E4IkC6x0Y z7v_Jr0_Gr1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s026x8GjcxK67AKxVWUGVWUWwC2zV AF1VAY17CE14v26r126r1DMIIYrxkI7VAKI48JMIIF0xvE2Ix0cI8IcVAFwI0_Jr0_JF4l IxAIcVC0I7IYx2IY6xkF7I0E14v26r4j6F4UMIIF0xvE42xK8VAvwI8IcIk0rVWrJr0_WF yUJwCI42IY6I8E87Iv67AKxVWUJVW8JwCI42IY6I8E87Iv6xkF7I0E14v26r4j6r4UJbIY CTnIWIevJa73UjIFyTuYvjxUOyCJDUUUU X-CM-SenderInfo: p1hex046kxt4xhlfz01xgou0bp/ X-CFilter-Loop: Reflected X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747735125233096533?= X-GMAIL-MSGID: =?utf-8?q?1747735125233096533?= From: Ye Bin After '60a9bb9048f9' and 'dcd1a59c62dc' commit 'blk_trace_remove_queue' is do the same job with '__blk_trace_remove', so just call '__blk_trace_remove'. Signed-off-by: Ye Bin --- kernel/trace/blktrace.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c index a995ea1ef849..115ae18e479d 100644 --- a/kernel/trace/blktrace.c +++ b/kernel/trace/blktrace.c @@ -1609,19 +1609,7 @@ device_initcall(init_blk_tracer); static int blk_trace_remove_queue(struct request_queue *q) { - struct blk_trace *bt; - - bt = rcu_replace_pointer(q->blk_trace, NULL, - lockdep_is_held(&q->debugfs_mutex)); - if (bt == NULL) - return -EINVAL; - - blk_trace_stop(bt); - - put_probe_ref(); - synchronize_rcu(); - blk_trace_free(q, bt); - return 0; + return __blk_trace_remove(q); } /*