[PATCH] Fix sgiioc4 DMA timeout problem with 64KiB s/g elements.

Problem caused by the fact that the code used to only pick the low 16
bits of the bytecount. That may be how some controllers act on it (byte
count of 0 means 0x10000), but not for this particular hardware.

Signed-off-by: Jeremy Higdon <jeremy@sgi.com>
Acked-by: Jes Sorensen <jes@sgi.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>

authored by Jeremy Higdon and committed by Linus Torvalds 0271fc2d b4103333

+4 -5
+4 -5
drivers/ide/pci/sgiioc4.c
··· 1 1 /* 2 - * Copyright (c) 2003 Silicon Graphics, Inc. All Rights Reserved. 2 + * Copyright (c) 2003-2006 Silicon Graphics, Inc. All Rights Reserved. 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify it 5 5 * under the terms of version 2 of the GNU General Public License ··· 510 510 drive->name); 511 511 goto use_pio_instead; 512 512 } else { 513 - u32 xcount, bcount = 513 + u32 bcount = 514 514 0x10000 - (cur_addr & 0xffff); 515 515 516 516 if (bcount > cur_len) ··· 525 525 *table = 0x0; 526 526 table++; 527 527 528 - xcount = bcount & 0xffff; 529 - *table = cpu_to_be32(xcount); 528 + *table = cpu_to_be32(bcount); 530 529 table++; 531 530 532 531 cur_addr += bcount; ··· 679 680 return -EIO; 680 681 681 682 /* Create /proc/ide entries */ 682 - create_proc_ide_interfaces(); 683 + create_proc_ide_interfaces(); 683 684 684 685 return 0; 685 686 }