From: David Wragg <dpw@doc.ic.ac.uk>
To: linux-kernel@vger.kernel.org
Subject: What protects f_pos?
Date: 04 Nov 2000 22:16:18 +0000 [thread overview]
Message-ID: <y7r8zqzqt71.fsf@sytry.doc.ic.ac.uk> (raw)
Since f_pos of struct file is a loff_t, on 32-bit architectures it
needs a lock to make accesses atomic (or some more sophisticated form
of protection). But looking in 2.4.0-test10, there doesn't seem to be
any such lock.
The llseek op is called with the Big Kernel Lock, but unlike in 2.2,
the read and write ops are called without any locks held, and so
generic_file_{read|write} make unprotected accesses to f_pos (through
their ppos argument).
Is this something for Ted's todo list?
David
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
next reply other threads:[~2000-11-04 22:16 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-11-04 22:16 David Wragg [this message]
2000-11-11 23:54 ` tytso
2000-11-12 1:56 ` David Wragg
2000-11-12 22:27 ` David Schwartz
2000-11-13 15:22 ` David Wragg
2000-11-13 15:44 ` Richard B. Johnson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=y7r8zqzqt71.fsf@sytry.doc.ic.ac.uk \
--to=dpw@doc.ic.ac.uk \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®