coda_file_write() in fs/coda/file.c calls down(&i_sem) before calling
f_op->write(). This will lock-up because generic_file_write() calls
down(&i_sem) again.
AFAICS, these lines are superflous, below is an untested patch.
Btw, where can I find informations about the file synchronization [ie
who should call down(&i_sem), which level of concurrency the various
standard allow,...]?
I think it's a Bad Thing (tm) that file write operations are single
threaded [generic_file_write() calls down(&i_sem)], and I'd like to
change that.
--
Manfred
<<<<<<<
--- build-2.3/fs/coda/file.c.old Sun Nov 28 12:54:05 1999
+++ build-2.3/fs/coda/file.c Sun Nov 28 12:54:22 1999
@@ -193,10 +193,9 @@
return -1;
}
- down(&cont_inode->i_sem);
result = cont_file.f_op->write(&cont_file , buff, count,
&(cont_file.f_pos));
- up(&cont_inode->i_sem);
+
coda_restore_codafile(coda_inode, coda_file, cont_inode, &cont_file);
if (result)
>>>>>>>