summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--arch/x86_64/lib/memset.S2
-rw-r--r--drivers/ide/ide-iops.c9
2 files changed, 10 insertions, 1 deletions
diff --git a/arch/x86_64/lib/memset.S b/arch/x86_64/lib/memset.S
index f0a7bca375c7..4b4c40638640 100644
--- a/arch/x86_64/lib/memset.S
+++ b/arch/x86_64/lib/memset.S
@@ -113,7 +113,7 @@ memset_c:
/* expand byte value */
movzbl %sil,%esi
movabs $0x0101010101010101,%rax
- mul %esi /* with rax, clobbers rdx */
+ mulq %rsi /* with rax, clobbers rdx */
rep
stosq
movl %r8d,%ecx
diff --git a/drivers/ide/ide-iops.c b/drivers/ide/ide-iops.c
index 06d6292cf70f..a239bbaf5074 100644
--- a/drivers/ide/ide-iops.c
+++ b/drivers/ide/ide-iops.c
@@ -647,6 +647,15 @@ int ide_wait_stat (ide_startstop_t *startstop, ide_drive_t *drive, u8 good, u8 b
timeout += jiffies;
while ((stat = hwif->INB(IDE_STATUS_REG)) & BUSY_STAT) {
if (time_after(jiffies, timeout)) {
+ /*
+ * One last read after the timeout in case
+ * heavy interrupt load made us not make any
+ * progress during the timeout..
+ */
+ stat = hwif->INB(IDE_STATUS_REG);
+ if (!(stat & BUSY_STAT))
+ break;
+
local_irq_restore(flags);
*startstop = DRIVER(drive)->error(drive, "status timeout", stat);
return 1;