Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src/sys/dev/dkwedge



Module Name:    src
Committed By:   jakllsch
Date:           Sun Aug 23 18:40:15 UTC 2015

Modified Files:
        src/sys/dev/dkwedge: dkwedge_gpt.c

Log Message:
Quadruple GPT partition entry count limit (to 512 entries or 64KiB).

The UEFI 2.3.1 specification states that:
"A minimum of 16,384 bytes of space must be reserved for the GPT Partition Entry Array."
and [the size of a partition entry shall be a power of two greater than 128]
and that [the defined fields of a partition entry total 128 bytes].

Clamping the entries means that no partitions on the drive will be detected,
as this will result in an incorrect partition entry array CRC. This change
reduces the likelyhood of useless partitions, while still not allowing a
huge kernel memory allocation to load the partition entries into.

In the future this code should probably be reworked to checksum and evaluate
the partition array in chunks while still limiting the number of GPT
wedges added per drive to something reasonable.


To generate a diff of this commit:
cvs rdiff -u -r1.14 -r1.15 src/sys/dev/dkwedge/dkwedge_gpt.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index