8000 Support for AHCI 4K sectors · Issue #60 · ReturnInfinity/BareMetal · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Support for AHCI 4K sectors #60
Open
@IanSeyler

Description

@IanSeyler

The AHCI driver only uses 512B sectors. ID should be checked to see if support for larger sectors is supported.

Check bit 12 of word 106 first to see if its set. If so, check words 117-118.

From the ATA8 Command Set, IDENTIFY returns the following:

7.17.7.73 Word 106: Physical sector size / Logical Sector Size
If bit 14 of word 106 is set to one and bit 15 of word 106 is cleared to zero, the contents of word 106 contain valid information. If not, information is not valid in this word.
Bit 13 of word 106 shall be set to one to indicate that the device has more than one logical sector per physical sector.
Bit 12 of word 106 shall be set to 1 to indicate that the device has been formatted with a logical sector size larger than 256 words. Bit 12 of word 106 shall be cleared to 0 to indicate that words 117-118 are invalid and that the logical sector size is 256 words.
Bits (11:4) of word 106 are reserved.
Bits (3:0) of word 106 indicate the size of the device physical sectors in power of two logical sectors.
Examples:
Bits (3:0): 0 = 1 logical sector per physical sector
Bits (3:0): 1 = 2 logical sector per physical sector
Bits (3:0): 2 = 4 logical sector per physical sector
Bits (3:0): 3 = 8 logical sector per physical sector

7.17.7.78 Words 117-118: Logical Sector Size
Words 117,118 indicate the size of device logical sectors in words. The value of words 117,118 shall be equal to or greater than 256. The value in words 117,118 shall be valid when word 106 bit 12 is set to 1. All logical sectors on a device shall be 117,118 words long.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0