From: "Joel Salomon" <joelcsalomon@gmail.com>
To: "Fans of the OS Plan 9 from Bell Labs" <9fans@cse.psu.edu>
Subject: [9fans] Semaphores
Date: Sun, 22 Oct 2006 19:05:55 -0400 [thread overview]
Message-ID: <7871fcf50610221605y124a0b9dnccd7e3e420a0ad03@mail.gmail.com> (raw)
Homework help: Could someone point me to an explanation of semaphore
implementation? I'm supposed to implement something very like
semacquire(2) using TAS spinlocks (the professor says it's OK for me
to use lock(2), but not qlock), but in user mode. He suggests using
signals for wakeup.
I'm looking at /sys/src/9/port/sysproc.c and /sys/doc/sleep.* not
quite understanding either. Is there a readable description of
queueing on a semaphore in the literature somewhere? Google's mostly
turning up assembler-heavy linux kernel one-upsmanship.
--Joel
--
In googlis non est, ergo non est.
next reply other threads:[~2006-10-22 23:05 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-22 23:05 Joel Salomon [this message]
2006-10-22 23:21 ` Russ Cox
2006-10-22 23:29 ` Steve Simon
-- strict thread matches above, loose matches on Subject: below --
2002-01-25 14:53 [9fans] semaphores Russ Cox
2002-01-16 7:48 nigel
[not found] <rsc@plan9.bell-labs.com>
2002-01-16 3:44 ` Russ Cox
2002-01-16 3:54 ` Scott Schwartz
2002-01-16 11:14 ` Boyd Roberts
2002-01-16 15:47 ` Ronald G Minnich
2002-01-25 10:30 ` Ralph Corderoy
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=7871fcf50610221605y124a0b9dnccd7e3e420a0ad03@mail.gmail.com \
--to=joelcsalomon@gmail.com \
--cc=9fans@cse.psu.edu \
/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;
as well as URLs for NNTP newsgroup(s).