From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.openvz.org (mail.openvz.org [69.168.225.77]) by lore.virtuozzo.com (Postfix) with ESMTPS id ED9488017D for ; Wed, 4 Nov 2026 21:47:55 +0000 (UTC) Received: from mail.openvz.org (localhost [127.0.0.1]) by mail.openvz.org (8.14.4/8.14.4) with ESMTP id 6A4Lkf2K027148; Thu, 5 Nov 2026 00:46:42 +0300 DKIM-Filter: OpenDKIM Filter v2.11.0 mail.openvz.org 6A4Lkf2K027148 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=openvz.org; s=default; t=1793828803; bh=vVBebYbrA62uAmSDQ4t3mtzcZQr9A6p6+ieMWmkZTfE=; h=From:To:Date:Cc:Subject:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe; b=i+h7b5h+P27gIPQqzENKddag98EqGF+/RU+B/7qNGCTP97aUQnyuapsCEiGjPNw9d f0AJz7yz80kfFaw3x66sT5UT5WL+oI9uWj0ZWTt3XK/lGUEgGhkmxBVZbY0J/cbaeP cx3s4/t0EywuLJh9YtWzjMngXnEYoXWA6kvwFaRoJmg/q06vSsL9om9VjvIFReBm4e jycFT+P/89o2qT62WRKFZkHwtc6s6clwfOcGxWRqmfQYVpE4K4LzXtffeDW/04yyfS NOc/0o/uDXTvVbiceYgtgkvYplOEEpuxbB0EoeUX46vW3yKZqREL6qvx03FuuaEAzn hFaeAwxkYhe7g== Received: from mail-wm1-f71.google.com (mail-wm1-f71.google.com [209.85.128.71]) by mail.openvz.org (8.14.4/8.14.4) with ESMTP id 6A4LkdOb027138 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=FAIL) for ; Thu, 5 Nov 2026 00:46:39 +0300 DKIM-Filter: OpenDKIM Filter v2.11.0 mail.openvz.org 6A4LkdOb027138 Authentication-Results: mail.openvz.org; dkim=pass (2048-bit key) header.d=openvz.org header.i=@openvz.org header.b="AiEL+KV6" Received: by mail-wm1-f71.google.com with SMTP id 5b1f17b1804b1-4a359c7f47bso11539905e9.2 for ; Wed, 04 Nov 2026 13:46:39 -0800 (PST) X-Forwarded-Encrypted: i=2; AKwUvBzq2T32zjbVsbMkBvKiJ7eqW4YnFhltx9PJl1b54UPm8jV9LXQWGCI+Zav7HDG5+LSPG1eBZg==@openvz.org X-Gm-Message-State: APuU4Z8rTKb553j6zPcAU/AJP+QiWSLDNUR+OJrweNVbDpdDPUujQPHp kreCJGIqwaF/X4PM3G3Lr7rAfv31YQwn6hD1YI248gJKmTIXvXdKX8OJHWRFeC7EtqEMActHT1d 9gTrgk9BNEKtVYls+Y7Fg77nYd90ljqdwZbkUouEcfJwoGCCs0slr0w== X-Gm-Gg: AYBFou1CRzJVcNy1FcZiXf3s5O4673At3rnOy8qM3yysyaZUWKIZ47POUc8PREUNbD1 wGlZC8YSfgfosz/K6Aa1OYO3+nA3LZ6UYvoXIFkay5mT2NYpWYDazGiYJJ0xxPfQGLQ8ZaRqxkR PDd1XzpmQmVusF3CmHprw12OABMDQRmRfsPV+uTBpAZ+LrPd28RDgfhbU0xkF5UhKhdbg8PmhvK w/TyGPiw8h0p6kaL5lvKcNylkw7p4OtUCatb1VZXTm+ZwFzVEu5bdbdcT5Oss965gPoMJJdCGyS 6Cg1GM0Mzw== X-Received: by 2002:a05:600c:310e:b0:4a2:10f9:37ce with SMTP id 5b1f17b1804b1-4ac1709ae70mr386688895e9.15.1793828799032; Wed, 04 Nov 2026 13:46:39 -0800 (PST) X-Received: by 2002:a05:600c:310e:b0:4a2:10f9:37ce with SMTP id 5b1f17b1804b1-4ac1709ae70mr386688655e9.15.1793828798620; Wed, 04 Nov 2026 13:46:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1793828798; cv=none; d=google.com; s=arc-20260327; b=W/kPLULMqxQe/+8cpYuLzX5SpzZMuGX5BHtJJKrF4cAPJ+TmTka0AaqOiR7QlWDvCC 8F5wyVbD3P36cvOARbIYW/EuilyfJKtfFMSHahKvoCg1UxieeaOP9ffpXwj+FYFo851m hlCCxC8P4tvyvm1e1bhblgYBhirFBbT+HeMu7YD3dXavqZ44y00V+JkLFnHxivOywt+m YLYeuLjnLRHknwlP/uWiiawf+54NOaHdqnzbxvhqLmF2JjvrVcKudpoo7Vll3ZLw0u/X y46O1YRrT8TvFkB5xptr2/s9xTG8QVvxLrCzmBPNx5Q3ysjifrr31pjVyFilbpjq6zFJ nWGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:dkim-signature; bh=1veLkKtQZz5G3rQ4Fcqvt2FoanoM05SVcJlO6MQ2C7c=; fh=RtW/11vFwhHGYVGXBLwlsmPJgOPW7uJiD+CvAkxvWSI=; b=mQ79wALNTe+gmZdVNu6WPzWKxyPwiIZx94r1m9jgLzfE1s/rsNYa3TCvtzDlN85nwb ZPNt1Y+L37Ale/6w7TIhEgDL+X24zH/d7ryZixP7PeaInMOJPVMftrmPF7zgkBf08Kq9 VKYPH1OC7v1nbpl+1GZsKaQnKkrluyKcFyJIlnVZv/urgpZL4ONJWpNUykfOhDPcG5h5 f6Pfe5qxzqq7kXD1gpBbtDrER6INDT4MczcQA9Y49f5oRLhgSXl7W+QvQH5/96YgvFz0 b/a7a36VbBY0jj3nkMhj7gepnp5ozAVZ6T3mzl4GBdTguNtYB823evrwhDGFJOIPukQM bGVg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@openvz.org header.s=google header.b=AiEL+KV6; spf=softfail (google.com: domain of transitioning den@openvz.org does not designate 2a06:5b06:b600:300:162e:5a6e:fd46:18b7 as permitted sender) smtp.mailfrom=den@openvz.org; dara=neutral header.i=@openvz.org Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id 5b1f17b1804b1-4b43de75041sor7100205e9.13.2026.11.04.13.46.38 for (Google Transport Security); Wed, 04 Nov 2026 13:46:38 -0800 (PST) Received-SPF: softfail (google.com: domain of transitioning den@openvz.org does not designate 2a06:5b06:b600:300:162e:5a6e:fd46:18b7 as permitted sender) client-ip=2a06:5b06:b600:300:162e:5a6e:fd46:18b7; Authentication-Results: mx.google.com; dkim=pass header.i=@openvz.org header.s=google header.b=AiEL+KV6; spf=softfail (google.com: domain of transitioning den@openvz.org does not designate 2a06:5b06:b600:300:162e:5a6e:fd46:18b7 as permitted sender) smtp.mailfrom=den@openvz.org; dara=neutral header.i=@openvz.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=openvz.org; s=google; t=1793828798; x=1794433598; darn=openvz.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to:content-type; bh=1veLkKtQZz5G3rQ4Fcqvt2FoanoM05SVcJlO6MQ2C7c=; b=AiEL+KV6czjXu3ezFU5IbL2hf2vaJe9cmF7tLYgURidLMO/hm+30dz7emqHPakthO4 nWJYT7e3xrWW3mWJXqTw0RQmJ3ctIv8sg9y6IBOl48LzWvmt9hgomr081Zhkm+Jx7xBG kyiV2a4jYpI5Yz9/asbOb7ARFwQpux+rcRsnse2DlbGLo/O+DZ8IZGtr7/xYSkAmFIcX unkIN0oWa3J51jt440PWUPly43HyGmLe3pJakQnISFPILG6961XGxHcB4yUmUqShnP3U cdHXOo88oSnpjYoFGb+B/nG/SbKZBDpIrjB9QdFjCUFdRvh3QW57gyQzTamOBhTULYHN PqIw== X-Forwarded-Encrypted: i=1; AKwUvBzePrBzoAdEuQxKGk2cvZnhVHutDt+98udGFy95Bp8pG7DzHgSprn6SVCeJqdRpPohU6gA3cg==@openvz.org X-Received: by 2002:a05:600c:8706:b0:4a1:e0d5:293e with SMTP id 5b1f17b1804b1-4ac1765d3ddmr406718915e9.21.1793828798124; Wed, 04 Nov 2026 13:46:38 -0800 (PST) Received: from athena.sw.ru ([2a06:5b06:b600:300:162e:5a6e:fd46:18b7]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4b56e2ae72dsm24489635e9.3.2026.11.04.13.46.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Nov 2026 13:46:37 -0800 (PST) From: "Denis V. Lunev" To: andrey.zhadchenko@virtuozzo.com Date: Wed, 4 Nov 2026 22:46:33 +0100 Message-ID: <20261104214635.2063009-1-den@openvz.org> X-Mailer: git-send-email 2.53.0 MIME-Version: 1.0 X-OZ-Fwd: true Cc: devel@openvz.org Subject: [Devel] [PATCH hci-8.1 0/2] dm-ploop: fix flip_upper_deltas panicking the host in its pre-flip check X-BeenThere: devel@openvz.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: OpenVZ development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: devel-bounces@openvz.org Errors-To: devel-bounces@openvz.org ploop_check_delta_before_flip() runs on every flip_upper_deltas, as PLOOP_DEBUG is always defined in dm-ploop-cmd.c, and both of its ways out of the walk are broken (VSTOR-153445): - patch 1: when it finds a cluster both deltas map, it returns -EEXIST with two md_locks held and interrupts disabled. The next pio on that BAT page spins on the lock forever, and the host panics on a hard lockup; - patch 2: the walk never stops at the end of the BAT of the lower delta, so once the device has grown past it the flip oopses on a NULL md page. Neither is reached through the ploop library. Its reverse merge, the only sender of the flip, grows the lower delta to the size of the top and clears the clusters both deltas map before it flips, and a device it mounted has the lower delta read-only, which the flip refuses with EACCES before the check. Both take a flip of a table built with the lower delta read-write, so VSTOR-153445 has no RK for 8.0. This is the fix the v2 cover letter of "dm-ploop: fix the pio submission stop around cmds" said would be sent separately. Tested on dev-cl04, stock 6.12.0-211.52.1.22.11.vz10, dm-ploop built out of tree with the series on top of the applied dm-ploop v2: - a chain whose top delta overwrote clusters of the base and a direct flip_upper_deltas: the stock module returns to dmsetup in atomic context ("BUG: scheduling while atomic"), and a read of the device then panics the host with "Hard LOCKUP". With the series the message fails with EEXIST and the device keeps working; - set_noresume, suspend, a grow to 2T and flip_upper_deltas: the stock module oopses at ploop_check_delta_before_flip+0x86, with the series the flip completes and the images keep their data; - the ploop pytest suite, ploop format, passes. Denis V. Lunev (2): dm-ploop: fix flip_upper_deltas returning with two md_locks held dm-ploop: fix flip_upper_deltas walking past the BAT of the lower delta drivers/md/dm-ploop-cmd.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) base-commit: 1f21db982845109040d1feb279e9ee34f8e6f065 -- 2.53.0 _______________________________________________ Devel mailing list Devel@openvz.org https://lists.openvz.org/mailman/listinfo/devel