Author: tfaber
Date: Sun May 22 10:25:24 2016
New Revision: 71371
URL:
http://svn.reactos.org/svn/reactos?rev=71371&view=rev
Log:
[UNIATA]
- When handling CD READ_CAPACITY requests in AtapiInterrupt__, fully rewind the DataBuffer
instead of relying on the last read length. Fixes crash on first stage boot in KVM.
CORE-11286 #resolve
CORE-11296
Modified:
trunk/reactos/drivers/storage/ide/uniata/id_ata.cpp
Modified: trunk/reactos/drivers/storage/ide/uniata/id_ata.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/ide/uniata…
==============================================================================
--- trunk/reactos/drivers/storage/ide/uniata/id_ata.cpp [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/ide/uniata/id_ata.cpp [iso-8859-1] Sun May 22 10:25:24
2016
@@ -5923,13 +5923,13 @@
// for that also.
if (srb->Cdb[0] == SCSIOP_READ_CAPACITY) {
- AtaReq->DataBuffer -= wordCount;
+ AtaReq->DataBuffer -= AtaReq->WordsTransfered;
if (AtaReq->DataBuffer[0] == 0x00) {
*((ULONG *) &(AtaReq->DataBuffer[0])) = 0xFFFFFF7F;
}
*((ULONG *) &(AtaReq->DataBuffer[2])) = 0x00080000;
- AtaReq->DataBuffer += wordCount;
+ AtaReq->DataBuffer += AtaReq->WordsTransfered;
}
#ifndef UNIATA_INIT_CHANGERS
else