summaryrefslogtreecommitdiff
path: root/blockdev.c
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2014-02-08 11:01:54 +0100
committerAndreas Färber <afaerber@suse.de>2014-02-14 21:12:04 +0100
commitf31c41ff5e7d64680382e94b9ea35d52ab4ca045 (patch)
tree78eddeec3b69d027dc3e1467ba90a75d6c40b734 /blockdev.c
parentc7bcc85d664b26b8b1e46416c7a730104b602e34 (diff)
downloadqemu-f31c41ff5e7d64680382e94b9ea35d52ab4ca045.tar.gz
block: Handle "rechs" and "large" translation options
Sure, CHS translation is an obscure topic, and legacy options for hard-disk geometries are obscure as well. But since QEMU does nothing with it except telling the BIOS, and since there "large" and "rechs" are listed in the enums, parsing them seems to be the bare minimum. Acked-by: Stefan Hajnoczi <stefanha@gmail.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'blockdev.c')
-rw-r--r--blockdev.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/blockdev.c b/blockdev.c
index 36ceece9ff..d71f815a76 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -776,6 +776,10 @@ DriveInfo *drive_init(QemuOpts *all_opts, BlockInterfaceType block_default_type)
translation = BIOS_ATA_TRANSLATION_NONE;
} else if (!strcmp(value, "lba")) {
translation = BIOS_ATA_TRANSLATION_LBA;
+ } else if (!strcmp(value, "large")) {
+ translation = BIOS_ATA_TRANSLATION_LARGE;
+ } else if (!strcmp(value, "rechs")) {
+ translation = BIOS_ATA_TRANSLATION_RECHS;
} else if (!strcmp(value, "auto")) {
translation = BIOS_ATA_TRANSLATION_AUTO;
} else {