Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 139402
b: refs/heads/master
c: f2bc316
h: refs/heads/master
v: v3
  • Loading branch information
Bartlomiej Zolnierkiewicz committed Mar 31, 2009
1 parent 5c97dd7 commit b6f01d5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7a00798b1a7502ff31736152b23189138db0b978
refs/heads/master: f2bc316736e69e5623443a010f9581a01429c075
14 changes: 6 additions & 8 deletions trunk/drivers/ide/ide-taskfile.c
Original file line number Diff line number Diff line change
Expand Up @@ -195,9 +195,7 @@ static void ide_pio_bytes(ide_drive_t *drive, struct ide_cmd *cmd,
struct scatterlist *sg = hwif->sg_table;
struct scatterlist *cursg = cmd->cursg;
struct page *page;
#ifdef CONFIG_HIGHMEM
unsigned long flags;
#endif
unsigned int offset;
u8 *buf;

Expand All @@ -218,9 +216,9 @@ static void ide_pio_bytes(ide_drive_t *drive, struct ide_cmd *cmd,
page = nth_page(page, (offset >> PAGE_SHIFT));
offset %= PAGE_SIZE;

#ifdef CONFIG_HIGHMEM
local_irq_save(flags);
#endif
if (PageHighMem(page))
local_irq_save(flags);

buf = kmap_atomic(page, KM_BIO_SRC_IRQ) + offset;

cmd->nleft -= nr_bytes;
Expand All @@ -238,9 +236,9 @@ static void ide_pio_bytes(ide_drive_t *drive, struct ide_cmd *cmd,
hwif->tp_ops->input_data(drive, cmd, buf, nr_bytes);

kunmap_atomic(buf, KM_BIO_SRC_IRQ);
#ifdef CONFIG_HIGHMEM
local_irq_restore(flags);
#endif

if (PageHighMem(page))
local_irq_restore(flags);

len -= nr_bytes;
}
Expand Down

0 comments on commit b6f01d5

Please sign in to comment.