[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#15347: [PATCH 18/19] libparted: Flush parent device on open (#962611
From: |
Brian C. Lane |
Subject: |
bug#15347: [PATCH 18/19] libparted: Flush parent device on open (#962611) |
Date: |
Wed, 11 Sep 2013 12:25:08 -0700 |
From: "Brian C. Lane" <address@hidden>
Parted probes for filesystems using geometry offsets into the parent
device, not the partition device itself. This means it may get stale
information if a partition has just been formatted.
On kernels before 2.6 this will also flush all partition devices. On 2.6
and newer kernels it will only flush the parent device.
* libparted/arch/linux.c (linux_open): Always call _flush_cache
---
libparted/arch/linux.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c
index 375be83..492f828 100644
--- a/libparted/arch/linux.c
+++ b/libparted/arch/linux.c
@@ -1669,9 +1669,7 @@ retry:
dev->read_only = 0;
}
- /* With kernels < 2.6 flush cache for cache coherence issues */
- if (!_have_kern26())
- _flush_cache (dev);
+ _flush_cache (dev);
return 1;
}
--
1.8.3.1
- bug#15356: [PATCH 00/19] Fedora parted patches, Brian C. Lane, 2013/09/11
- bug#15349: [PATCH 10/19] libparted: mklabel to support EDEV DASD, Brian C. Lane, 2013/09/11
- bug#15353: [PATCH 12/19] tests: rewrite t6001 to use /dev/mapper, Brian C. Lane, 2013/09/11
- bug#15351: [PATCH 09/19] libparted: Avoid dasd as default disk type while probe, Brian C. Lane, 2013/09/11
- bug#15352: [PATCH 04/19] libparted: preserve the uuid on dm partitions (#832145), Brian C. Lane, 2013/09/11
- bug#15354: [PATCH 05/19] tests: Make sure dm UUIDs are not erased, Brian C. Lane, 2013/09/11