[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 30/41] blockdev: Drop redundant CHS validation for i
From: |
Kevin Wolf |
Subject: |
[Qemu-devel] [PATCH 30/41] blockdev: Drop redundant CHS validation for if=ide |
Date: |
Tue, 17 Jul 2012 18:00:27 +0200 |
From: Markus Armbruster <address@hidden>
Leave it to ide_init_drive().
Signed-off-by: Markus Armbruster <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>
---
blockdev.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/blockdev.c b/blockdev.c
index 06c997e..5f8677e 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -330,15 +330,15 @@ DriveInfo *drive_init(QemuOpts *opts, int default_to_scsi)
max_devs = if_max_devs[type];
if (cyls || heads || secs) {
- if (cyls < 1 || (type == IF_IDE && cyls > 16383)) {
+ if (cyls < 1) {
error_report("invalid physical cyls number");
return NULL;
}
- if (heads < 1 || (type == IF_IDE && heads > 16)) {
+ if (heads < 1) {
error_report("invalid physical heads number");
return NULL;
}
- if (secs < 1 || (type == IF_IDE && secs > 63)) {
+ if (secs < 1) {
error_report("invalid physical secs number");
return NULL;
}
--
1.7.6.5
- [Qemu-devel] [PULL 00/41] Block patches, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 01/41] sheepdog: always use coroutine-based network functions, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 02/41] sheepdog: do not blindly memset all read buffers, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 03/41] fdc: Move floppy geometry guessing back from block.c, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 13/41] hd-geometry: Cut out block layer translation middleman, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 22/41] qdev: Collect private helpers in one place, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 33/41] hw/block-common: Factor out fall back to legacy -drive serial=..., Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 30/41] blockdev: Drop redundant CHS validation for if=ide,
Kevin Wolf <=
- [Qemu-devel] [PATCH 27/41] ide pc: Put hard disk info into CMOS only for hard disks, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 31/41] Relax IDE CHS limits from 16383, 16, 63 to 65535, 16, 255, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 41/41] fdc-test: Clean up a bit, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 37/41] coroutine-ucontext: Help valgrind understand coroutines, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 24/41] ide: qdev property for BIOS CHS translation, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 25/41] qtest: Cover qdev property for BIOS CHS translation, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 18/41] scsi-hd: qdev properties for disk geometry, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 26/41] block: Geometry and translation hints are now useless, purge them, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 32/41] hw/block-common: Move BlockConf & friends from block.h, Kevin Wolf, 2012/07/17
- [Qemu-devel] [PATCH 38/41] qemu-iotests: Valgrind support, Kevin Wolf, 2012/07/17