From e2f3dc2b6a205cf969ba5d1307293db17fd9621f Mon Sep 17 00:00:00 2001 From: Markus Armbruster Date: Tue, 10 Jul 2012 11:12:37 +0200 Subject: hd-geometry: Cut out block layer translation middleman hd_geometry_guess() picks geometry and translation. Callers can get the geometry directly, via parameters, but for translation they need to go through the block layer. Add a parameter for translation, so it can optionally be gotten just like geometry. In preparation of purging translation from the block layer, which will happen later in this series. Signed-off-by: Markus Armbruster Signed-off-by: Kevin Wolf --- hw/ide/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'hw/ide') diff --git a/hw/ide/core.c b/hw/ide/core.c index 0d1bf1035..28f04add5 100644 --- a/hw/ide/core.c +++ b/hw/ide/core.c @@ -1934,7 +1934,7 @@ int ide_init_drive(IDEState *s, BlockDriverState *bs, IDEDriveKind kind, s->drive_kind = kind; bdrv_get_geometry(bs, &nb_sectors); - hd_geometry_guess(bs, &cylinders, &heads, &secs); + hd_geometry_guess(bs, &cylinders, &heads, &secs, NULL); if (cylinders < 1 || cylinders > 16383) { error_report("cyls must be between 1 and 16383"); return -1; -- cgit v1.2.3