From: Kevin Wolf Date: Mon, 27 Jul 2015 03:42:53 +0000 (-0400) Subject: ide/atapi: Fix START STOP UNIT command completion (CVE-2015-5154) X-Git-Tag: qemu-xen-4.6.0-rc1~9 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=325ec5e0b290b47b177c42e4a930b6644c538321;p=qemu-upstream-4.6-testing.git ide/atapi: Fix START STOP UNIT command completion (CVE-2015-5154) The command must be completed on all code paths. START STOP UNIT with pwrcnd set should succeed without doing anything. upstream-commit-id: 03441c3a4a42beb25460dd11592539030337d0f8 Signed-off-by: Kevin Wolf Reviewed-by: John Snow Signed-off-by: Stefano Stabellini --- diff --git a/hw/ide/atapi.c b/hw/ide/atapi.c index c63b7e556..2887b0f41 100644 --- a/hw/ide/atapi.c +++ b/hw/ide/atapi.c @@ -880,6 +880,7 @@ static void cmd_start_stop_unit(IDEState *s, uint8_t* buf) if (pwrcnd) { /* eject/load only happens for power condition == 0 */ + ide_atapi_cmd_ok(s); return; }