From 9d3f5740f73c66603aece0ea031098d591d34457 Mon Sep 17 00:00:00 2001 From: xiaochn Date: Wed, 26 Mar 2025 08:35:37 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Ddisk=E5=A4=A7=E5=B0=8F?= =?UTF-8?q?=E8=AE=A1=E7=AE=97=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 每个扇区大小通常为512字节,除以2即转化为KB --- tests/compatible/disk/common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/compatible/disk/common.py b/tests/compatible/disk/common.py index b7127a7..690893f 100644 --- a/tests/compatible/disk/common.py +++ b/tests/compatible/disk/common.py @@ -146,7 +146,7 @@ def vfs_test(logger, command, disk, filesystems): if not os.path.exists(proc_path): proc_path = os.path.join("/sys/block/*/", disk) size = getoutput("cat %s/size" % proc_path) - size = int(size) / 2 / 2 + size = int(size) / 2 if size <= 0: logger.error( "Device %s size is not suitable for testing." % device) -- Gitee