Skip to content

Commit

Permalink
Fix error recovery problems with platform_poll()
Browse files Browse the repository at this point in the history
The commit 104dddde63 added some wait loops, but these should
exit if SCSI reset occurs.
  • Loading branch information
PetteriAimonen authored and erichelgeson committed Jun 15, 2023
1 parent ae1ff6c commit de9b1cc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/BlueSCSI_disk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1487,7 +1487,7 @@ void scsiDiskStartRead(uint32_t lba, uint32_t blocks)

if (transfer.currentBlock == transfer.blocks)
{
while (!scsiIsWriteFinished(NULL))
while (!scsiIsWriteFinished(NULL) && !scsiDev.resetFlag)
{
platform_poll();
diskEjectButtonUpdate(false);
Expand Down Expand Up @@ -1667,7 +1667,7 @@ static void diskDataIn()
}
#endif

while (!scsiIsWriteFinished(NULL))
while (!scsiIsWriteFinished(NULL) && !scsiDev.resetFlag)
{
platform_poll();
diskEjectButtonUpdate(false);
Expand Down

0 comments on commit de9b1cc

Please sign in to comment.