lkml.org 
[lkml]   [2002]   [Feb]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: linux 2.5.4-pre3 and IDE changes
John Weber wrote:
> The address member of struct scatterlist appears to have been changed to
> dma_address.
>
> A simple s/\.address/\.dma_address/ should fix this compile error.
>
> ide-dma.c: In function `ide_raw_build_sglist':
> ide-dma.c:269: structure has no member named `address'
> ide-dma.c:276: structure has no member named `address'
> make[3]: *** [ide-dma.o] Error 1
> make[3]: Leaving directory `/usr/src/linux-2.5.4/drivers/ide'
> make[2]: *** [first_rule] Error 2
> make[2]: Leaving directory `/usr/src/linux-2.5.4/drivers/ide'
> make[1]: *** [_subdir_ide] Error 2
> make[1]: Leaving directory `/usr/src/linux-2.5.4/drivers'
> make: *** [_dir_drivers] Error 2

This is the patch that Jens posted, though he posted it before this
kernel was even released. His post said it fixed a compile error
in pre2, but pre2 compiled fine. It _does_ fix the compile error in
pre3 though.

--
Skip
diff -Nru a/drivers/ide/ide-dma.c b/drivers/ide/ide-dma.c
--- a/drivers/ide/ide-dma.c Thu Feb 7 09:44:56 2002
+++ b/drivers/ide/ide-dma.c Thu Feb 7 09:44:56 2002
@@ -266,14 +266,16 @@
#if 1
if (sector_count > 128) {
memset(&sg[nents], 0, sizeof(*sg));
- sg[nents].address = virt_addr;
+ sg[nents].page = virt_to_page(virt_addr);
+ sg[nents].offset = (unsigned long) virt_addr & ~PAGE_MASK;
sg[nents].length = 128 * SECTOR_SIZE;
nents++;
virt_addr = virt_addr + (128 * SECTOR_SIZE);
sector_count -= 128;
}
memset(&sg[nents], 0, sizeof(*sg));
- sg[nents].address = virt_addr;
+ sg[nents].page = virt_to_page(virt_addr);
+ sg[nents].offset = (unsigned long) virt_addr & ~PAGE_MASK;
sg[nents].length = sector_count * SECTOR_SIZE;
nents++;
#endif
\
 
 \ /
  Last update: 2005-03-22 13:24    [W:0.047 / U:45.344 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site