Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

blkid: Add support for > 64k cluster NTFS volumes. #167

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

unsound
Copy link

@unsound unsound commented Nov 10, 2023

Windows 10 Creators Edition introduced larger cluster sizes for NTFS, but since the number of sectors per cluster is stored as an 8-bit integer and 128 is the largest power of 2 that can be represented as an unsigned 8-bit integer, larger cluster sizes are encoded as a bitshift value / power of two counted down from the value 255. I.e. past the sectors_per_cluster value 128 the actual number of sectors per cluster is calculated as 2^(256 - sectors_per_cluster).

Windows 10 Creators Edition introduced larger cluster sizes for NTFS,
but since the number of sectors per cluster is stored as an 8-bit
integer and 128 is the largest power of 2 that can be represented as an
unsigned 8-bit integer, larger cluster sizes are encoded as a bitshift
value / power of two counted down from the value 255.
I.e. past the sectors_per_cluster value 128 the actual number of sectors
per cluster is calculated as 2^(256 - sectors_per_cluster).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant