From patchwork Tue Nov 22 14:21:23 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jinlong Chen X-Patchwork-Id: 24405 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp2232318wrr; Tue, 22 Nov 2022 06:27:59 -0800 (PST) X-Google-Smtp-Source: AA0mqf7ykNcpb005/6tAgdGF62S9VVInbMzJneeDM98b1Zc8+NMMxv3s6uIdxMktjJJt7nsg8ElI X-Received: by 2002:aa7:cf07:0:b0:469:5aae:5807 with SMTP id a7-20020aa7cf07000000b004695aae5807mr12661508edy.133.1669127278834; Tue, 22 Nov 2022 06:27:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669127278; cv=none; d=google.com; s=arc-20160816; b=E5DYcTXyCx1Vc0bzRdH8t4YMy8uHN76fol+Lb4e+H8SFfKp1yzeNAq9vmR+SYU2wTH px/1n8UG1IiqljQorfPlyKHwwN2S/rXOJqR1ttWYgENoFSG/nSwMWXJHLA7+YCbw5CQx dmCTsiEHGCv8BPyseXe0koyGaCHa0Jl6+UOEGbd8WZ3Hvo9phkM7RjgFu6ZkgMxCT2sf vbn3adhSvqaQKOxEkLqBIkBVKNSrQH+Kfh8DaqE1wJIIe4R4pvtwfOnxyGeT5lGyqx6W cysSQLuMX7ym4XwZCMXo0gxLFKFlHMO/swdzy3ggIpdJe83TJn6x4uNI1HdyVA+RgbNO qMjg== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=PJz6+jp9x7OlqSOZDfzo/7HV2170yv1S48z3Np6t9Cw=; b=z1Nl9s3ZqZQp5wQsTc9CvEJZoyEsWWq5VcwbgFLHwWhc2OMIxDhj8F8a6plyDSbyC4 VlUtAz823Wnio8gRF7VZYXGeOEON+0tEGH2pzHmhCj9tHVFbZ1E8csGuvnTGetI7Ird0 DdyyXfCsKoRiFm42ZCUnoF4BXO5L1pdLzyuJC8nA0fH6nlKL7gbeCBtwrJt5yGapDJTJ D9gEuTz6+5HcBVogoiB9Jdt4WuP0ACm/wPyJaYI4OQQvkD2uyK/PFRpdalcyidsKu2BO Q/FQZOqglUTKwnVE+jb8XCdlRylW0l63l4E2evANBssANtH7mcAtSuLI3MBvWdgjTw7f Oa2Q== 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 mp8-20020a1709071b0800b007adb868f102si1797391ejc.476.2022.11.22.06.27.33; Tue, 22 Nov 2022 06:27:58 -0800 (PST) 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 S233943AbiKVOV5 (ORCPT + 99 others); Tue, 22 Nov 2022 09:21:57 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40792 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233207AbiKVOVq (ORCPT ); Tue, 22 Nov 2022 09:21:46 -0500 Received: from zju.edu.cn (spam.zju.edu.cn [61.164.42.155]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id DC88762394; Tue, 22 Nov 2022 06:21:44 -0800 (PST) Received: from localhost.localdomain (unknown [10.14.30.50]) by mail-app4 (Coremail) with SMTP id cS_KCgCHrN_o2nxjHR5BCA--.15646S3; Tue, 22 Nov 2022 22:21:40 +0800 (CST) From: Jinlong Chen To: axboe@kernel.dk Cc: hch@lst.de, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, nickyc975@zju.edu.cn Subject: [PATCH 1/4] elevator: update the document of elevator_switch Date: Tue, 22 Nov 2022 22:21:23 +0800 Message-Id: <94250961689ba7d2e67a7d9e7995a11166fedb31.1669126766.git.nickyc975@zju.edu.cn> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 X-CM-TRANSID: cS_KCgCHrN_o2nxjHR5BCA--.15646S3 X-Coremail-Antispam: 1UD129KBjvdXoW7GF4xKw1fuF4fXrWrCryxuFg_yoWkJwc_Z3 45tas7J34DWr4YgryfKF15trW09ws3XFy5Gws2grn3Xas0kFyvyr48ur17ur1xWa1UC343 A3yqv3WFvrnagjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUbs8Fc2x0x2IEx4CE42xK8VAvwI8IcIk0rVWrJVCq3wAFIxvE14AK wVWUJVWUGwA2ocxC64kIII0Yj41l84x0c7CEw4AK67xGY2AK021l84ACjcxK6xIIjxv20x vE14v26w1j6s0DM28EF7xvwVC0I7IYx2IY6xkF7I0E14v26r4UJVWxJr1l84ACjcxK6I8E 87Iv67AKxVW0oVCq3wA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_GcCE3s1lnxkEFVAIw20F6c xK64vIFxWle2I262IYc4CY6c8Ij28IcVAaY2xG8wAqx4xG64xvF2IEw4CE5I8CrVC2j2Wl Yx0E2Ix0cI8IcVAFwI0_Jr0_Jr4lYx0Ex4A2jsIE14v26r1j6r4UMcvjeVCFs4IE7xkEbV WUJVW8JwACjcxG0xvY0x0EwIxGrwACjI8F5VA0II8E6IAqYI8I648v4I1l42xK82IYc2Ij 64vIr41l42xK82IY6x8ErcxFaVAv8VW8uw4UJr1UMxC20s026xCaFVCjc4AY6r1j6r4UMI 8I3I0E5I8CrVAFwI0_Jr0_Jr4lx2IqxVCjr7xvwVAFwI0_JrI_JrWlx4CE17CEb7AF67AK xVWUAVWUtwCIc40Y0x0EwIxGrwCI42IY6xIIjxv20xvE14v26r1j6r1xMIIF0xvE2Ix0cI 8IcVCY1x0267AKxVWUJVW8JwCI42IY6xAIw20EY4v20xvaj40_Jr0_JF4lIxAIcVC2z280 aVAFwI0_Jr0_Gr1lIxAIcVC2z280aVCY1x0267AKxVW8JVW8JrUvcSsGvfC2KfnxnUUI43 ZEXa7VUbHa0DUUUUU== X-CM-SenderInfo: qssqjiaqqzq6lmxovvfxof0/1tbiAgcCB1ZdtciuZAADs- X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_PASS, 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?1750206805277074087?= X-GMAIL-MSGID: =?utf-8?q?1750206805277074087?= We no longer support falling back to the old io scheduler if switching to the new one fails. Update the document to indicate that. Fixes: a1ce35fa4985 ("block: remove dead elevator code") Signed-off-by: Jinlong Chen Reviewed-by: Christoph Hellwig --- block/elevator.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/block/elevator.c b/block/elevator.c index a5bdc3b1e7e5..01aa9f38f22e 100644 --- a/block/elevator.c +++ b/block/elevator.c @@ -650,10 +650,10 @@ void elevator_init_mq(struct request_queue *q) } /* - * switch to new_e io scheduler. be careful not to introduce deadlocks - - * we don't free the old io scheduler, before we have allocated what we - * need for the new one. this way we have a chance of going back to the old - * one, if the new one fails init for some reason. + * Switch to new_e io scheduler. + * + * If switching fails, we are most likely running out of memory and not able + * to restore the old io scheduler, so leaving the io scheduler being none. */ int elevator_switch(struct request_queue *q, struct elevator_type *new_e) { From patchwork Tue Nov 22 14:21:24 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jinlong Chen X-Patchwork-Id: 24404 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp2231255wrr; Tue, 22 Nov 2022 06:26:33 -0800 (PST) X-Google-Smtp-Source: AA0mqf7Qe49PcV1+bA+NOJt3ytZ3BuWNterEDyd+rGQCHeF+NEK1r1ztZzrQflCseBO4p2nwyd3/ X-Received: by 2002:a05:6402:1767:b0:469:4606:e2a2 with SMTP id da7-20020a056402176700b004694606e2a2mr13370880edb.232.1669127193368; Tue, 22 Nov 2022 06:26:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669127193; cv=none; d=google.com; s=arc-20160816; b=lHldQFWhBzFh0knKP8u5K05X1t9br/WZgvPYpG95MlfVBOeMBoVxH9sbzRlnFjBzch CdzsleQjqk6nKosEx2oIfnhBbQR9TWx1z+OJ+LtzS79LwQhGmSHUxCXS1AbkdcCR6i3K lHOJg/Murl8h6dSODHxEGABR+9vQCGxhuVXDY87dzh8OCefnlIkN1yyUtgs5S2ewXZ5F HAgPWxdDc4UZWLxMU+7RsWWxAiQO84+8VO8wKoiB74nxhVN7GW63uXL+7bA4XGFgg6KS zivm73h4KwnW/KKLaU9/nahiZACangyatz7FRRcUJ0YM+AnUoDnG2SPAqc4DinZ65Zis cg9w== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=I2UhijnCzcPzoMeQF7uO0bnhSe4uRy/HGGDiLwpaOVA=; b=Z32N6oLlR7I1X3Gggh+e+22GYEoyaoR7FiUAWxt+obKKev7l6bUfkjWTdrbF5Qhdrp v9Z/RI8q8cLZ9KIPVf47VDWcT0zqTETyhcNcRlFZnvayJKsWMNXnFDfQ8QLij+DSCO6x 7d2gwjBYKKrrE2FZqrW0ICEqLpEvfEal9iLV8/dqI9YsG/IXQM+3lRPZl1U4Wb2VXnxp NsM17yfXHALGLJEvEJudc0LOBcjnUphdx+MFnnzj9/i01vuomNIPTnPt51BU+k3lFIrs +PIO/HVmBnrrESbSlzDaJucQDCCRFMoDXTCVn9GqPSxraD0nVp4v6yn8Xyep4+CvMQHI 3+/Q== 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 z14-20020a056402274e00b00469a45ae32csi5647369edd.562.2022.11.22.06.26.09; Tue, 22 Nov 2022 06:26:33 -0800 (PST) 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 S233416AbiKVOVw (ORCPT + 99 others); Tue, 22 Nov 2022 09:21:52 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40782 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233070AbiKVOVq (ORCPT ); Tue, 22 Nov 2022 09:21:46 -0500 Received: from zju.edu.cn (mail.zju.edu.cn [61.164.42.155]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E4CD86829C; Tue, 22 Nov 2022 06:21:44 -0800 (PST) Received: from localhost.localdomain (unknown [10.14.30.50]) by mail-app4 (Coremail) with SMTP id cS_KCgCHrN_o2nxjHR5BCA--.15646S4; Tue, 22 Nov 2022 22:21:41 +0800 (CST) From: Jinlong Chen To: axboe@kernel.dk Cc: hch@lst.de, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, nickyc975@zju.edu.cn Subject: [PATCH 2/4] elevator: printk a warning if switching to a new io scheduler fails Date: Tue, 22 Nov 2022 22:21:24 +0800 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 X-CM-TRANSID: cS_KCgCHrN_o2nxjHR5BCA--.15646S4 X-Coremail-Antispam: 1UD129KBjvdXoW7Jw4fGw4rGFykXry5uw18AFb_yoWxtrb_G3 y8K3Z7Jan8Gr4Yyr1fKF1YqF10vwn3JFy5Ww42qrn3J3W29Fyvyr10vr1xCr1kWFWUG3W3 Jw4q9rnrZw13KjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUbs8Fc2x0x2IEx4CE42xK8VAvwI8IcIk0rVWrJVCq3wAFIxvE14AK wVWUJVWUGwA2ocxC64kIII0Yj41l84x0c7CEw4AK67xGY2AK021l84ACjcxK6xIIjxv20x vE14v26w1j6s0DM28EF7xvwVC0I7IYx2IY6xkF7I0E14v26r4UJVWxJr1l84ACjcxK6I8E 87Iv67AKxVW0oVCq3wA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_GcCE3s1lnxkEFVAIw20F6c xK64vIFxWle2I262IYc4CY6c8Ij28IcVAaY2xG8wAqx4xG64xvF2IEw4CE5I8CrVC2j2Wl Yx0E2Ix0cI8IcVAFwI0_Jr0_Jr4lYx0Ex4A2jsIE14v26r1j6r4UMcvjeVCFs4IE7xkEbV WUJVW8JwACjcxG0xvY0x0EwIxGrwACjI8F5VA0II8E6IAqYI8I648v4I1l42xK82IYc2Ij 64vIr41l42xK82IY6x8ErcxFaVAv8VW8uw4UJr1UMxC20s026xCaFVCjc4AY6r1j6r4UMI 8I3I0E5I8CrVAFwI0_Jr0_Jr4lx2IqxVCjr7xvwVAFwI0_JrI_JrWlx4CE17CEb7AF67AK xVWUAVWUtwCIc40Y0x0EwIxGrwCI42IY6xIIjxv20xvE14v26r1j6r1xMIIF0xvE2Ix0cI 8IcVCY1x0267AKxVW8JVWxJwCI42IY6xAIw20EY4v20xvaj40_Jr0_JF4lIxAIcVC2z280 aVAFwI0_Jr0_Gr1lIxAIcVC2z280aVCY1x0267AKxVW8JVW8JrUvcSsGvfC2KfnxnUUI43 ZEXa7VUbHa0DUUUUU== X-CM-SenderInfo: qssqjiaqqzq6lmxovvfxof0/1tbiAg4CB1ZdtciuiQAAsY X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_PASS, 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?1750206716109691317?= X-GMAIL-MSGID: =?utf-8?q?1750206716109691317?= printk a warning to indicate that the io scheduler has been set to none if switching to a new io scheduler fails. Signed-off-by: Jinlong Chen Reviewed-by: Christoph Hellwig --- block/elevator.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/block/elevator.c b/block/elevator.c index 01aa9f38f22e..1fa45717b1d6 100644 --- a/block/elevator.c +++ b/block/elevator.c @@ -683,6 +683,12 @@ int elevator_switch(struct request_queue *q, struct elevator_type *new_e) out_unfreeze: blk_mq_unquiesce_queue(q); blk_mq_unfreeze_queue(q); + + if (ret) { + pr_warn("elv: switch to \"%s\" failed, falling back to \"none\"\n", + new_e->elevator_name); + } + return ret; } From patchwork Tue Nov 22 14:21:25 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jinlong Chen X-Patchwork-Id: 24407 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp2232573wrr; Tue, 22 Nov 2022 06:28:17 -0800 (PST) X-Google-Smtp-Source: AA0mqf7NpeX3u4Yx23J73f2VdYXPTHUG4hzeZge5L9f6XmEzEg7sV+8Dw5BYAyCv1ai0aBKroFRL X-Received: by 2002:a17:907:3907:b0:7ae:37a8:9b5c with SMTP id so7-20020a170907390700b007ae37a89b5cmr4701914ejc.241.1669127297142; Tue, 22 Nov 2022 06:28:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669127297; cv=none; d=google.com; s=arc-20160816; b=v1GDsoTIGdgDikyk2YiVwXqoJa6PNmsIyC3/P3LMmB2mCjeEe+wHYkEu6ij7nUeydn kttM76vV44ZyODbz/TIEAsTQm5fZZPCuVERVShtmlGowUJscFfVMDt1Gn4af7ngjqAK7 OgyFg2RepUYRBedOUfGASSUnlY20oaoCyhULFEbmB6qd8bVPrbSmCIJXvGfor6WOFGzc 69sfKmo9hticyYrgp7kM++aPcGe74KEkdFt8dRuw5tjCy7YiLfvvqCWAwdn1++gsBqBE pCO2TLUhOlQPM0pc9NeCIfbsZR7ZgM0NuqmO80//IW1F4M1wlK/KyYYreK6bnKzV5zXi UAYA== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=c6Wihxb8mwhxP6SyDa7dcfX6DBMwmkaixxXjljqQsVs=; b=gVUO2ofMYKG851IRWj1qAD59wcp4lombMCwqrdOFKghc7WDLbKBCJMXh1Di0o1zljc /+dfXdUNyIEOMjsoYpmfZzQe0UmyQKQZzWZWazMUk1zXvUcZxGn1YNo2kq5gmTKgHHMx H5Sjsn0vMVfHebCdN8cWpU9EZwL5V8gkJguUwpJtNWrJHuXKn04o8p5vHgvXFcCqnMbH q3/sbPe/xekCkjctlKwQjXWO+VSTfTMGCWIZGCFPmdxd0Gtda9YKaWa2dLmOgcRKegdY udbJwTZsRh/zRiko82buFpz7h3RGLOVfC7VmZk4rGwPkdWnSCgojsiV9/7qpnKyvEXSP 8nEA== 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 js16-20020a17090797d000b0078dd7383ed8si14789422ejc.414.2022.11.22.06.27.44; Tue, 22 Nov 2022 06:28:17 -0800 (PST) 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 S232625AbiKVOWG (ORCPT + 99 others); Tue, 22 Nov 2022 09:22:06 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40782 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233378AbiKVOVs (ORCPT ); Tue, 22 Nov 2022 09:21:48 -0500 Received: from zju.edu.cn (mail.zju.edu.cn [61.164.42.155]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E9AE2490A1; Tue, 22 Nov 2022 06:21:46 -0800 (PST) Received: from localhost.localdomain (unknown [10.14.30.50]) by mail-app4 (Coremail) with SMTP id cS_KCgCHrN_o2nxjHR5BCA--.15646S5; Tue, 22 Nov 2022 22:21:42 +0800 (CST) From: Jinlong Chen To: axboe@kernel.dk Cc: hch@lst.de, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, nickyc975@zju.edu.cn Subject: [PATCH 3/4] elevator: update the document of elevator_match Date: Tue, 22 Nov 2022 22:21:25 +0800 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 X-CM-TRANSID: cS_KCgCHrN_o2nxjHR5BCA--.15646S5 X-Coremail-Antispam: 1UD129KBjvdXoW7Wr18Gr1rWr4xZw1fCF13twb_yoWDZwb_G3 yjy3Z7J34DJr1akF1IqF4Yqry7Zwn3Cry5Gr1xtFyxAayFgFnFyrZ7CryUCw1UXrW5C3W5 Cw4Duw17Zr1agjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUbs8Fc2x0x2IEx4CE42xK8VAvwI8IcIk0rVWrJVCq3wAFIxvE14AK wVWUJVWUGwA2ocxC64kIII0Yj41l84x0c7CEw4AK67xGY2AK021l84ACjcxK6xIIjxv20x vE14v26w1j6s0DM28EF7xvwVC0I7IYx2IY6xkF7I0E14v26r4UJVWxJr1l84ACjcxK6I8E 87Iv67AKxVW0oVCq3wA2z4x0Y4vEx4A2jsIEc7CjxVAFwI0_GcCE3s1lnxkEFVAIw20F6c xK64vIFxWle2I262IYc4CY6c8Ij28IcVAaY2xG8wAqx4xG64xvF2IEw4CE5I8CrVC2j2Wl Yx0E2Ix0cI8IcVAFwI0_Jr0_Jr4lYx0Ex4A2jsIE14v26r1j6r4UMcvjeVCFs4IE7xkEbV WUJVW8JwACjcxG0xvY0x0EwIxGrwACjI8F5VA0II8E6IAqYI8I648v4I1l42xK82IYc2Ij 64vIr41l42xK82IY6x8ErcxFaVAv8VW8uw4UJr1UMxC20s026xCaFVCjc4AY6r1j6r4UMI 8I3I0E5I8CrVAFwI0_Jr0_Jr4lx2IqxVCjr7xvwVAFwI0_JrI_JrWlx4CE17CEb7AF67AK xVWUAVWUtwCIc40Y0x0EwIxGrwCI42IY6xIIjxv20xvE14v26r1j6r1xMIIF0xvE2Ix0cI 8IcVCY1x0267AKxVW8JVWxJwCI42IY6xAIw20EY4v20xvaj40_Jr0_JF4lIxAIcVC2z280 aVAFwI0_Jr0_Gr1lIxAIcVC2z280aVCY1x0267AKxVW8JVW8JrUvcSsGvfC2KfnxnUUI43 ZEXa7VUbHa0DUUUUU== X-CM-SenderInfo: qssqjiaqqzq6lmxovvfxof0/1tbiAg4CB1ZdtciuigABsa X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_PASS, 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?1750206825088718200?= X-GMAIL-MSGID: =?utf-8?q?1750206825088718200?= elevator_match does not care about elevator_features any more. Remove related descriptions from its document. Fixes: ffb86425ee2c ("block: don't check for required features in elevator_match") Signed-off-by: Jinlong Chen Reviewed-by: Christoph Hellwig --- block/elevator.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/block/elevator.c b/block/elevator.c index 1fa45717b1d6..5287b39cd7a9 100644 --- a/block/elevator.c +++ b/block/elevator.c @@ -91,12 +91,11 @@ static inline bool elv_support_features(struct request_queue *q, } /** - * elevator_match - Test an elevator name and features + * elevator_match - Check whether @e's name or alias matches @name * @e: Scheduler to test * @name: Elevator name to test * - * Return true if the elevator @e name matches @name and if @e provides all - * the features specified by @required_features. + * Return true if the elevator @e's name or alias matches @name. */ static bool elevator_match(const struct elevator_type *e, const char *name) { From patchwork Tue Nov 22 14:21:26 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jinlong Chen X-Patchwork-Id: 24406 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp2232354wrr; Tue, 22 Nov 2022 06:28:01 -0800 (PST) X-Google-Smtp-Source: AA0mqf5AdtfhZ06KJXGNxEaijwzagccW2U3w/ngFECBwHk8ybm+A/ZIqamykH1Fi0oo4SPkkBbST X-Received: by 2002:a05:6a00:3204:b0:574:31bb:a576 with SMTP id bm4-20020a056a00320400b0057431bba576mr673637pfb.46.1669127281310; Tue, 22 Nov 2022 06:28:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669127281; cv=none; d=google.com; s=arc-20160816; b=Zvz8k55jInGXvtGuDYLs1dxqe6dwegePsf/vcegRHwh960iOxUU6r0dZ2S4KRysxk/ ICTwtfEYeCZ22hrDl++mAg60PIr4HT/PsHF8YBW7NWHXKDbWmYdSwncW33Ro39snHXKh /dkiDjXEYCAy6TAhCqBE18FgW6cF9CiT4V+MZUQ6/c4sQYw+NK46vikxNqmFk/36zBPi KOSoPbyVqAMw/Pl8Mk5zap9na9IxhSi4kc8PdqzOhuv6jQz3fsKj34OviFgFfP+ny+iC dALtB69hyK24HGMauDEn+UhN4kmyyYPyWJfQNjTdqL3ANcm/l2ai0oGiVdQi+KOri9+Z pHxg== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=ZDZS1Vohgob9LOT0XdIIS8ecuf92i8BSdW6ETo1UII8=; b=sLDWGVrvIambGBXcdJt3pZuuBovoHDCXG4YCQIFeM7HRrrRNEpEw4P3NJIpvg1V7rR pHfQfdys1KsB/f/jricx0FdD4lMg1iLHom7x6PDmkZIYiuhJiwGdhRrRMu6+IEe6aroy MduUPpykuSdqwbOkxaj1HdLBTKnh7dsDUewqrivoyOq+XkkCC/Amo7CunCNLJ88kXpEX JBS3AKhjlNs/nlZLD4KcDWNfiiO7PBWMbKhsBKoZKRogl0c5p2Qe/1SML49vMyNEQeOH yBQdYn8hjF0yS3qrQ22DWbL6vDjlYM2EQKzlAGuGvEI0jrd1L9CA/JTZNoXvnQaCT87D +KVw== 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 t17-20020a170902e85100b001870dc9ef63si16116539plg.129.2022.11.22.06.27.46; Tue, 22 Nov 2022 06:28:01 -0800 (PST) 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 S233691AbiKVOWK (ORCPT + 99 others); Tue, 22 Nov 2022 09:22:10 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40792 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233492AbiKVOVs (ORCPT ); Tue, 22 Nov 2022 09:21:48 -0500 Received: from zju.edu.cn (mail.zju.edu.cn [61.164.42.155]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 48A246829D; Tue, 22 Nov 2022 06:21:46 -0800 (PST) Received: from localhost.localdomain (unknown [10.14.30.50]) by mail-app4 (Coremail) with SMTP id cS_KCgCHrN_o2nxjHR5BCA--.15646S6; Tue, 22 Nov 2022 22:21:43 +0800 (CST) From: Jinlong Chen To: axboe@kernel.dk Cc: hch@lst.de, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, nickyc975@zju.edu.cn Subject: [PATCH 4/4] elevator: remove an outdated comment in elevator_change Date: Tue, 22 Nov 2022 22:21:26 +0800 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 X-CM-TRANSID: cS_KCgCHrN_o2nxjHR5BCA--.15646S6 X-Coremail-Antispam: 1UD129KBjDUn29KB7ZKAUJUUUUU529EdanIXcx71UUUUU7v73 VFW2AGmfu7bjvjm3AaLaJ3UjIYCTnIWjp_UUUY37CY07I20VC2zVCF04k26cxKx2IYs7xG 6rWj6s0DM7CIcVAFz4kK6r1j6r18M28lY4IEw2IIxxk0rwA2F7IY1VAKz4vEj48ve4kI8w A2z4x0Y4vE2Ix0cI8IcVAFwI0_tr0E3s1l84ACjcxK6xIIjxv20xvEc7CjxVAFwI0_Gr1j 6F4UJwA2z4x0Y4vEx4A2jsIE14v26rxl6s0DM28EF7xvwVC2z280aVCY1x0267AKxVW0oV Cq3wAac4AC62xK8xCEY4vEwIxC4wAS0I0E0xvYzxvE52x082IY62kv0487Mc02F40EFcxC 0VAKzVAqx4xG6I80ewAv7VC0I7IYx2IY67AKxVWUJVWUGwAv7VC2z280aVAFwI0_Jr0_Gr 1lOx8S6xCaFVCjc4AY6r1j6r4UM4x0Y48IcxkI7VAKI48JM4x0x7Aq67IIx4CEVc8vx2IE rcIFxwCF04k20xvY0x0EwIxGrwCF04k20xvE74AGY7Cv6cx26r4fKr1UJr1l4I8I3I0E4I kC6x0Yz7v_Jr0_Gr1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s026x8GjcxK67AKxVWUGVWU WwC2zVAF1VAY17CE14v26r126r1DMIIYrxkI7VAKI48JMIIF0xvE2Ix0cI8IcVAFwI0_Jr 0_JF4lIxAIcVC0I7IYx2IY6xkF7I0E14v26r4j6F4UMIIF0xvE42xK8VAvwI8IcIk0rVWU JVWUCwCI42IY6I8E87Iv67AKxVWUJVW8JwCI42IY6I8E87Iv6xkF7I0E14v26r4j6r4UJb IYCTnIWIevJa73UjIFyTuYvjfUOlksUUUUU X-CM-SenderInfo: qssqjiaqqzq6lmxovvfxof0/1tbiAgECB1ZdtciuiwAAsV X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_PASS, 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?1750206808288506955?= X-GMAIL-MSGID: =?utf-8?q?1750206808288506955?= mq is no longer a special case. Signed-off-by: Jinlong Chen Reviewed-by: Christoph Hellwig --- block/elevator.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/block/elevator.c b/block/elevator.c index 5287b39cd7a9..599413620558 100644 --- a/block/elevator.c +++ b/block/elevator.c @@ -721,9 +721,6 @@ static int elevator_change(struct request_queue *q, const char *elevator_name) if (!blk_queue_registered(q)) return -ENOENT; - /* - * Special case for mq, turn off scheduling - */ if (!strncmp(elevator_name, "none", 4)) { if (q->elevator) elevator_disable(q);