fs/affs: bugfix: enable writes on OFS disks
authorFabian Frederick <fabf@skynet.be>
Mon, 24 Apr 2017 20:12:57 +0000 (22:12 +0200)
committerAl Viro <viro@zeniv.linux.org.uk>
Thu, 27 Apr 2017 03:54:06 +0000 (23:54 -0400)
commit077e073e8f9ebc6bdd3f3f0324b16db07147a232
treece16ea16b55fb4fe3a1404bb1c482b1ce53196d6
parenta9d6cfb70f71e3d7fb4fe90db40f965e7096bdab
fs/affs: bugfix: enable writes on OFS disks

We called unconditionally affs_bread_ino() with create 0 resulting in
"error (device ...): get_block(): strange block request 0"
when trying to write on AFFS OFS format.

This patch adds create parameter to that function.
0 for affs_readpage_ofs()
1 for affs_write_begin_ofs()

Bug was found here:
https://bugzilla.kernel.org/show_bug.cgi?id=114961

Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/affs/file.c