History | View | Annotate | Download (5.5 kB)
hd-geometry: Compute BIOS CHS translation in one place
Currently, it is split between hd_geometry_guess() andpc_cmos_init_late(). Confusing. info qtree shows the result of theformer. Also confusing.
Fold the part done in pc_cmos_init_late() into hd_geometry_guess()....
block: Geometry and translation hints are now useless, purge them
There are two producers of these hints: drive_init() on behalf of-drive, and hd_geometry_guess().
The only consumer of the hint is hd_geometry_guess().
The callers of hd_geometry_guess() call it only when drive_init()...
hd-geometry: Move disk geometry guessing back from block.c
Commit f3d54fc4 factored it out of hw/ide.c for reuse. Sensible,except it was put into block.c. Device-specific functionality shouldbe kept in device code, not the block layer. Move it tohw/hd-geometry.c, and make stylistic changes required to keep...
hd-geometry: Add tracepoints
Signed-off-by: Markus Armbruster <armbru@redhat.com>Signed-off-by: Kevin Wolf <kwolf@redhat.com>
hd-geometry: Unnest conditional in hd_geometry_guess()
hd-geometry: Factor out guess_chs_for_size()
hd-geometry: Clean up gratuitous goto in hd_geometry_guess()
hd-geometry: Clean up confusing use of prior translation hint
When hd_geometry_guess() picks a geometry, it also picks theappropriate translation, but only when the prior translation hint isBIOS_ATA_TRANSLATION_AUTO. Looks wrong, because such a priortranslation would be passed to the BIOS whether it's suitable for the...
hd-geometry: Cut out block layer translation middleman
hd_geometry_guess() picks geometry and translation. Callers can getthe geometry directly, via parameters, but for translation they needto go through the block layer.
Add a parameter for translation, so it can optionally be gotten just...
hd-geometry: Switch to uint32_t to match BlockConf
Best to use the same type, to avoid unwanted truncation or signextension.
BlockConf can't use plain int for cyls, heads and secs, becauseinteger properties require an exact width.
Signed-off-by: Markus Armbruster <armbru@redhat.com>...