Messages in this thread Patch in this message | | | Date | Sun, 29 Aug 2004 14:36:32 +0200 | From | "Joachim Bremer" <> | Subject | <no subject> |
| |
As mentioned before I got even with Nicks patch some errors. Looking closer at the source there is is a second "goto page_ok" a few lines down the label "page_not_up_to_date". Inserting the same calculating code used before the label "readpage_error" fixes the errors on my machine. These for instance where failure to do reiserfsck (bread complains on last block of device) and compiling the linux-tree (file truncated).
The leads to the same calculation 3 times...
Patch attached
Joachim _______________________________________________________ WEB.DE Video-Mail - Sagen Sie mehr mit bewegten Bildern Informationen unter: http://freemail.web.de/?mc=021199--- linux-2.6.9-np/mm/filemap.c 2004-08-29 14:03:40.989353448 +0200 +++ linux-2.6/mm/filemap.c 2004-08-29 13:48:37.000000000 +0200 @@ -798,6 +798,15 @@ page_not_up_to_date: /* Did somebody else fill it already? */ if (PageUptodate(page)) { unlock_page(page); + nr = PAGE_CACHE_SIZE; + if (index == end_index) { + nr = isize & ~PAGE_CACHE_MASK; + if (nr <= offset) { + page_cache_release(page); + goto out; + } + } + nr = nr - offset; goto page_ok; } | |