Skip to content

Commit

Permalink
Fix "fs: convert core functions to zero_user_page"
Browse files Browse the repository at this point in the history
The bug was introduced by 01f2705.
It misses to convert the first argument, it should be "new_page".

This became a cause of fatfs corruption.

Cc: Nate Diller <nate.diller@gmail.com>
Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
OGAWAHirofumi authored and Linus Torvalds committed May 21, 2007
1 parent 5f66340 commit ff1be9a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/buffer.c
Original file line number Diff line number Diff line change
Expand Up @@ -2101,7 +2101,7 @@ int cont_prepare_write(struct page *page, unsigned offset,
PAGE_CACHE_SIZE, get_block);
if (status)
goto out_unmap;
zero_user_page(page, zerofrom, PAGE_CACHE_SIZE - zerofrom,
zero_user_page(new_page, zerofrom, PAGE_CACHE_SIZE - zerofrom,
KM_USER0);
generic_commit_write(NULL, new_page, zerofrom, PAGE_CACHE_SIZE);
unlock_page(new_page);
Expand Down

0 comments on commit ff1be9a

Please sign in to comment.