diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2009-03-27 07:46:37 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2009-03-27 07:46:37 -0400 |
commit | e6830a86c260d73c6f370aa7ed17ee6c71e5ee05 (patch) | |
tree | c2c7d472184da1549852b86eef551609cddcbcbf /drivers/ide/ide-dma-sff.c | |
parent | b109f526cabcd098131e770fd6232282bce147b4 (diff) |
ide: call ide_build_sglist() prior to ->dma_setup (v2)
* Re-map sg table if needed in ide_build_sglist().
* Move ide_build_sglist() call from ->dma_setup to its users.
* Un-export ide_build_sglist().
v2:
* Build fix for CONFIG_BLK_DEV_IDEDMA=n (noticed by Randy Dunlap).
There should be no functional changes caused by this patch.
Cc: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide-dma-sff.c')
-rw-r--r-- | drivers/ide/ide-dma-sff.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/ide/ide-dma-sff.c b/drivers/ide/ide-dma-sff.c index 123d393658af..22b3e751d19b 100644 --- a/drivers/ide/ide-dma-sff.c +++ b/drivers/ide/ide-dma-sff.c | |||
@@ -120,10 +120,6 @@ int ide_build_dmatable(ide_drive_t *drive, struct request *rq) | |||
120 | struct scatterlist *sg; | 120 | struct scatterlist *sg; |
121 | u8 is_trm290 = !!(hwif->host_flags & IDE_HFLAG_TRM290); | 121 | u8 is_trm290 = !!(hwif->host_flags & IDE_HFLAG_TRM290); |
122 | 122 | ||
123 | hwif->sg_nents = ide_build_sglist(drive, rq); | ||
124 | if (hwif->sg_nents == 0) | ||
125 | return 0; | ||
126 | |||
127 | for_each_sg(hwif->sg_table, sg, hwif->sg_nents, i) { | 123 | for_each_sg(hwif->sg_table, sg, hwif->sg_nents, i) { |
128 | u32 cur_addr, cur_len, xcount, bcount; | 124 | u32 cur_addr, cur_len, xcount, bcount; |
129 | 125 | ||