mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-06-07 11:45:36 +02:00
27 lines
969 B
Diff
27 lines
969 B
Diff
From 4268b52193e07dc767aad3674d7362abe07cd61c Mon Sep 17 00:00:00 2001
|
|
From: Natanael Copa <ncopa@alpinelinux.org>
|
|
Date: Wed, 28 May 2025 14:19:10 +0200
|
|
Subject: [PATCH] Ensure we read full block from nvme pipe
|
|
|
|
Budybox dd does not guarantee that full block is read without explicitly
|
|
setting iflag=fullblock. This resulted in test failure on loongarch64.
|
|
---
|
|
persistent-storage | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/persistent-storage b/persistent-storage
|
|
index 2ccd2c2..4954e56 100644
|
|
--- a/persistent-storage
|
|
+++ b/persistent-storage
|
|
@@ -121,7 +121,7 @@ if [ "${MDEV#nvme}" != "$MDEV" ] && [ "$model" = "Amazon_Elastic_Block_Store" ]
|
|
n=30
|
|
while [ $n -gt 0 ]; do
|
|
ebs_alias=$(nvme id-ctrl -b /dev/$_check_dev \
|
|
- | dd bs=32 skip=96 count=1 2>/dev/null \
|
|
+ | dd bs=32 skip=96 count=1 iflag=fullblock 2>/dev/null \
|
|
| sed -nre '/^(\/dev\/)?(s|xv)d[a-z]{1,2} /p' \
|
|
| tr -d ' ')
|
|
if [ -n "$ebs_alias" ]; then
|
|
--
|
|
2.49.0
|
|
|