From patchwork Tue Jun 7 12:47:27 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871884 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 39640CCA47C for ; Tue, 7 Jun 2022 12:47:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244162AbiFGMrs (ORCPT ); Tue, 7 Jun 2022 08:47:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35836 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242948AbiFGMrr (ORCPT ); Tue, 7 Jun 2022 08:47:47 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 37C3E2ADF for ; Tue, 7 Jun 2022 05:47:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=piKidiCmKaDeB4ftdaJqsCLVsy9ug3lNTMc7VzUl50M=; b=N/nhlkOyCzjEKWaSuwh/ylbmc1 dpsU/d5j4ajRLSFVIpRXPfvWD3ulJ8yCef380Ljt6166UeZSdlJ8hk+cx4v0bgCN50FlT+3s0e7x1 ZgZibmI3cMXzPxJ6mz4ExM1V3vkjMqoDZm1Hb4arpCH/Wr+d31c0vrqbFNv9i/dkWsdldpGWgCANn cni1iwiOeF4SlspEk+Hl30dtDSCDsvL7d1KCSWBUhD4RLyhd4ZYbQcyRkecbSoziGAIQZNC9uXtX8 eIqG6paOMidLj/PRj3p+q1OgpIWVQcRObL85drbyMNbtYbxC/ayt1gmF4x4TVIvJ1mbmwq4ugwUr+ kylUbLTQ==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYcb-007SVG-6b; Tue, 07 Jun 2022 12:47:45 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org, Chaitanya Kulkarni Subject: [PATCH blktests 01/13] common/null_blk: remove explicit queue_mode=2 parameters Date: Tue, 7 Jun 2022 14:47:27 +0200 Message-Id: <20220607124739.1259977-2-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org queue_mode 2 (aka blk-mq) is the default in null_blk, so remove the extra explicitly parameter. Signed-off-by: Christoph Hellwig Reviewed-by: Chaitanya Kulkarni --- tests/block/006 | 2 +- tests/block/010 | 4 ++-- tests/block/014 | 2 +- tests/block/015 | 2 +- tests/block/016 | 2 +- tests/block/017 | 3 +-- tests/block/018 | 3 +-- tests/block/020 | 2 +- tests/block/022 | 2 +- tests/block/024 | 3 +-- tests/block/029 | 2 +- tests/block/030 | 2 +- tests/block/031 | 2 +- 13 files changed, 14 insertions(+), 17 deletions(-) diff --git a/tests/block/006 b/tests/block/006 index 0b8a3c0..7ca1021 100755 --- a/tests/block/006 +++ b/tests/block/006 @@ -24,7 +24,7 @@ test() { _divide_timeout 2 FIO_PERF_FIELDS=("read iops") - if ! _init_null_blk queue_mode=2 submit_queues=2 blocking=1; then + if ! _init_null_blk submit_queues=2 blocking=1; then return 1 fi diff --git a/tests/block/010 b/tests/block/010 index b81208e..ed56135 100644 --- a/tests/block/010 +++ b/tests/block/010 @@ -49,7 +49,7 @@ test() { _divide_timeout 2 - if ! _init_null_blk queue_mode=2 submit_queues=16 nr_devices=32; then + if ! _init_null_blk submit_queues=16 nr_devices=32; then return 1 fi @@ -58,7 +58,7 @@ test() { run_fio_job _exit_null_blk - if ! _init_null_blk queue_mode=2 submit_queues=16 nr_devices=32 shared_tags=1; then + if ! _init_null_blk submit_queues=16 nr_devices=32 shared_tags=1; then return 1 fi diff --git a/tests/block/014 b/tests/block/014 index 04c34fa..449046a 100755 --- a/tests/block/014 +++ b/tests/block/014 @@ -18,7 +18,7 @@ test() { # The format is ",,,". Here, we # fail 50% of I/Os. - if ! _init_null_blk queue_mode=2 timeout='1,50,0,-1'; then + if ! _init_null_blk timeout='1,50,0,-1'; then return 1 fi diff --git a/tests/block/015 b/tests/block/015 index 79102a2..2e5cf35 100755 --- a/tests/block/015 +++ b/tests/block/015 @@ -20,7 +20,7 @@ test() { # The format is ",,,". Here, we # requeue 10% of the time. - if ! _init_null_blk queue_mode=2 requeue='1,10,0,-1'; then + if ! _init_null_blk requeue='1,10,0,-1'; then return 1 fi diff --git a/tests/block/016 b/tests/block/016 index c70b7d0..2b7a05f 100755 --- a/tests/block/016 +++ b/tests/block/016 @@ -20,7 +20,7 @@ requires() { test() { echo "Running ${TEST_NAME}" - if ! _init_null_blk queue_mode=2 irqmode=2 completion_nsec=2000000000; then + if ! _init_null_blk irqmode=2 completion_nsec=2000000000; then return 1 fi diff --git a/tests/block/017 b/tests/block/017 index e4a9259..c84b661 100755 --- a/tests/block/017 +++ b/tests/block/017 @@ -27,8 +27,7 @@ show_inflight() { test() { echo "Running ${TEST_NAME}" - if ! _init_null_blk queue_mode=2 irqmode=2 \ - completion_nsec=500000000; then + if ! _init_null_blk irqmode=2 completion_nsec=500000000; then return 1 fi diff --git a/tests/block/018 b/tests/block/018 index 7312723..a80ecbc 100755 --- a/tests/block/018 +++ b/tests/block/018 @@ -33,8 +33,7 @@ test() { echo "Running ${TEST_NAME}" - if ! _init_null_blk queue_mode=2 irqmode=2 \ - completion_nsec=1000000000; then + if ! _init_null_blk irqmode=2 completion_nsec=1000000000; then return 1 fi diff --git a/tests/block/020 b/tests/block/020 index b4887a2..eef63cb 100755 --- a/tests/block/020 +++ b/tests/block/020 @@ -20,7 +20,7 @@ requires() { test() { echo "Running ${TEST_NAME}" - if ! _init_null_blk queue_mode=2 irqmode=2 completion_nsec=2000000 \ + if ! _init_null_blk irqmode=2 completion_nsec=2000000 \ submit_queues=4 hw_queue_depth=1; then return 1 fi diff --git a/tests/block/022 b/tests/block/022 index 30b2a68..10851ff 100755 --- a/tests/block/022 +++ b/tests/block/022 @@ -28,7 +28,7 @@ test() { echo "Running ${TEST_NAME}" : "${TIMEOUT:=30}" - if ! _init_null_blk shared_tags=1 nr_devices=0 queue_mode=2; then + if ! _init_null_blk shared_tags=1 nr_devices=0; then return 1 fi diff --git a/tests/block/024 b/tests/block/024 index b40a869..6808db0 100755 --- a/tests/block/024 +++ b/tests/block/024 @@ -37,8 +37,7 @@ test() { # The maximum value for CONFIG_HZ is 1000. I.e., a tick is one # millisecond. So, make each I/O take half a millisecond. - if ! _init_null_blk queue_mode=2 irqmode=2 \ - completion_nsec=500000; then + if ! _init_null_blk irqmode=2 completion_nsec=500000; then return 1 fi diff --git a/tests/block/029 b/tests/block/029 index 0c4fe08..dcf4024 100755 --- a/tests/block/029 +++ b/tests/block/029 @@ -31,7 +31,7 @@ test() { local sq=/sys/kernel/config/nullb/nullb0/submit_queues : "${TIMEOUT:=30}" - _init_null_blk nr_devices=0 queue_mode=2 && + _init_null_blk nr_devices=0 && _configure_null_blk nullb0 completion_nsec=0 blocksize=512 \ size=16 memory_backed=1 power=1 && if { echo 1 >$sq; } 2>/dev/null; then diff --git a/tests/block/030 b/tests/block/030 index d2e5286..f08f772 100755 --- a/tests/block/030 +++ b/tests/block/030 @@ -22,7 +22,7 @@ test() { : "${TIMEOUT:=30}" # Legend: init_hctx=,,, # Set to $(nproc) + 1 to make loading of null_blk succeed. - if ! _init_null_blk nr_devices=0 queue_mode=2 \ + if ! _init_null_blk nr_devices=0 \ "init_hctx=$(nproc),100,$(($(nproc) + 1)),-1"; then echo "Loading null_blk failed" return 1 diff --git a/tests/block/031 b/tests/block/031 index cb4ba67..d253af8 100755 --- a/tests/block/031 +++ b/tests/block/031 @@ -18,7 +18,7 @@ test() { local fio_status bs=512 : "${TIMEOUT:=30}" - if ! _init_null_blk nr_devices=0 queue_mode=2 shared_tag_bitmap=1; then + if ! _init_null_blk nr_devices=0 shared_tag_bitmap=1; then echo "Loading null_blk failed" return 1 fi From patchwork Tue Jun 7 12:47:28 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871885 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 4B5DFC433EF for ; Tue, 7 Jun 2022 12:47:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244163AbiFGMru (ORCPT ); Tue, 7 Jun 2022 08:47:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35978 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242948AbiFGMru (ORCPT ); Tue, 7 Jun 2022 08:47:50 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 15EA4A189 for ; Tue, 7 Jun 2022 05:47:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=mMuOHIc+QnUZPAlEF+ZR+W7p5ZRovy3Tyoelagso/Z8=; b=1wwIuzFwhPRg1C3MCR3CCCw/Hw aL8Q5Xizpqr3DnbF8YF0z86d0ScD4yt6AasUfArK1NJwCmAz330APIe+AEC5nFxtqt533/LaNn8Ok dlU+2Onb47WOFaPmvGdjNE/JTU69xXB4GH5nAerX4vmDfUkiDVgmKJK4wgw37Qo3CB74Rmr5aQilo 33GUomlEO3P/q5CWLha+2V3Pa2tOAScV0JHLH4VhDW+t86IG8yZz8Z47jYmho+yb0WhKdhkxuhP93 QPbcYtDEz4L5Hu7/kTk0zQBjTDiDYChqBsbc+ctxuwq1Dyzz/qXSctg9NXHqOxHVCCqImfSrj1okB /JRhfpTw==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYce-007SWR-6e; Tue, 07 Jun 2022 12:47:48 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 02/13] common/null_blk: allow _configure_null_blk with built-in null_blk Date: Tue, 7 Jun 2022 14:47:28 +0200 Message-Id: <20220607124739.1259977-3-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Test that do use _configure_null_blk already configure do not actually require a built-in null_blk driver. Relax the check in _have_null_blk to just require a driver instead of a module, and instead set a skip reason instead of failing in _init_null_blk when null_blk is built-in or otherwise not available. Also try to load the null_blk module in _configure_null_blk as _init_null_blk is optional now and we thus can't rely on the module to be loaded. Signed-off-by: Christoph Hellwig --- common/null_blk | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/common/null_blk b/common/null_blk index 6611db0..30d54c2 100644 --- a/common/null_blk +++ b/common/null_blk @@ -4,8 +4,10 @@ # # null_blk helper functions. +. common/shellcheck + _have_null_blk() { - _have_modules null_blk + _have_driver null_blk } _remove_null_blk_devices() { @@ -22,6 +24,7 @@ _init_null_blk() { if (( RUN_FOR_ZONED )); then zoned="zoned=1"; fi if ! modprobe -r null_blk || ! modprobe null_blk "$@" "${zoned}" ; then + SKIP_REASON="requires modular null_blk" return 1 fi @@ -32,8 +35,12 @@ _init_null_blk() { # Configure one null_blk instance with name $1 and parameters $2..${$#}. _configure_null_blk() { local nullb=/sys/kernel/config/nullb/$1 param val - shift + + if [[ ! -d /sys/module/null_blk ]]; then + modprobe -q null_blk + fi + mkdir "$nullb" || return $? while [[ $# -gt 0 ]]; do param="${1%%=*}" @@ -46,5 +53,5 @@ _configure_null_blk() { _exit_null_blk() { _remove_null_blk_devices udevadm settle - modprobe -r null_blk + modprobe -r -q null_blk } From patchwork Tue Jun 7 12:47:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871886 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 D70BAC43334 for ; Tue, 7 Jun 2022 12:47:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242948AbiFGMrx (ORCPT ); Tue, 7 Jun 2022 08:47:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36162 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244165AbiFGMrw (ORCPT ); Tue, 7 Jun 2022 08:47:52 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C14D0101C1 for ; Tue, 7 Jun 2022 05:47:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=XGcDw+5ZFF149p0q/ozu/n6Dg7dA61lEb6sxxuCdLRU=; b=K8qjI8llXeBcPF3kfulce0zQvN 23AKM7IOG2//SoLXNc1qosckxeX0tNWstFAklQqZ1QPLAa3vhdbeJ9cSXlwnXx8UDjp89LILmHzzm hzKULVGr0qLuiOEdFxYrCsjdQyLQJlaEmMAIWBnL7BCVh/TECvXWk2DIKMIlxGDRO6maWTtu3ivdD h5Oc8SgKGrydS+Dn/Ch/sO+M9ezv/r0IrTvLMXTtn+SKjIlc52WVsTUOLle4NHbw80yUuZBEcqi3B bSs43dToOGSCZmpsj3WSAMP+Uia0Bg3vdgLITfGSnSpRWhIU0jg9xa/WKaWhGyaDVv7kwCfEi+h7h vufuOHCQ==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYch-007SXy-1N; Tue, 07 Jun 2022 12:47:51 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 03/13] common/null_blk: respect RUN_FOR_ZONED in _configure_null_blk Date: Tue, 7 Jun 2022 14:47:29 +0200 Message-Id: <20220607124739.1259977-4-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Create zoned devices in _configure_null_blk when RUN_FOR_ZONED is set, just like it is done in _init_null_blk Signed-off-by: Christoph Hellwig --- common/null_blk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/common/null_blk b/common/null_blk index 30d54c2..918ba44 100644 --- a/common/null_blk +++ b/common/null_blk @@ -42,6 +42,11 @@ _configure_null_blk() { fi mkdir "$nullb" || return $? + + if (( RUN_FOR_ZONED )); then + echo "1" > "$nullb/zoned" || return $? + fi + while [[ $# -gt 0 ]]; do param="${1%%=*}" val="${1#*=}" From patchwork Tue Jun 7 12:47:30 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871887 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 F410AC433EF for ; Tue, 7 Jun 2022 12:47:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244164AbiFGMr5 (ORCPT ); Tue, 7 Jun 2022 08:47:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36456 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244182AbiFGMr4 (ORCPT ); Tue, 7 Jun 2022 08:47:56 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BCF61A189 for ; Tue, 7 Jun 2022 05:47:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=fIIUnl2FFj3PC5UM3XNNeUdzjQLbccPKejN95eKVEjY=; b=Do0l2MqlpMQ2mzA0EkOXTJV2Zj DZSqJenmhBwOCNe9tuWwQDhAbSORQdYaG/MF1pKhvGSAwuMzbNF09HRUZLIr/L7UpIDUSIeAFixou JTPn5/NMcL9LwIdkKAAc7at4CBT3s9upYcVEAdijNQL8FIxg/9PcpRck2qusVdzvZ+XLjzQzLQk1/ l86Sq6V5Yp6HDqWpcwnusZBGkx3nG9ZaaJGsR6x2GgAiMrN9U2QTNHcHkHjmEBRQ+hHG3hTFJxzsG 8Khi+R+Bc7n5ewAdq2wSQ/nHs2/XHXhnWzH9lQp6+YAACtfMmX2MLTDHUGvTr3qd1A3Ma546qm63y Kt0RRJOg==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYcj-007SZY-MG; Tue, 07 Jun 2022 12:47:54 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 04/13] block/029: don't require modular null_blk Date: Tue, 7 Jun 2022 14:47:30 +0200 Message-Id: <20220607124739.1259977-5-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Drop the call to _init_null_blk and just operate on nullb1 instead, leaving the default device alone. Signed-off-by: Christoph Hellwig --- tests/block/029 | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/tests/block/029 b/tests/block/029 index dcf4024..b9a897d 100755 --- a/tests/block/029 +++ b/tests/block/029 @@ -21,25 +21,24 @@ modify_nr_hw_queues() { num_cpus=$(nproc) while [ "$(_uptime_s)" -lt "$deadline" ]; do sleep .1 - echo 1 > /sys/kernel/config/nullb/nullb0/submit_queues + echo 1 > /sys/kernel/config/nullb/nullb1/submit_queues sleep .1 - echo "$num_cpus" > /sys/kernel/config/nullb/nullb0/submit_queues + echo "$num_cpus" > /sys/kernel/config/nullb/nullb1/submit_queues done } test() { - local sq=/sys/kernel/config/nullb/nullb0/submit_queues + local sq=/sys/kernel/config/nullb/nullb1/submit_queues : "${TIMEOUT:=30}" - _init_null_blk nr_devices=0 && - _configure_null_blk nullb0 completion_nsec=0 blocksize=512 \ + _configure_null_blk nullb1 completion_nsec=0 blocksize=512 \ size=16 memory_backed=1 power=1 && if { echo 1 >$sq; } 2>/dev/null; then modify_nr_hw_queues & fio --rw=randwrite --bs=4K --loops=$((10**6)) \ --iodepth=64 --group_reporting --sync=1 --direct=1 \ - --ioengine=libaio --filename="/dev/nullb0" \ - --runtime="${TIMEOUT}" --name=nullb0 \ + --ioengine=libaio --filename="/dev/nullb1" \ + --runtime="${TIMEOUT}" --name=nullb1 \ --output="${RESULTS_DIR}/block/fio-output-029.txt" \ >>"$FULL" wait From patchwork Tue Jun 7 12:47:31 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871888 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 1B5D4CCA47C for ; Tue, 7 Jun 2022 12:48:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244186AbiFGMsG (ORCPT ); Tue, 7 Jun 2022 08:48:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37094 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244190AbiFGMsB (ORCPT ); Tue, 7 Jun 2022 08:48:01 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3F1F12125A for ; Tue, 7 Jun 2022 05:47:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=YZqL45OZLXfGdFUrW98mhAIJnOCPS8lTW1cNSXZmPb8=; b=Xd0eVz8TDrCafvXAThhPm70qRK JPGfqk9Bg0kknO8m1d+LwnGRHGdHg9ZwBIextQMHmgJE77em20hDPeKsPW89fA+EnoJ8xf+LPLBGl fFc55Upj74vx9ftwJBusN1aC0S/eJXcZBzcuRqu9xidZbAbE10P4c22g8qagv+XiMhLM2lMcsQM/n 8lmOUxTL27m617OogX8UBB5HqlJ673UpCk88nljjo9dl6J8rWvIu+H7VPS0yLSZUYPeLSlh3tsInE itzHHVrfFU9wf/8eFHvz8ByjGZK1IQdwtWLTWArXTxO555RlODCCPYJz6GZRwj54ndub1E3Ksoaot H7dT38aw==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYcm-007Sap-JP; Tue, 07 Jun 2022 12:47:57 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 05/13] block/006: convert to use _configure_null_blk Date: Tue, 7 Jun 2022 14:47:31 +0200 Message-Id: <20220607124739.1259977-6-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Switch to use _configure_null_blk so that built-in null_blk can be supported, which implies not using the default nullb0 device. Signed-off-by: Christoph Hellwig --- tests/block/006 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/block/006 b/tests/block/006 index 7ca1021..7d05b11 100755 --- a/tests/block/006 +++ b/tests/block/006 @@ -24,18 +24,18 @@ test() { _divide_timeout 2 FIO_PERF_FIELDS=("read iops") - if ! _init_null_blk submit_queues=2 blocking=1; then + if ! _configure_null_blk nullb1 submit_queues=2 blocking=1 power=1; then return 1 fi # run sync test _fio_perf --bs=4k --ioengine=sync --rw=randread --norandommap --name=sync \ - --filename=/dev/nullb0 --size=5g --direct=1 + --filename=/dev/nullb1 --size=5g --direct=1 # run async test _fio_perf --bs=4k --ioengine=libaio --iodepth=8 --numjobs="$(nproc)" \ --rw=randread --norandommap --name=async \ - --filename=/dev/nullb0 --size=5g --direct=1 + --filename=/dev/nullb1 --size=5g --direct=1 _exit_null_blk From patchwork Tue Jun 7 12:47:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871889 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 6720DC433EF for ; Tue, 7 Jun 2022 12:48:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244229AbiFGMsQ (ORCPT ); Tue, 7 Jun 2022 08:48:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37462 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244204AbiFGMsF (ORCPT ); Tue, 7 Jun 2022 08:48:05 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 25E0A1A820 for ; Tue, 7 Jun 2022 05:48:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=MSo0KHkZgIYFHJZ42AzFvKbwN7oNudFzfkVTVPAxH7Q=; b=IVafBXRXad32GvYRhNDEl3clBO r5RARe45fNs/bhCHVct7ljYWX69eM8u9O31MoB73vDo+cU3vtI084wFNzPiACeNfv2DslRoooFOjP IOkO/dNeWLpTCe99Dcof6rxKrxwMmt4barnic6gSUKoBhX59Wi/pm7LAuTz+7Et06wKJNgVCaa2BO zhCe8g2MHisHuumCghabiShNDPprVUTWOEsH+JBNjxqhYilI2UyhlnuWFhrdJJO9Pb2y0xdvEXpex OvfvIsZQudzg7wM2JxdzXR5EOlliOMPOgaZlL8sVarg4EoXQo8fmF3KIF08HMfc3ccfkBIqy8rC3b 4yDpyJpw==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYcp-007Scu-Hf; Tue, 07 Jun 2022 12:48:00 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 06/13] block/016: convert to use _configure_null_blk Date: Tue, 7 Jun 2022 14:47:32 +0200 Message-Id: <20220607124739.1259977-7-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Switch to use _configure_null_blk so that built-in null_blk can be supported, which implies not using the default nullb0 device. Signed-off-by: Christoph Hellwig --- tests/block/016 | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/block/016 b/tests/block/016 index 2b7a05f..775069c 100755 --- a/tests/block/016 +++ b/tests/block/016 @@ -20,21 +20,22 @@ requires() { test() { echo "Running ${TEST_NAME}" - if ! _init_null_blk irqmode=2 completion_nsec=2000000000; then + if ! _configure_null_blk nullb1 irqmode=2 completion_nsec=2000000000 \ + power=1; then return 1 fi # Start an I/O, which will take two seconds. - dd if=/dev/nullb0 of=/dev/null bs=512 iflag=direct count=1 status=none & + dd if=/dev/nullb1 of=/dev/null bs=512 iflag=direct count=1 status=none & sleep 0.5 # This will freeze the queue, and since we have an I/O in flight, it # will stay frozen until the I/O completes. - echo 64 > /sys/block/nullb0/queue/nr_requests & + echo 64 > /sys/block/nullb1/queue/nr_requests & sleep 0.5 # Do an I/O, which will wait for the queue to unfreeze. - dd if=/dev/nullb0 of=/dev/null bs=512 iflag=direct count=1 status=none & + dd if=/dev/nullb1 of=/dev/null bs=512 iflag=direct count=1 status=none & sleep 0.5 # While dd is blocked, send a signal which we know dd has a handler From patchwork Tue Jun 7 12:47:33 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871890 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 9A198C43334 for ; Tue, 7 Jun 2022 12:48:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244181AbiFGMsR (ORCPT ); Tue, 7 Jun 2022 08:48:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37466 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244176AbiFGMsG (ORCPT ); Tue, 7 Jun 2022 08:48:06 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2960C313B1 for ; Tue, 7 Jun 2022 05:48:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=Z2CkPnYlffK5GNSK1h/kYKOR8TaKi66VozXAAmMXrbg=; b=PlEUO63RaUw8Yb05QUhE3Hw4Sm UTBtg1NEoDWZXnOOUioVlRRy2ACVDd/5me050kMg7Kdqk5CdWKNUc98F6ULu7XxUJQ0CMmbNCdyBS bvW7PWGp8LiNH5ZZ9AgkyePVYkNL24eQu/sdmDNMWphn5BUXd4IKJsD+YmJ5ibNqurnM3IKuy8JlJ t8ZY4TEI65TghHH8aqR/S7KxkvIgzOF2JUwiUf+ebRmytPzImoYS1bBUF+GMRhEUdoGsthhuicnZB 7QV30rGDs6Qkug7wjZF1WtPx9JNZuTR3Q+E7bQP2q2QM8wU6IsXoP42yjSkilik1A5jIEgC/NIku6 oc/qX+uw==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYcs-007SeT-DH; Tue, 07 Jun 2022 12:48:02 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 07/13] block/017: convert to use _configure_null_blk Date: Tue, 7 Jun 2022 14:47:33 +0200 Message-Id: <20220607124739.1259977-8-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Switch to use _configure_null_blk so that built-in null_blk can be supported, which implies not using the default nullb0 device. Signed-off-by: Christoph Hellwig --- tests/block/017 | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/tests/block/017 b/tests/block/017 index c84b661..8596888 100755 --- a/tests/block/017 +++ b/tests/block/017 @@ -19,23 +19,24 @@ requires() { show_inflight() { awk '{ printf "sysfs inflight reads %d\nsysfs inflight writes %d\n", $1, $2 }' \ - /sys/block/nullb0/inflight - awk '{ print "sysfs stat " $9 }' /sys/block/nullb0/stat - awk '$3 == "nullb0" { print "diskstats " $12 }' /proc/diskstats + /sys/block/nullb1/inflight + awk '{ print "sysfs stat " $9 }' /sys/block/nullb1/stat + awk '$3 == "nullb1" { print "diskstats " $12 }' /proc/diskstats } test() { echo "Running ${TEST_NAME}" - if ! _init_null_blk irqmode=2 completion_nsec=500000000; then + if ! _configure_null_blk nullb1 irqmode=2 completion_nsec=500000000 \ + power=1; then return 1 fi - dd if=/dev/nullb0 of=/dev/null bs=4096 iflag=direct count=1 status=none & + dd if=/dev/nullb1 of=/dev/null bs=4096 iflag=direct count=1 status=none & sleep 0.1 show_inflight - dd if=/dev/zero of=/dev/nullb0 bs=4096 oflag=direct count=1 status=none & + dd if=/dev/zero of=/dev/nullb1 bs=4096 oflag=direct count=1 status=none & sleep 0.1 show_inflight From patchwork Tue Jun 7 12:47:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871891 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 4242FCCA47C for ; Tue, 7 Jun 2022 12:48:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244193AbiFGMsS (ORCPT ); Tue, 7 Jun 2022 08:48:18 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37614 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244190AbiFGMsG (ORCPT ); Tue, 7 Jun 2022 08:48:06 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E2DAF19030 for ; Tue, 7 Jun 2022 05:48:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=2W4S3a1VuQDwEOsgchh+sd14l85+LMpS0eeU2cEnqkk=; b=Cx8cgw2sFOrmacgGhGPeFwEEpQ BMQ1cXi7EjkrB+Sv5t/TWk0QSAqWpgtHK2Q1tQGLaSiVZop8sp9lGaD8kAwWNUAwoqt1QJXhT4WzS x5EW6lYw8yXX6lr0GFQMnHg72NKMnIloTjwxlXaoibMBy4/LBvy7N/u1/aBQ72MIQjroUX0loGgx/ s3chclR98h3cRU6VixpejVpiek5ZRCDleIPFQo4CiqAjdcXw686exMB60nBqrF/DYNk+fK/i+2K/r gbZknjqdmy752jfLFhfZlsAHDAWYtUYN2sqchQpqA14g7ra647v6yz3u7t4J3fT0m+DmHgzMyvHnC SkY3GDKg==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYcv-007Sfq-2d; Tue, 07 Jun 2022 12:48:05 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 08/13] block/018: convert to use _configure_null_blk Date: Tue, 7 Jun 2022 14:47:34 +0200 Message-Id: <20220607124739.1259977-9-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Switch to use _configure_null_blk so that built-in null_blk can be supported, which implies not using the default nullb0 device. Signed-off-by: Christoph Hellwig --- tests/block/018 | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/tests/block/018 b/tests/block/018 index a80ecbc..e7ac445 100755 --- a/tests/block/018 +++ b/tests/block/018 @@ -15,13 +15,13 @@ requires() { } init_times() { - init_read_ms="$(awk '{ print $4 }' /sys/block/nullb0/stat)" - init_write_ms="$(awk '{ print $8 }' /sys/block/nullb0/stat)" + init_read_ms="$(awk '{ print $4 }' /sys/block/nullb1/stat)" + init_write_ms="$(awk '{ print $8 }' /sys/block/nullb1/stat)" } show_times() { - read_ms="$(awk '{ print $4 }' /sys/block/nullb0/stat)" - write_ms="$(awk '{ print $8 }' /sys/block/nullb0/stat)" + read_ms="$(awk '{ print $4 }' /sys/block/nullb1/stat)" + write_ms="$(awk '{ print $8 }' /sys/block/nullb1/stat)" # Print rounded to the nearest second printf 'read %d s\n' $(((read_ms - init_read_ms + 500) / 1000)) @@ -33,22 +33,23 @@ test() { echo "Running ${TEST_NAME}" - if ! _init_null_blk irqmode=2 completion_nsec=1000000000; then + if ! _configure_null_blk nullb1 irqmode=2 completion_nsec=1000000000 \ + power=1; then return 1 fi init_times show_times - dd if=/dev/nullb0 of=/dev/null bs=4096 iflag=direct count=1 status=none + dd if=/dev/nullb1 of=/dev/null bs=4096 iflag=direct count=1 status=none show_times - dd if=/dev/zero of=/dev/nullb0 bs=4096 oflag=direct count=1 status=none + dd if=/dev/zero of=/dev/nullb1 bs=4096 oflag=direct count=1 status=none show_times - dd if=/dev/nullb0 of=/dev/null bs=4096 iflag=direct count=1 status=none & - dd if=/dev/zero of=/dev/nullb0 bs=4096 oflag=direct count=1 status=none & - dd if=/dev/zero of=/dev/nullb0 bs=4096 oflag=direct count=1 status=none & + dd if=/dev/nullb1 of=/dev/null bs=4096 iflag=direct count=1 status=none & + dd if=/dev/zero of=/dev/nullb1 bs=4096 oflag=direct count=1 status=none & + dd if=/dev/zero of=/dev/nullb1 bs=4096 oflag=direct count=1 status=none & wait show_times From patchwork Tue Jun 7 12:47:35 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871892 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 9394EC43334 for ; Tue, 7 Jun 2022 12:48:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244243AbiFGMsV (ORCPT ); Tue, 7 Jun 2022 08:48:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38320 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244224AbiFGMsQ (ORCPT ); Tue, 7 Jun 2022 08:48:16 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A48CD13EA2 for ; Tue, 7 Jun 2022 05:48:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=SqL/dT8JHaSK4BhmWma2PjJFslONxIxpXjyJPGhZHP4=; b=ilPT2d6dAB8Zaa9Jh0nMiRLpId xX+XrG6W6D8m81aOCDj8/0f1k9hvyZzD7GIA19RGtK+cRf3U9f2hri8dQyNCNRxDNtjHid67tWC7Y 4FIZ8ATSbnb/XGbFMf2weoq9aG+miu70hdXZafVKZfWXHFsCEYAdgRIOmhnsln+8rNXxMbTHMBlOP kOMkyh4jFZIElex/L+FIYkeGNVaX5HFcygdR4mz4RTfUSVPxEC/RuDSTn5qG8eQu3TaU7ATo/VqCK 6M2IShkY7Esr+3+dxVTQRvQ36JzHOh8JRpP5JHoMlgy8cB8E1TD6G+xT1PFObuYQ6TH1T8voYCQK6 nVmSKGAA==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYcx-007ShD-PJ; Tue, 07 Jun 2022 12:48:08 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 09/13] block/020: convert to use _configure_null_blk Date: Tue, 7 Jun 2022 14:47:35 +0200 Message-Id: <20220607124739.1259977-10-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Switch to use _configure_null_blk so that built-in null_blk can be supported, which implies not using the default nullb0 device. Signed-off-by: Christoph Hellwig --- tests/block/020 | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/block/020 b/tests/block/020 index eef63cb..3e8cbbd 100755 --- a/tests/block/020 +++ b/tests/block/020 @@ -20,14 +20,14 @@ requires() { test() { echo "Running ${TEST_NAME}" - if ! _init_null_blk irqmode=2 completion_nsec=2000000 \ - submit_queues=4 hw_queue_depth=1; then + if ! _configure_null_blk nullb1 irqmode=2 completion_nsec=2000000 \ + submit_queues=4 hw_queue_depth=1 power=1; then return 1 fi local scheds # shellcheck disable=SC2207 - scheds=($(sed 's/[][]//g' /sys/block/nullb0/queue/scheduler)) + scheds=($(sed 's/[][]//g' /sys/block/nullb1/queue/scheduler)) local max_iodepth=$(($(cat /proc/sys/fs/aio-max-nr) / $(nproc))) local iodepth=1024 @@ -36,10 +36,10 @@ test() { fi for sched in "${scheds[@]}"; do echo "Testing $sched" >> "$FULL" - echo "$sched" > /sys/block/nullb0/queue/scheduler + echo "$sched" > /sys/block/nullb1/queue/scheduler _fio_perf --bs=4k --ioengine=libaio --iodepth=$iodepth \ --numjobs="$(nproc)" --rw=randread --name=async \ - --filename=/dev/nullb0 --size=1g --direct=1 \ + --filename=/dev/nullb1 --size=1g --direct=1 \ --runtime=10 done From patchwork Tue Jun 7 12:47:36 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871893 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 DBEAAC433EF for ; Tue, 7 Jun 2022 12:48:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244199AbiFGMsY (ORCPT ); Tue, 7 Jun 2022 08:48:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37482 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244197AbiFGMsT (ORCPT ); Tue, 7 Jun 2022 08:48:19 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C29338BD0D for ; Tue, 7 Jun 2022 05:48:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=dSY9q8SiyA9w6r6j8Ui3CeYMf/mJmCFyCSTGI67/BE0=; b=Y/gLPNOT+jJx+7aMO7p4ydhSkl pzQ34Q0hIIrsMc3HouNiUp65EoP3D0DaKzkgx6l3hwr7zCEF6DV5D+vtbrlni/zvZPvOlQCIyxrdt xhLH0j1YomkGcCI+niFOte0COejebHNNVJ6OBDarI5Qco0Ir36qjr4LQARHj8GkLwtlWS9TlTgnDy FOyIwgF0xdIGMqZN80op8D57JfgHgirQ3cgI1TOr4HcDjruHTXhSKF6PcbSqIwDD4UJNo75tpzdF0 sHt8EsxHgjFgMmUn0XdKK0z1ZY/QoF9egxRUeoHAFpNWZy1jXWo43MdzoRc/pY1iiiHyac6zz+S+T guXw2Q9g==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYd0-007Sj7-Eu; Tue, 07 Jun 2022 12:48:10 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 10/13] block/021: convert to use _configure_null_blk Date: Tue, 7 Jun 2022 14:47:36 +0200 Message-Id: <20220607124739.1259977-11-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Switch to use _configure_null_blk so that built-in null_blk can be supported, which implies not using the default nullb0 device. Signed-off-by: Christoph Hellwig --- tests/block/021 | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/block/021 b/tests/block/021 index a1bbf45..89ebcd0 100755 --- a/tests/block/021 +++ b/tests/block/021 @@ -20,7 +20,7 @@ requires() { test() { echo "Running ${TEST_NAME}" - if ! _init_null_blk; then + if ! _configure_null_blk nullb1 power=1; then return 1 fi @@ -28,14 +28,14 @@ test() { local nr local scheds # shellcheck disable=SC2207 - scheds=($(sed 's/[][]//g' /sys/block/nullb0/queue/scheduler)) + scheds=($(sed 's/[][]//g' /sys/block/nullb1/queue/scheduler)) for sched in "${scheds[@]}"; do echo "Testing $sched" >> "$FULL" - echo "$sched" > /sys/block/nullb0/queue/scheduler - max_nr="$(cat /sys/block/nullb0/queue/nr_requests)" + echo "$sched" > /sys/block/nullb1/queue/scheduler + max_nr="$(cat /sys/block/nullb1/queue/nr_requests)" for ((nr = 4; nr <= max_nr; nr++)); do - echo "$nr" > /sys/block/nullb0/queue/nr_requests + echo "$nr" > /sys/block/nullb1/queue/nr_requests done done From patchwork Tue Jun 7 12:47:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871895 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 CB412C43334 for ; Tue, 7 Jun 2022 12:48:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244207AbiFGMs3 (ORCPT ); Tue, 7 Jun 2022 08:48:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37466 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244212AbiFGMsY (ORCPT ); Tue, 7 Jun 2022 08:48:24 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 94D30712EC for ; Tue, 7 Jun 2022 05:48:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=65paewg8yS0KNWz5DhHsYMpKIlKFDfT9YdBgnnfnxcU=; b=rLNa4Q87lZvYgqI7ErbjxKb88E coz6mt8MIYxsjAd1VnljGe5cqqiH57f2T1cNmzjvG398YrxmU7ds4oOq+o+zgnJjEHtIzVye5Swch ddL6pZ/gyUofPaALPHHdICPGTTlgvVBvNLD5qRdnvUJaC719mKi/u/npXuZ6mxi+zFQUSdEslEwnh mqcWXjSi/BvTJzTt3CCMEyy6xEYIN61dESbgEwJozMfkkMzgEPF5JTApkP7ht8PJMsJBZ9vJM/fzK pVNorfRoVRO8i1AJO+jh0oifue3YOJqSY9IM/yco1uerF/YAjtaCAMJt7sIdjqKrzxecB2uFwExcH XgYQ4qyg==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYd3-007Ski-6G; Tue, 07 Jun 2022 12:48:13 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 11/13] block/023: convert to use _configure_null_blk Date: Tue, 7 Jun 2022 14:47:37 +0200 Message-Id: <20220607124739.1259977-12-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Switch to use _configure_null_blk so that built-in null_blk can be supported, which implies not using the default nullb0 device. Signed-off-by: Christoph Hellwig --- tests/block/023 | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/block/023 b/tests/block/023 index 0f20f4a..db1cbe0 100755 --- a/tests/block/023 +++ b/tests/block/023 @@ -21,10 +21,11 @@ test() { local queue_mode for queue_mode in 0 2; do - if _init_null_blk gb=1 queue_mode="$queue_mode"; then + if _configure_null_blk nullb1 size=1024 \ + queue_mode="$queue_mode" power=1; then echo "Queue mode $queue_mode" - dd if=/dev/nullb0 of=/dev/null iflag=direct bs=64k status=none - dd if=/dev/null of=/dev/nullb0 oflag=direct bs=64k status=none + dd if=/dev/nullb1 of=/dev/null iflag=direct bs=64k status=none + dd if=/dev/null of=/dev/nullb1 oflag=direct bs=64k status=none _exit_null_blk fi done From patchwork Tue Jun 7 12:47:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871894 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 39B27C433EF for ; Tue, 7 Jun 2022 12:48:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244189AbiFGMs2 (ORCPT ); Tue, 7 Jun 2022 08:48:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37542 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244194AbiFGMsX (ORCPT ); Tue, 7 Jun 2022 08:48:23 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AB1E619030 for ; Tue, 7 Jun 2022 05:48:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=JeU7VryXXcal5oED3q371Aec/jIk1kAEDb5xYMDF3/I=; b=dtCJA6Q5h5ffJhDElvoQLhbDk+ fWYltdO7Abc4swugf3pFQ5IOsOpO6PxLDZHi6mZI2T73Okd5J1PL9AHilOyAs9EInHKWtszt/atgI 8W0j7KHWzibJ7DVpHrmNEeYC/B49nom5UU1COUmILDHOZl2zEw14zdinyU5NgHI74d8aDhGmxfRjT JIoIIMFIl4NyCRIoDtkOUdHQcD7VSO+0Uy4k5rAJ2RR1q+jyJIYd5Pb7UE/tndc2sVMytdXlenhrm TCHTmaK42CsFweoo/4inAXRY8tRHBcUGjVuQtwNDI0LtNoVsd7u8LqtW9Xi3/r2kTy2Ny4FPzxvLO PdLLzltw==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYd6-007SmN-0I; Tue, 07 Jun 2022 12:48:16 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 12/13] block/024: convert to use _configure_null_blk Date: Tue, 7 Jun 2022 14:47:38 +0200 Message-Id: <20220607124739.1259977-13-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Switch to use _configure_null_blk so that built-in null_blk can be supported, which implies not using the default nullb0 device. Signed-off-by: Christoph Hellwig --- tests/block/024 | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/tests/block/024 b/tests/block/024 index 6808db0..2a7c934 100755 --- a/tests/block/024 +++ b/tests/block/024 @@ -17,13 +17,13 @@ requires() { } init_times() { - init_read_ms="$(awk '{ print $4 }' /sys/block/nullb0/stat)" - init_write_ms="$(awk '{ print $8 }' /sys/block/nullb0/stat)" + init_read_ms="$(awk '{ print $4 }' /sys/block/nullb1/stat)" + init_write_ms="$(awk '{ print $8 }' /sys/block/nullb1/stat)" } show_times() { - read_ms="$(awk '{ print $4 }' /sys/block/nullb0/stat)" - write_ms="$(awk '{ print $8 }' /sys/block/nullb0/stat)" + read_ms="$(awk '{ print $4 }' /sys/block/nullb1/stat)" + write_ms="$(awk '{ print $8 }' /sys/block/nullb1/stat)" # Print rounded to the nearest second printf 'read %d s\n' $(((read_ms - init_read_ms + 500) / 1000)) @@ -37,7 +37,8 @@ test() { # The maximum value for CONFIG_HZ is 1000. I.e., a tick is one # millisecond. So, make each I/O take half a millisecond. - if ! _init_null_blk irqmode=2 completion_nsec=500000; then + if ! _configure_null_blk nullb1 irqmode=2 completion_nsec=500000 \ + power=1; then return 1 fi @@ -46,16 +47,16 @@ test() { # 1500 * 0.5 ms is 0.75 seconds, allowing for some overhead so # that it rounds to one second. - dd if=/dev/nullb0 of=/dev/null bs=4096 iflag=direct count=1500 status=none + dd if=/dev/nullb1 of=/dev/null bs=4096 iflag=direct count=1500 status=none show_times - dd if=/dev/zero of=/dev/nullb0 bs=4096 oflag=direct count=1500 status=none + dd if=/dev/zero of=/dev/nullb1 bs=4096 oflag=direct count=1500 status=none show_times # 1800 * 0.5 ms is 0.9 seconds. - dd if=/dev/nullb0 of=/dev/null bs=4096 iflag=direct count=1500 status=none & - dd if=/dev/zero of=/dev/nullb0 bs=4096 oflag=direct count=1800 status=none & - dd if=/dev/zero of=/dev/nullb0 bs=4096 oflag=direct count=1800 status=none & + dd if=/dev/nullb1 of=/dev/null bs=4096 iflag=direct count=1500 status=none & + dd if=/dev/zero of=/dev/nullb1 bs=4096 oflag=direct count=1800 status=none & + dd if=/dev/zero of=/dev/nullb1 bs=4096 oflag=direct count=1800 status=none & wait show_times From patchwork Tue Jun 7 12:47:39 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12871896 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 D288BC43334 for ; Tue, 7 Jun 2022 12:48:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244206AbiFGMsb (ORCPT ); Tue, 7 Jun 2022 08:48:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39384 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244238AbiFGMs0 (ORCPT ); Tue, 7 Jun 2022 08:48:26 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 05B7027FDF for ; Tue, 7 Jun 2022 05:48:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description; bh=9ImW3ViAH4R/6++YirlEucp0ES3EGzNnPCCbYMq0OV8=; b=Agj0jyta1cI2r67tQeRCu/M4pF 0Woaeh+wmoy0rItA+rYZgoNRAa3HF/1uowgcBgn11Et+M1BSAjc26fRzfL01zXFBpgWakF1mRo8hG frxNUEgI+P0Jn7hZe4jjw3Pt6D8HQRdOcfniyzIC3yA3HV0TPf3XcM9cWEAI7damySpahh9glpsS1 2/WiCVMdlk3B6z+aUtEMVeCe6qOhmgfnH9sdugcx6ZJUi1wWW75UNjqTrbHUMn+bNCk8G1a1qDIE4 Id1FQkODVmMOXzp0xDYFOlufovdE+hVQRZLQ1yP8cxNEMw/aQ4m2u8Wt5aPLiVJf437Vfwv/zD4NR D82nKXlA==; Received: from [2001:4bb8:190:726c:b34a:228:52ee:6d34] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nyYd8-007Snm-PW; Tue, 07 Jun 2022 12:48:19 +0000 From: Christoph Hellwig To: Shin'ichiro Kawasaki Cc: linux-block@vger.kernel.org Subject: [PATCH blktests 13/13] zbd: allow falling back to built-in null_blk Date: Tue, 7 Jun 2022 14:47:39 +0200 Message-Id: <20220607124739.1259977-14-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220607124739.1259977-1-hch@lst.de> References: <20220607124739.1259977-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Use _configure_null_blk to configure the fallback device and thus allow for a built-in null_blk driver. Signed-off-by: Christoph Hellwig --- tests/zbd/rc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/zbd/rc b/tests/zbd/rc index 9deadc1..fea55d6 100644 --- a/tests/zbd/rc +++ b/tests/zbd/rc @@ -13,7 +13,7 @@ group_requires() { _have_root && _have_program blkzone && _have_program dd && - _have_kernel_option BLK_DEV_ZONED && _have_modules null_blk && + _have_kernel_option BLK_DEV_ZONED && _have_null_blk && _have_module_param null_blk zoned } @@ -25,10 +25,11 @@ group_device_requires() { } _fallback_null_blk_zoned() { - if ! _init_null_blk zone_size=4 gb=1 zoned=1 ; then + if ! _configure_null_blk nullb1 zone_size=4 size=1024 zoned=1 \ + power=1; then return 1 fi - echo /dev/nullb0 + echo /dev/nullb1 } #