Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 82519
b: refs/heads/master
c: 36e9dc4
h: refs/heads/master
i:
  82517: 68a2166
  82515: 757fa83
  82511: d0b75cb
v: v3
  • Loading branch information
Bartlomiej Zolnierkiewicz committed Feb 2, 2008
1 parent ed84f61 commit bad9a73
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 19 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: 124d3b7041f9a0ca7c43a6293e1cae4576c32fd5
refs/heads/master: 36e9dc469b1300d8bec6f2ab48b4556e2c4241ba
4 changes: 0 additions & 4 deletions trunk/drivers/ide/ide.c
Original file line number Diff line number Diff line change
Expand Up @@ -791,10 +791,6 @@ int set_io_32bit(ide_drive_t *drive, int arg)
return -EBUSY;

drive->io_32bit = arg;
#ifdef CONFIG_BLK_DEV_DTC2278
if (HWIF(drive)->chipset == ide_dtc2278)
HWIF(drive)->drives[!drive->select.b.unit].io_32bit = arg;
#endif /* CONFIG_BLK_DEV_DTC2278 */

spin_unlock_irq(&ide_lock);

Expand Down
12 changes: 6 additions & 6 deletions trunk/drivers/ide/legacy/dtc2278.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,6 @@ static void dtc2278_set_pio_mode(ide_drive_t *drive, const u8 pio)
/* Actually we do - there is a data sheet available for the
Winbond but does anyone actually care */
}

/*
* 32bit I/O has to be enabled for *both* drives at the same time.
*/
drive->io_32bit = 1;
HWIF(drive)->drives[!drive->select.b.unit].io_32bit = 1;
}

static int __init dtc2278_probe(void)
Expand Down Expand Up @@ -123,18 +117,24 @@ static int __init dtc2278_probe(void)
local_irq_restore(flags);

hwif->serialized = 1;
hwif->no_io_32bit = 1; /* disallow ->io_32bit changes */
hwif->chipset = ide_dtc2278;
hwif->pio_mask = ATA_PIO4;
hwif->set_pio_mode = &dtc2278_set_pio_mode;
hwif->drives[0].no_unmask = 1;
hwif->drives[1].no_unmask = 1;
hwif->drives[0].io_32bit = 1;
hwif->drives[1].io_32bit = 1;
hwif->mate = mate;

mate->serialized = 1;
mate->no_io_32bit = 1;
mate->chipset = ide_dtc2278;
mate->pio_mask = ATA_PIO4;
mate->drives[0].no_unmask = 1;
mate->drives[1].no_unmask = 1;
mate->drives[0].io_32bit = 1;
mate->drives[1].io_32bit = 1;
mate->mate = hwif;
mate->channel = 1;

Expand Down
5 changes: 3 additions & 2 deletions trunk/drivers/ieee1394/sbp2.c
Original file line number Diff line number Diff line change
Expand Up @@ -1465,9 +1465,10 @@ static void sbp2_prep_command_orb_sg(struct sbp2_command_orb *orb,
orb->misc |= ORB_SET_DIRECTION(orb_direction);

/* special case if only one element (and less than 64KB in size) */
if (scsi_use_sg == 1 && sg->length <= SBP2_MAX_SG_ELEMENT_LENGTH) {
if ((scsi_use_sg == 1) &&
(sg_dma_len(sg) <= SBP2_MAX_SG_ELEMENT_LENGTH)) {

cmd->dma_size = sg->length;
cmd->dma_size = sg_dma_len(sg);
cmd->dma_type = CMD_DMA_PAGE;
cmd->cmd_dma = dma_map_page(hi->host->device.parent,
sg_page(sg), sg->offset,
Expand Down
8 changes: 2 additions & 6 deletions trunk/mm/filemap.c
Original file line number Diff line number Diff line change
Expand Up @@ -1750,11 +1750,7 @@ static void __iov_iter_advance_iov(struct iov_iter *i, size_t bytes)
const struct iovec *iov = i->iov;
size_t base = i->iov_offset;

/*
* The !iov->iov_len check ensures we skip over unlikely
* zero-length segments.
*/
while (bytes || !iov->iov_len) {
while (bytes) {
int copy = min(bytes, iov->iov_len - base);

bytes -= copy;
Expand Down Expand Up @@ -2272,7 +2268,6 @@ static ssize_t generic_perform_write(struct file *file,

cond_resched();

iov_iter_advance(i, copied);
if (unlikely(copied == 0)) {
/*
* If we were unable to copy any data at all, we must
Expand All @@ -2286,6 +2281,7 @@ static ssize_t generic_perform_write(struct file *file,
iov_iter_single_seg_count(i));
goto again;
}
iov_iter_advance(i, copied);
pos += copied;
written += copied;

Expand Down

0 comments on commit bad9a73

Please sign in to comment.