From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=170.10.129.124 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796192904; b=ypLtmy/3wGdkXy0zlnaCut06x6hlmNU1L3MSBSsqxkkG52JE+11g5UZWevhwwgG+AYDN 2pnNMNbjXmfL0y8esoDFkprOrL/coHpyTioD9QE1G0NsChG4fzobSyKphPXHy8x8mODV3 alB+67vC8fXgI2/Dwwd/M07Tfe2tAc8GpTXG5LLqm0D/8b8jJQ0KoCONgzstpgJRzlG20 ZuDmF5/eGV8mYmRPaVlNGdvQVoi0vfHyy87DUYXnd/2mbZwwb6rB7FjpzfXC3mWBir/Pu NYUQ4sAmOkF30qtu9Ev0kRYzQvDEDMnMzlvoqfAXvv3lDzzrDw8SPxlbHZSRfaVYazw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796192904; h=DMARC-Filter:DKIM-Signature:Received:X-MC-Unique: X-Mimecast-MFC-AGG-ID:Received:DKIM-Signature:X-Google-DKIM-Signature: X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received: X-Received:Received:Date:From:To:Cc:Subject:Message-ID:References: MIME-Version:Content-Type:Content-Disposition:In-Reply-To; bh=xxGBXiOJh7OvQ5pR2ju4z1ruIM0msU5odWpvE5DBt68=; b=V/5B16MdhNOTT2Lo6/ACB9aiT79O9JradwT9x646bNJAx7Yh39485b/jY5bXzV3BkmTD Y8T81f6pLTo/j0q7KNb+nB9L4A9G7A6ded5GoKy7pweKf3nSuDQesYXv243Euv/mS/NVw 1tXSpJvDH8DCg1VqpDqWiAf2n8s8T3bxpvLjMjKtJwV6DQubnsixb6SznzgHycIhmXJYG dWGDjQAlt2RwC7XL8aW12N1t2dVa++29RSEf2UemeSaz5COW/WyY+vL279EKCAvTn1wvU cG2GZ1ypEL4KfbQ2dZHU3XGU+g5lsQAk9HdRKYuEiSrs825cUmlEiNtkIIYyeXG12dQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=KuHa5YXb; dkim=pass header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=google header.b="aoD3oi/R"; arc=none smtp.remote-ip=170.10.129.124 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 51B83606A322 for ; Wed, 2 Dec 2026 06:28:24 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 51B83606A322 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=KuHa5YXb; dkim=pass (2048-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=google header.b=aoD3oi/R DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1796192903; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=xxGBXiOJh7OvQ5pR2ju4z1ruIM0msU5odWpvE5DBt68=; b=KuHa5YXbmPYk+8cGW2KpSiJmz4WN2tNIUua3EYQEGvlJYVuPbUVqFdj8yg5TihSBzwBd8Q 5MWZ+2OWz2uOA79tRDZxE0jj/VYb2upmr4TTeq0gId/a+zQFNTzvZIO3GrpTnZLfHtf/9t TUEehIkGP0D8xrgjuqJqAO8ZWfeUtKc= Received: from mail-dy1-f198.google.com (mail-dy1-f198.google.com [74.125.82.198]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-627-_7CiQQE-O12j-y8RC9nnhg-1; Wed, 2 Dec 2026 06:28:21 +0000 X-MC-Unique: _7CiQQE-O12j-y8RC9nnhg-1 X-Mimecast-MFC-AGG-ID: _7CiQQE-O12j-y8RC9nnhg_1796192900 Received: by mail-dy1-f198.google.com with SMTP id 5a478bee46e88-386ad819860so9591081eec.0 for ; Tue, 01 Dec 2026 22:28:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=google; t=1796192900; x=1796797700; darn=vger.kernel.org; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:from:to:cc:subject :date:message-id:reply-to:content-type; bh=xxGBXiOJh7OvQ5pR2ju4z1ruIM0msU5odWpvE5DBt68=; b=aoD3oi/RWUSgVNoSbNlvEeCHMVHYUFdw1lBejpNMaiNpIxi/zhodJnBYA0jVuGrKal T02eZGo2ePmqwIhuReye2eNRW/36QNEmTJTmFhwe13JB97A6H3453B+Ror5a8tPmBzG5 0gPlDVQ5MOpPJXA0MagDeYp2bCi1DKGTqkUB4RP8IBjRYRdLwiqdnoHrWaCeqFFsLkhr /Y1WdwiqrsOn2hFEG4b8TZ9WWt2EzZwnVcaPx6ZqOTnAT3493DtKCPX3W9EiPJl6C3mV 8jUbIJKyCVvb1sxGpKHjfIYEBF9nF5R5cz/HjbmrbZlYQIfIRe4h86QCYg1oHHlUi5bX 5gXQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796192900; x=1796797700; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=xxGBXiOJh7OvQ5pR2ju4z1ruIM0msU5odWpvE5DBt68=; b=T/QAsEaIdHJmqS0+BzrEO/0HC7Zjij5o95HMich/BsQMuczYkz1eZhL9QQufm4PRkj VarJYEv3mg54wFgTd6IshoCGAYz9y+tzzPzCl4X1tN+Xlc9V6f4olXD+1R5pxwCWQV1n eK1AredBIbaviUUNMPBC9HbJisS3MNaUxbfwLQMVY5tiT9uXZnEKupLZ2qAEbTT9MCfd nZOQl6IXA6gke9ActLFdYRMOm/oWwsNUyigexNbmqSiLOAr2g1nbCrtlOD+UHkMIvbPS fQmjPBCxOBBidptdPo8Xfq7/Ja1XKvnvkLuTuVZAFHYGKYgMbT/xqcsfTQVYAiMoJXE8 8s+g== X-Forwarded-Encrypted: i=1; AL+hErFe8saMjjwuBIwdO9Ky22SuOsBjeoqh31vMCfUkWi8lfsklRaSKslmD6/56UMJaupbt1omDXE+AA1XmWg==@vger.kernel.org X-Gm-Message-State: APuU4Z89pr2h9aqFERGd2KIMy0zafWzDrxTXkSFMvebBMZgcv0jbJnfX Uv+awj6WRTw3vKIdBd62qVehhRuiu/k0yfX/tyY8TXKjEY2qE7rJkdUy/Phi6C4BYAnkTj9KyM3 ual3sspLhTiAub4kqIvdjF8IwnfNvltqjESk1HKkVZzCnQmA3PFp/eohnfvwTx5U= X-Gm-Gg: AZFdTZeuo7snP7+92W5C+W6w7yVTHoXDAeXKKN36jgw4Cwcfc2gfcWwc/fxki6vP6wF zMqOKCSWhBLnTF71VqvLJA7Djt57vD+myi2SIgYS+02zlfS9cu8IvvRDMhSd2yNK66lZe05eUaX 4WyWoO/icfBtfepzImPyYGC29o1xFGJiGBYooQh8yzvdWw2VqvSE2Ah8TAJeFR53UJ414OycOm6 TFH3HPbsokNi7mGqNcnNPXaC1OY+1c7Pk0fuG0aS3z69AotuCr9aKzliMu4UyuwJJbXxxW6KKkn xUKUw50fHZcpsjW7exJYRVj7Y5zgVwicx2IZ8uyK7g300Ra+CvfE9d/liIIw3Z/eN6d5eft98PW vhvQDGEllggLmdeSJ6rO3KeDOAu5icw1MarAIrbqruAM4 X-Received: by 2002:a05:7301:d805:b0:385:ce95:2e14 with SMTP id 5a478bee46e88-385ce953221mr37072880eec.30.1796192900166; Tue, 01 Dec 2026 22:28:20 -0800 (PST) X-Received: by 2002:a05:7301:d805:b0:385:ce95:2e14 with SMTP id 5a478bee46e88-385ce953221mr37072860eec.30.1796192899459; Tue, 01 Dec 2026 22:28:19 -0800 (PST) Received: from redhat.com ([2401:4900:1f27:d78:e666:5427:b8d:48a6]) by smtp.gmail.com with ESMTPSA id 5a478bee46e88-386ffc4ab65sm29004470eec.22.2026.12.01.22.28.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Dec 2026 22:28:19 -0800 (PST) Date: Wed, 2 Dec 2026 11:58:13 +0530 From: Utkarsh Singh To: Ming Lei Cc: Jens Axboe , linux-block@vger.kernel.org, Caleb Sander Mateos , Shuah Khan , linux-kselftest@vger.kernel.org Subject: Re: [PATCH v2 0/5] ublk: fix completion of short READ/WRITE Message-ID: References: <20261201095153.1012606-1-tom.leiming@gmail.com> X-Mailing-List: linux-block@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <20261201095153.1012606-1-tom.leiming@gmail.com> On Tue, Dec 01, 2026 at 03:51:46AM -0600, Ming Lei wrote: >Hi Jens, > >Since commit a8a79eba22dc ("ublk: lift checks out of >ublk_{,un}map_io()"), a short result from the ublk server is ignored for >WRITE, and for READ on user copy, zero copy, auto buffer registration >and shmem zero copy devices: the request is completed in full. > I tested this patch series on fe6ff8d5d675 ("Linux 7.4-rc5"), x86_64. test_loop_09.sh and test_stripe_01..06.sh pass. I traced loop_09 to check nothing was silently skipped: all six modes run and NR_RUN reaches 6. Also confirmed the original failure on plain v7.4-rc5 -- dd reported 17 blocks written with rc=0 while 60K never reached the backing file -- and its absence with the series applied. For patch 2 I hacked fault_inject to complete READ/WRITE with an injected byte count. With dd bs=4096 (blk_rq_bytes 4096, logical block size 512): io->res = 100 (not block aligned) -> EIO io->res = 0 -> EIO io->res = 8192 (> blk_rq_bytes, aligned) -> EIO io->res = 4096 (full length) -> completes normally io->res = 2048 (short but aligned) -> requeued, completes So all three rejection branches fire and a legitimate short result is still requeued rather than rejected. Happy to post the fault_inject --bad_res knob separately if useful. Patch 4 is untested: kublk has no zoned target, so a short zone append can't be exercised from the suite at all. Tested-by: Utkarsh Singh