Adjust minimal filesystem size for luks partitions.

This commit is contained in:
Andrius Štikonas 2016-05-20 20:13:11 +01:00
parent 7e8ee77edf
commit f820c8d764
1 changed files with 2 additions and 0 deletions

View File

@ -189,6 +189,8 @@ qint64 Partition::sectorsUsed() const
/** @return the minimum number of sectors this Partition must be long */
qint64 Partition::minimumSectors() const
{
if (roles().has(PartitionRole::Luks))
return fileSystem().minCapacity() / sectorSize() + 4096; // 4096 is the default cryptsetup payload offset
return fileSystem().minCapacity() / sectorSize();
}